Skip to content

About

Production-ready AI GitHub bot powered by OpenCode Automate issue analysis, PR reviews, and intelligent collaboration — completely free for open-source projects.

Resources

Security policy

Stars

24 stars

Watchers

0 watching

Forks

Repository files navigation

Mirrobot Agent

An AI collaborator for your GitHub repository, powered by OpenCode, running entirely on GitHub Actions.

It reads your code, reviews your pull requests, audits merge readiness, answers questions in your issues, and writes fixes when you ask, with genuine judgment, in its own voice, on infrastructure you already have.

zread Ask DeepWiki Ask Mirrobot

The Ask Mirrobot badge in the row above is this project's own.

License: MIT Powered by OpenCode Runs on GitHub Actions Any LLM provider


Contents


What you get

The agent will...
🔍 Analyze every new issue Assess the problem, hunt duplicates, trace the root cause through your code, then grade it (how bad, how good if done, how risky) and label it
🧠 Review pull requests Severity-graded findings (🔴 🟠 🟡 🔵), inline on the exact lines, with a justified verdict in plain words
✅ Audit merge readiness On /mirrobot-check: documentation, consistency, good practices, gating the merge via a real status check
💬 Answer anywhere @mirrobot-agent in any issue or PR: questions answered, code investigated, other PRs reviewed on demand
🌡️ Judge without ceremony "Check this PR, is it good?" gets a calibrated opinion: a judgment-first comment, findings anchored inline where they earn it, an honest scope note, never a heavyweight review object unless you actually ask for a review
🔧 Contribute code "Fix this" → it branches, implements, self-reviews, and opens a PR, never touching your workflows
🛡️ Refuse to be exploited Injection-hardened, adversarially tested, scrubbed workspaces, least-privilege tokens

Closer to a colleague than a linter: it reads the whole thread, remembers its own previous reviews, admits uncertainty, argues when you're wrong, and stays quiet when it has nothing to add.

What a review looks like

Verdict: changes requested: the tracing hook has two blocking problems; the rest is solid and I'd approve once they're addressed.

  • logger.py:42 🔴 Critical: redact_keys skips Authorization and x-api-key, so the "redacted" trace file contains raw credentials
  • logger.py:88 🟠 Major: the flush happens after the response returns, so a crashed request loses its own trace
  • README.md 🟡 Minor: new TRACE_FILE env var is undocumented
  • tests/ 🔵 Info: no coverage for the new hook; the existing fixtures would take a case easily

This review was generated by an AI assistant.

Every finding carries its severity. The verdict always says why. Push a fix and the follow-up review sees only the delta, and checks whether its previous feedback was actually addressed.


How it works

flowchart TB
    subgraph events["GitHub events"]
        C[comment or discussion mention]
        I[issue opened]
        P[PR opened, ready, reopened, pushed]
        RC[inline review comment]
        N[account notification]
        D[.github change]
        M[manual dispatch]
        S[weekly schedule]
    end

    C --> ROUTER["<b>Agent Router</b><br/>parses once, dispatches per match"]
    I --> TURN
    P --> STUB["<b>PR Review Trigger</b><br/>zero-secret base-branch stub:<br/>decide + pending merge-blocker status"]
    P --> GATE["<b>Compliance Gate</b><br/>redundant pending-status poster"]
    RC --> SIGNAL["<b>Inline Review Comment Router</b><br/>zero-secret signal, PR merge commit"]
    N --> POLLER["<b>Mention Poller</b><br/>re-verified cross-repo triggers"]
    D --> FIX["<b>Scrub Fixture Suite</b><br/>batteries on the branch under test"]
    M --> BOOT["<b>Agent Bootstrap</b><br/>seed defaults and labels"]
    S --> EXCERPTS["<b>Excerpts Refresh</b><br/>landing-page card pool"]

    subgraph agent["Agent work, privileged, from the default branch"]
        TURN["<b>Thread Turn</b><br/>one session per thread:<br/>triage, review, delta, reply, fix"]
        COMPL["<b>Compliance Check</b><br/>end-of-life merge audit"]
        VERIFY["<b>Compliance Verify job</b><br/>separate job, fresh runner"]
        GUEST["<b>Bot Reply (Guest)</b><br/>foreign-repo sessions"]
    end

    ROUTER -->|mention| TURN
    ROUTER -->|/mirrobot-check| COMPL
    STUB -->|review wanted| TURN
    SIGNAL -->|direct dispatch| TURN
    SIGNAL -.->|read-only fork token| BRIDGE["<b>Inline Review Comment Bridge</b><br/>workflow_run fallback"]
    BRIDGE --> TURN
    POLLER --> GUEST
    COMPL --> VERIFY

    subgraph engine["Every agent run"]
        S1["1 · Identity: account PAT or App token<br/>(scope-gated, fail-fast)"]
        S2["2 · Trusted artifacts secured<br/>before any PR checkout"]
        S3["3 · Workspace scrub + taint alarm<br/>(removed files quarantined, readable as data)"]
        S4["4 · Context: 3-block review memory,<br/>diffs, trusted roster, requester trust line"]
        S5["5 · Prompt assembled from parts<br/>(38 parts → 13 mode manifests)"]
        S6["6 · OpenCode session<br/>the agent does the work"]
        S7["7 · Verification: footer/SHA checks,<br/>repair, reactions"]
        S8["8 · Sealed session archive (MRB3, 30 days, when SESSION_ARTIFACT_PUBKEY is set)<br/>+ offline snapshot (7 days, no live share by default)"]
        S1 --> S2 --> S3 --> S4 --> S5 --> S6 --> S7 --> S8
    end

    TURN & COMPL & GUEST --> engine
Loading

The core security principle: PR content is only ever data. Agent work always executes the default branch's copy of its workflows; a malicious PR cannot redefine the agent pipeline that reviews it. The only agent-path workflows whose execution copy a PR event chooses are zero-secret, no-checkout event stubs: the two base-branch markers and the merge-commit inline-review signal. Untrusted text never touches a shell except through environment variables. Everything the agent auto-loads from a checkout (instruction files, agent configs, skills) survives only when its bytes match a state a trusted branch shipped; otherwise it's removed, logged, and quarantined for the agent to read as data. The details are in security; read them before you open this to strangers.

And the platform checks itself: a fixture suite and prompt structural checks run in CI on every change under .github/scripts, .github/prompts, .github/actions, or .github/workflows, so drift shows up as a red build instead of a silent change. CI enforces machine contracts only (assembly integrity, placeholder completeness, marker couplings, security behavior); prompt prose is never pinned, so forks can reword anything.


Quick start (~10 minutes)

1. Install the platform

Copy .github/ and mrb3.py from this repo into yours, on the default branch. That's the whole runtime: workflows, prompts, scripts, the composite action, and the MRB3 archive sealer.

Optional companions:

Also copy Enables
decrypt_share_link.py Decrypting the agent's encrypted session archives locally. The run browser lists thread/compliance/guest runs newest first, with the thread label shown when it changes; selecting one shows the live share first (read from the run's annotation, so nothing is downloaded for it), then offers the raw session family and the stored snapshot page, which opens straight from disk (file://). Pasting a block decrypts on one Enter. It opens the current MRB3 archives and the older MRB1 link form. It asks before downloading or writing; files land in sessions/ beside the tool (--save/--open skip the prompt), and cached sessions older than 30 days are pruned by default. Listing runs and reading a live link need no token on a public repo; artifact downloads and private repos need one (Checks: read). Its setup mode generates the keypair, offers to set the SESSION_ARTIFACT_PUBKEY secret through gh, and keeps the private key local. Settings live in ~/.config/mirrobot/config.json (see configuration.md). Live sharing (optional, OpenShare) is documented in configuration.md.
tools/mention-worker/ Cross-repo guest mode, the agent answering mentions in repos it's not installed in
minify_json_secret.py Minifying the OPENCODE_CONFIG_JSON secret to one line (RFC 8259-strict; warns above GitHub's 48 KB secret limit)

2. Pick an identity

Option A: bot account (recommended): a dedicated user account with a classic PAT, public_repo scope for a public repository (repo for a private one) (no workflow scope; the platform rejects it), invited to the repo as a collaborator with Write.

Option B, GitHub App: create an App with read/write on the surfaces the lanes use: Contents · Issues · Pull requests · Discussions · Commit statuses · Actions, install it on the repo. App mode needs Variables: write only if Agent Bootstrap should seed through the App.

Presence of the account token selects account mode automatically; otherwise the App pair is used.

3. Add secrets

Settings → Secrets and variables → Actions → Secrets, the minimal set:

Secret What
OPENCODE_MODEL Main model, provider/model format, e.g. anthropic/claude-sonnet-4. Optional when your config carries a model field; when set it overrides that field
OPENCODE_CONFIG_JSON Your complete OpenCode config, minified to one line: permission profile, providers, API keys, MCP servers, model. Start from the committed template: .github/actions/bot-setup/permissions.example.json
+ identity ACCOUNT_GH_TOKEN (account mode), or BOT_APP_ID + BOT_PRIVATE_KEY (App mode)
# minify the template (or your own config) to one byte-exact line first:
python minify_json_secret.py .github/actions/bot-setup/permissions.example.json -o config.min.json

gh secret set OPENCODE_MODEL       -R <owner>/<repo> --body "anthropic/claude-sonnet-4"   # skip when the config carries "model"
gh secret set OPENCODE_CONFIG_JSON -R <owner>/<repo> < config.min.json        # bash/macOS/Linux
gh secret set ACCOUNT_GH_TOKEN     -R <owner>/<repo>   # paste the PAT when prompted
Get-Content config.min.json | gh secret set OPENCODE_CONFIG_JSON -R <owner>/<repo>   # PowerShell

For orientation, a minimal config looks like:

{
  "provider": { "anthropic": { "options": { "apiKey": "sk-ant-..." } } },
  "permission": { "...": "the block from permissions.example.json" }
}

Then run Agent Bootstrap once (Actions → Agent Bootstrap → Run workflow, needs repo write access): it seeds the tuning variables it owns, creates missing labels from .github/labels.txt, and prints a secrets checklist into the run summary. It never overwrites existing values or labels. Full reference with where-to-get-everything: Configuration.

4. Gate merges (recommended)

Settings → Rules → Rulesets → New ruleset, targeting your default branch: require a pull request before merging, and require the compliance-check status. Now nothing merges until the agent's audit passes. Two toggles to leave off: "Restrict updates" (with an admin-only bypass it deadlocks bot merges entirely) and "Require approval of the most recent reviewable push" (it is enforced even at zero required approvals, so after the bot pushes a fix its own approval can never cover its own push, and you cannot approve your own PR).

On a public repository, GitHub blocks pull_request_target by default unless the repository's Actions event policy allows it. Both PR Review Trigger and Compliance Gate run on that event, so allow it under Settings → Actions → Policies (or at the organization level); without it, automatic reviews and the pending compliance-check status never start.

With that ruleset in place you may tell the agent to merge a PR. It never merges on its own initiative, and under your order it still works the gate itself: its own approving review at the final head, the compliance status read, then the merge.

5. Say hello

Open an issue, open a PR, or comment @mirrobot-agent hello; within about a minute you should see a 👀 reaction, then a reply. Comment dispatches show their decision in the Agent Router run; PR and inline-review events show theirs in their trigger runs.


Trigger words & identity

Two systems with two different jobs:

Triggers, what summons the agent. The default words are @mirrobot, @mirrobot-agent, and /mirrobot-check. They all come from one variable. BOT_TRIGGERS holds plain names, and each name expands into a mention plus a compliance command. Concretely, the default value:

BOT_TRIGGERS = "mirrobot, mirrobot-agent"

makes the agent answer to @mirrobot and @mirrobot-agent (a review is a request in natural language: "please review this"), and run compliance for /mirrobot-check and /mirrobot-agent-check. Renaming works the same way: set BOT_TRIGGERS="acme" and the bot answers to @acme and /acme-check, and the mirrobot words stop routing (setting the variable replaces the defaults). When the variable is unset, the names come from the bot's own identity: the BOT_IDENTITIES entries every dispatcher can read, plus the account login the agent workflows detect live; if nothing is set, the stock names apply.

Identity, who the agent is. When the agent asks "did I write this review?" (loop guards, review attribution, footer verification), it compares against its logins: whatever you put in the BOT_IDENTITIES variable, plus (in account mode) the account name it detects live from its token. If neither exists, the stock names apply. "mirrobot" is the agent's name, not an identity: a user who happens to be named mirrobot is never treated as the agent itself. Bootstrap seeds both variables.

Details: configuration · renaming.


Configuration

Full reference with worked examples lives in docs/configuration.md. Summary:

Secrets (Settings → … → Secrets): the minimal set is OPENCODE_CONFIG_JSON (with a model field, or add OPENCODE_MODEL), plus one identity pair. Optional: OPENCODE_API_KEY (provider key when it's not inside your config), CONTENT_PACKS_PRIVATE + CONTENT_PACK_TOKEN (private content packs), SESSION_ARTIFACT_PUBKEY (encrypted session archives; python decrypt_share_link.py setup generates the keypair and offers to set this secret), SESSION_STATE_KEY (lets runs resume the same archives; openssl rand -hex 64), OPENSHARE_CONFIG_JSON (live session sharing via OpenShare, the whole plugin config as one secret, template at .github/plugins/openshare.ci.EXAMPLE.json; see configuration.md), MAGIC_CONTEXT_CONFIG_JSON (optional Magic Context store config; arm it by adding @cortexkit/opencode-magic-context@<version> to the plugin list inside OPENCODE_CONFIG_JSON, remove that entry to disable; see configuration.md).

Variables (Settings → … → Variables):

Variable Default What it tunes
AGENT_PAUSED false Global kill switch, see pause switches
OPEN_TRIGGERING true false = on-demand summons limited to collaborators + trusted roster (auto paths stay open)
AGENT_PAUSED_PARTS_JSON all false Per-part pause, see pause switches
REVIEW_DRAFT_PRS false Review draft PRs on creation too
AGENT_MODELS_JSON (empty template) Per-agent models, see docs
BOT_IDENTITIES account login / stock names Who the agent is (self-detection set)
BOT_TRIGGERS mirrobot, mirrobot-agent What summons the agent (stems; commands derive)
CONTEXT_LIMITS_JSON (full budget template) Context budget: how many comments/reviews/threads the agent reads, lower = smaller prompts. Details
CONTEXT_IGNORE_AUTHORS (empty) Logins whose posts never enter agent context
CONTEXT_FILTER_PATTERNS_JSON baked AI-noise defaults Regex patterns dropping matching posts; replaces the defaults
TRUSTED_AGENT_USERS (empty) Extra friendly users beyond collaborators (collaborators already count)
ELEVATED_REVIEWS_COUNT 1 How many of the agent's own newest reviews are elevated (unfiltered memory). Older ones still appear, filtered, in the history block
SESSION_STATE_KEEP_HISTORY (unset) Keep superseded session archives until their 30-day expiry instead of pruning them after a successful archive upload
CONTENT_PACKS (unset) Public content pack sources: skills, plugins, agents, commands, boot-time extensions and config fragments, see docs
OPENSHARE_PASSIVE true false disables the passive session export, offline snapshot and encrypted archive
OPENSHARE_SNAPSHOT auto Offline snapshot policy: auto (only when there is no live share), always, never; kept 7 days
OPENSHARE_BUNDLE_URL (released master) Override the OpenShare plugin bundle URL; delete it to return to the released master line
FOREIGN_MENTIONS_ENABLED / FOREIGN_MENTIONS_USERS false / (empty) Cross-repo guest mode, see below
GUEST_REPO_RULES (unset) Ordered <owner/repo>:deny or :allow rules for guest mode; last match wins, and the platform repo is always denied

Notes:

  • Model strings are provider/model; the provider can be a built-in (when OPENCODE_API_KEY supplies its key) or an entry in your OPENCODE_CONFIG_JSON.
  • The runtime protects the config secret: every credential leaf inside it is masked, and the file (plus materialized plugins) is deleted right after opencode reads it. Details.
  • Thread context is filtered before it's allocated: hidden (minimized) content never reaches the agent (its own posts included), and the built-in defaults drop known AI-reviewer noise (rate-limit notices, skip posts) while keeping those tools' substantive reviews. Output from other AI reviewers is verified like anyone else's; none of it is treated as a verdict.

Pause switches

AGENT_PAUSED=true pauses everything: the router dispatches nothing, the mention poller stays silent, every agent lane skips with a visible gray "skipped" (manual agent dispatches included). The two base-branch marker workflows keep running, so open PRs keep their pending merge-blocker status; pausing never makes a PR mergeable.

AGENT_PAUSED_PARTS_JSON pauses one part at a time:

{ "pr-review": true, "bot-reply": false, "bot-reply-guest": false, "compliance-check": false, "issue-analysis": false }

Paused parts skip visibly: the router skips its routes, the PR stub suppresses review dispatches, and the thread, compliance and guest lanes skip their turns; missing keys (or the whole variable) mean not paused; malformed JSON fails the run with a visible error. Typical use: quiet just the issue triage during a label migration, or just the reviewer while you rebase a big stack.


Cross-repo guest mode (opt-in)

The agent can answer wherever its account is mentioned: any public repo, even ones it's not installed in. Mentions of a bot account become account notifications; an external Cloudflare worker relays them to the mention-poller workflow, which re-verifies everything (allowlist, genuine-mention token, reason) before spawning a guest session under strict guest rules, read-only by default, authority pinned to the allowlist.

Enable (account mode only): add notifications scope to the PAT, set FOREIGN_MENTIONS_ENABLED=true, optionally FOREIGN_MENTIONS_USERS (who may summon it abroad; collaborators already can), and deploy the worker (~10 minutes, free tier). End-to-end latency is about a minute and a half (the home-repo path in the quick start answers in under a minute, the guest path adds the worker relay). Full story: docs/workflows/mention-poller.md.


The workflows

Workflow Trigger Runs from What it does
Agent Router comment, discussion comment, new discussion default branch Parses once; dispatches compliance for /mirrobot-check on a PR and Thread Turn for a genuine mention, one run per match (a compound comment can dispatch both)
Thread Turn issue opened; dispatch from the router, PR stub, and review-comment signal or its bridge; manual dispatch default branch One persistent session per thread: triage, first review, delta re-review, mention replies, fixes and merge orders
PR Review Trigger PR opened, ready, reopened, pushed on an Agent Monitored PR, review requested from the bot PR's base branch Zero-secret, no-checkout stub: decides whether a review is wanted, posts the pending merge-blocker status on a non-draft PR, dispatches Thread Turn; a declined event dispatches nothing
Compliance Gate PR opened, ready, reopened, pushed PR's base branch Zero-secret, no-checkout second poster of the pending status on a non-draft PR; retries, then goes red rather than letting a transient error make a PR look mergeable
Inline Review Comment Router inline review comment created PR's merge commit Zero-secret, no-checkout signal: dispatches Thread Turn for a genuine mention; on a fork's read-only token it publishes the comment id for the bridge
Inline Review Comment Bridge completion of the router default branch Reads the fallback artifact, re-fetches the comment, and dispatches Thread Turn; no checkout
Compliance Check /mirrobot-check via the router, or manual dispatch default branch End-of-life merge audit; posts the report and compliance-check status; a separate verify job on a fresh runner checks the report's footers and exception provenance, and demotes the status if verification fails
Bot Reply (Guest) dispatch from the poller, or manual default branch Guest lane: sessions in foreign repositories, account mode only, allowlist-pinned and read-only by default
Mention Poller relayed account notification, or manual dispatch default branch Cross-repo ears: re-verifies each notification, then dispatches a guest session (see the worker)
Agent Bootstrap manual dispatch default branch One-time setup: seeds the tuning variables it owns and the label palette, prints a secrets checklist; never overwrites, no checkout
Excerpts Refresh weekly schedule, or manual dispatch default branch Rebuilds the landing page's card pool from the agent's real posts and deploys docs/ to Pages as an artifact
Scrub Fixture Suite pushes and PRs touching .github/scripts, .github/prompts, .github/actions, or .github/workflows; manual dispatch the branch under test The batteries: security fixtures, prompt structural checks, and strict workflow YAML validation

The "Runs from" column is the platform's spine. Everything that holds secrets or does agent work runs from the default branch (main here). Only three agent-path workflows have their execution copy chosen by the PR event, and all three are zero-secret and no-checkout: the two base-branch markers (PR Review Trigger and Compliance Gate) and the merge-commit inline-review signal. Every dispatch they make targets the default branch. The fixture suite is CI: it checks whatever copy it runs on. Platform updates land on main; your integration branch needs no per-batch sync. The one exception: auto-load content (AGENTS.md and friends) evolves on the integration branch with the work it describes. The full sync doctrine lives in design.md.

Workflow index with per-workflow triggers, knobs, failure meanings and test recipes: docs/workflows/overview.md.

The life of a pull request

  1. Opened → stub dispatches a review turn → first review: full diff, acknowledgment within its first action, severity-graded findings, a justified verdict
  2. New commits → (with the Agent Monitored label) → follow-up: incremental diff only, previous feedback re-verified
  3. Ready to merge → /mirrobot-check → compliance audit → status goes 🟢 (clean, or warnings, read the description) or 🔴 (blocking)
  4. Merge: ask the agent and it will merge after its own safety review and after reading the compliance description, not merely because the status is green

The review-request button works too: on repos with the platform, requesting a review from the agent's identity triggers a review turn immediately; no label is needed (draft PRs still follow REVIEW_DRAFT_PRS).

The strategies behind a reply

Mention the agent and it picks its own approach, loading the matching instruction set on demand: conversationalist, investigator (evidence-grade codebase exploration), code reviewer (full review flow for any PR, @mirrobot-agent review #42 works from any thread), code contributor (branch → implement → self-review → PR), repository manager (labels, issues, housekeeping).


Security

Built against real adversarial testing (disguised injection PRs, trojan documentation, malicious agent-config files, symlink escapes, evil merges) and re-verified by CI on every change.

  • No untrusted interpolation: comment bodies, PR titles, file contents reach shells only as environment variables; a pinned audit proves it
  • Privileged execution from the default branch: agent work never runs a PR's copy of a workflow. The two base-branch markers and the merge-commit inline-review signal are zero-secret and no-checkout; any dispatch they make targets the default branch
  • Workspace scrub, split trust: auto-loaded files (instruction files, skills, configs) survive only when their bytes match a state a trusted branch shipped at-or-after the fork point; .github wiring anchors to main alone; everything else is removed and quarantined, readable as data
  • Least-privilege identity + dying secrets: scope-gated tokens, credential leaves masked, config and plugins deleted right after boot

The full threat model, defense by defense, with the known residuals: docs/security.md.


Development

.github/
├── actions/
│   ├── bot-setup/                    # dual-identity token + config passthrough
│   │   └── permissions.example.json  # → your OPENCODE_CONFIG_JSON secret
│   └── requester-context/            # trust-line context (association + roster)
├── prompts/
│   ├── security-brief.md             # read first in every home session
│   ├── security-brief-guest.md       # the guest-lane brief
│   ├── parts/                        # 38 instruction parts (the prose)
│   ├── manifests/                    # 13 mode manifests (the assembly order)
│   ├── skills/                       # 5 on-demand prompt skills (labels, discussions,
│   │                                 #   hierarchy, opinion, reactions)
│   └── appends/                      # conditional fragments (self-review tone)
├── scripts/                          # 25 scripts: assembler, scrub, router, context
│                                     # engine, review kit, session state/export,
│                                     # share filter, boot cleanup, the two CI
│                                     # batteries, and supporting tools;
│                                     # post/ holds the posting helpers
└── workflows/                        # the 12 workflows above

decrypt_share_link.py                 # operator session decryptor and run browser
mrb3.py                               # MRB3 archive sealer staged into session runs
minify_json_secret.py                 # JSON → single-line secret string

Changing behavior: find the part (grep -r .github/prompts/parts/), edit it, re-pin if the wording is load-bearing, verify locally (Windows: run these from Git Bash or WSL):

bash .github/scripts/assemble-prompt.sh --verify        # manifests resolve
bash .github/scripts/assemble-prompt.sh --list          # see every mode
bash .github/scripts/assemble-prompt.sh --system thread-system # the standing orders
bash .github/scripts/assemble-prompt.sh agentlib-review        # the review pack
bash .github/scripts/prompt-rule-fixtures.sh            # prompt structure green
bash .github/scripts/scrub-fixtures.sh                  # security fixtures green (add --quick/--only/--parallel for local speed)

Contributing: fork → branch → change → batteries green → PR. Your PR gets an automated review; run /mirrobot-check for the compliance audit before merge.


Documentation

  • Getting started: the install guide in full detail (identity choice, secrets, branch protection, first hello)
  • Design: the execution map, the life of a PR, the trust model, the update doctrine
  • Configuration: every variable and secret, with examples and interaction rules
  • Customization: prompts, the compliance rule documents, the permission profile, renaming the agent
  • Security: the threat model, defense by defense
  • Workflows: the workflow index and per-lane pages
  • ARCHITECTURE.md / STRUCTURE.md: the code-state mirrors (layers, entry points, file inventory); the docs above carry the principles and guides

Landing page & badge

Repositories running a Mirrobot deployment can carry the Ask Mirrobot badge, linking visitors to the informational page. Two knobs on the badge link:

  • ?bot=: your deployment's bot name, so visitors know who to mention back home; comma-separate several if it answers to more than one (?bot=MyBot,MyBot[bot])
  • &repo=: repoints the page's live-activity strip at the linking repository (&repo=OWNER/REPO)

The page ships in docs/ and publishes through the Excerpts Refresh workflow as a Pages artifact; its "field notes" cards are dealt at random from a weekly-harvested pool of the agent's real posts (harvest knobs).


FAQ

Cost? Public repos: Actions minutes are free; you pay only LLM usage (typically a few dollars/month for an active project). Private repos: 2,000 free minutes/month. Each run prints its own token usage in the step summary; CONTEXT_LIMITS_JSON and AGENT_MODELS_JSON are the cost knobs.

Providers? Anything OpenCode speaks: OpenAI, Anthropic, self-hosted (Ollama, vLLM), proxies, regional providers, configured in OPENCODE_CONFIG_JSON.

Can it commit code? Yes, when asked (contributor strategy: branch, implement, self-review, open a PR). It never modifies .github/workflows (hard-denied at the permission layer). It merges only after its own safety review + a green compliance check.

Fork PRs? Fully supported, including reviews; fork heads are fetched explicitly and pinned to the API-recorded SHA.

What if it's wrong? It's an AI: review its output critically, correct it in-thread (it reads follow-ups), and improve the parts. The batteries keep your edits from breaking the system silently.

Multiple bots? Different App or account per repo, different secrets, or different prompt parts per fork. The platform is the same.


Credits

Built on OpenCode · GitHub Actions · GitHub Apps. MIT License, see LICENSE.

Made for the open-source community: Deploy in ten minutes; you keep your infrastructure and your keys.

About

Production-ready AI GitHub bot powered by OpenCode Automate issue analysis, PR reviews, and intelligent collaboration — completely free for open-source projects.

Resources

Security policy

Stars

24 stars

Watchers

0 watching

Forks

Contributors

Languages