Skip to main content
The contracted agent turns a GitHub issue into a pull request. You write the issue and label it mnemom. Mnemom checks the request, seals it as a contract and starts an agent on it. The agent opens a pull request against your repo. Then it keeps working on that pull request: it answers your reviews, your @mnemom-record comments and failed CI checks, until the pull request is merged or closed. The pull request follows your merge policies. It does not have to wait for a person: with the auto-merge setting the agent turns on GitHub auto-merge, and your branch protection decides when it merges. The agent never merges by itself. This guide is for the people who write the issues and review the pull requests. An owner or admin of your Mnemom org turns contracted agents on for a repo and sets the repo settings.

Before you start

  • Your Mnemom org has access. Mnemom durable agent and Mnemom contracted agents come with the Durable agent invite tier, enabled per Mnemom org by invitation. Ask for access at mnemom.ai/waitlist.
  • The repo is on for contracted agents in your Mnemom org, and the mnemom-record GitHub App is installed on it. See Set up the Mnemom record.
  • You have write access to the repo. Only an issue written by someone with write access is sealed.
  • The runner is the Mnemom CLI 0.18.0 or later. The runner workflow, .github/workflows/mnemom-agent-run.yml, pins the CLI version. Run mnemom record enable --check to see whether the pin is too old. An older runner still opens the pull request, but it does not act on feedback: Mnemom posts one comment on the pull request saying so, and the job ends when the pull request opens.

Label the issue mnemom

Only an issue that carries the mnemom label is a request. The label is matched without regard to case. The check reads the request the way a reviewer would. When something is missing, Mnemom sends the issue back: it posts one comment on the issue that tags you and lists what is missing. Nothing is sealed. Edit the issue to answer, and Mnemom checks it again. When the request passes, Mnemom seals it as a contract and posts one comment on the issue with the contract’s short sha256. An agent then starts and opens a pull request. Once an issue is sealed, the job runs from the sealed text. Editing the issue afterwards does not change the job.

Write a good issue

The agent works from your issue and nothing else, so the issue is the whole brief. A good issue has four parts. Tips:
  • Be specific. “Fix the login bug” is sent back. “POST /login returns 500 when the email has a plus sign; it must return 200” is not.
  • One job per issue. Split a large change into several issues.
  • Name the tests. If a test must be added, say where.
  • Put limits in a mnemom block, not in prose. Prose limits are not enforced.

Set limits with a mnemom block

You can add an optional fenced block to the issue body to set the job’s ceilings. The block is a code fence whose language is mnemom:
The fields: Rules:
  • One key: value per line. Keys are not case-sensitive.
  • Blank lines and lines starting with # are allowed.
  • Every key is optional. Leave out a key to keep the default for that ceiling.
  • Only the first mnemom block in the issue counts.
  • An unknown key or a bad value is never ignored. The issue is sent back with a comment naming the line. Fix it and edit the issue.
  • Each value must be within the contract’s own bounds. A value outside them is sent back the same way.
The limits are sealed into the contract with the rest of the request. The check that decides whether to send an issue back knows the limits come from the block, so it does not ask for them in prose. The block is taken out of the task text before the check reads it.

Issue template

Copy this into a new issue, or save it in your repo so it shows up in GitHub’s New issue list. To add it as a GitHub issue template, save it as .github/ISSUE_TEMPLATE/mnemom-job.md on your default branch. The labels: mnemom line in its header adds the label for you when someone opens an issue from it.
.github/ISSUE_TEMPLATE/mnemom-job.md
If you only want the label and not the template file, add the mnemom label by hand when you open the issue.

Do the same over MCP

The Mnemom MCP server’s seal_contracts tool submits the same request without a GitHub issue. It takes a batch of 1 to 50 contracts for one repo. Your MCP client sends your GitHub token as the X-GitHub-Token header, and Mnemom checks your write access to the repo with it. The token is never a tool argument. Each contract carries the same limits as structured fields: Set source to "mcp". Put the goal in statement, the acceptance items in requirements, and the scope in allowed_paths and forbidden_paths. Pass the request as you wrote it in request (title and body): the check compares the contract with it.
seal_contracts answers at once with an intake_id and the status judging. Call get_contract_intake until the status changes: The tool descriptions in your MCP client name every field, so an agent can discover them without this page.

After the pull request opens

The job does not end when the pull request opens. The agent waits on the pull request and wakes when there is something to act on.

What wakes the agent

An example of a steering comment:
On the pull request, @mnemom-record steers this job. It never starts a new request. To start a new job, open a new issue. When the agent wakes, it reads everything that arrived: review comments, your instructions, and for a failed check, its summary and the end of its log. It makes the change, runs the tests, commits and pushes. Then it replies on the pull request with what it changed and why. If the agent decides no change is needed, it replies with its answer and keeps waiting. A wake with no new commit never ends the job. Events that arrive while the agent is working are queued, never dropped. When it finishes, it wakes again at once and gets all of them together. Failed checks from one push are gathered too: a CI failure wakes the agent only once two minutes pass with no new failure, so it handles them in one wake. A review or an @mnemom-record comment wakes it at once.

The iteration limit

Each wake is one iteration, whatever woke it. The default limit is 10 iterations per job. An owner or admin can change it per repo (see Repo settings). When the job reaches the limit, it pauses. It does not end. Mnemom posts one comment on the pull request saying it stopped and how to continue. Reviews, comments and failed checks are still queued while it is paused. Anyone with write access can let it continue: The agent then wakes with everything queued while it was paused. A continue on its own never spends an iteration. Comments from bots and from people without write access are ignored. Mnemom keeps a record of who raised the limit, when and by how much.

When the job ends

A paused job ends the same way. The job is recorded and billed as finished when it ends. A comment after the end does not wake it: open a new issue for new work. The model the job started on stays the same for the whole job. A change to the repo’s model applies to new jobs only.

Repo settings

An owner or admin of the Mnemom org sets these per repo. A change applies at the job’s next wake, except the model, which applies to new jobs only. Besides the iteration limit, the runner has a separate wake count for the whole job, which also counts wakes that are not feedback (an answered question, a raised limit, a retry). It is the iteration limit plus 10, and never less than 20, so the iteration limit is always the one you reach first.

Over the API

For example, the body { "fix_iterations": 20, "checks_mode": "all", "merge_strategy": "auto-merge" } raises the limit, counts every failed check and turns on auto-merge.