Skip to main content

Research a topic and run a review pass

Research and the review pass both find problems in a knowledge base. To decide on one question where the documents point in different directions, research the topic first. To look over the whole knowledge base, run a review pass on a regular schedule.

Research a topic​

The research-topic skill gives you a brief: a map of where the documents disagree. You then settle each disagreement, one question at a time. The agent never picks a side for you. For how the agent finds the disagreements, see Research: a map of a topic before you decide.

If the decision is already made, record it instead: see Record one document.

Get the brief​

  1. Run the skill with the initiative and a question that a decision can answer:

    /reasonry:research-topic INITIATIVE: QUESTION

    Phrase the question as a choice, such as "Should fares use zones or one flat fare?" If you ask for a summary, the skill stops, because a summary isn't a decision.

  2. Confirm the question and the boundary. The agent restates your question and says what the brief leaves out. The agent reads nothing before you confirm.

  3. Read the brief, and start with the section "Tension axes". Each axis is one choice that the documents force on you. The following excerpt comes from a brief on Reasonry's test knowledge base, which belongs to a fictional tram operator. The excerpt is shortened:

    #### Axis 1: Zone fares (DEC-VT-0001) or a single flat fare (DEC-VT-0002)

    | | Branch A — Zones | Branch B — Flat fare |
    | - | ---------------- | --------------------- |
    | **Evidence weight** | One active evidence document, cited directly: EVID-VT-0002 (outer-stop trips average 6.2 km vs 2.9 km inside the ring) | No evidence document cited or found. |

    **Discriminating situation:** A rider boards at an outer-zone stop and rides to an inner-zone stop. Under DEC-VT-0001 they pay 2.60 marks because the trip crosses the ring. Under DEC-VT-0002 they pay the flat 2.20 marks regardless.

    The brief has three more sections:

    • Inventory: Every document that the agent read.
    • Inherited and invented: For each possible rule, the parts that a document already states, and the parts that you add yourself.
    • Coverage: What the agent left unread, and why.

    If the brief has no axes, the documents agree, and you can decide without a choice to make.

  4. Say whether to keep the brief. The agent saves a brief that you keep as source/raw/YYYY-MM-DD-TOPIC-brief.md. Files in source/raw/ aren't documents, so a saved brief changes no decision.

Settle the choices​

After the brief, the agent asks whether to settle the axes in the same conversation. To settle them later, run the skill again with the path of the saved brief.

  1. Answer one axis at a time. Each question gives the choice, the documents on each side, the cost of each option, and the agent's recommendation. You can settle an axis, defer it, or drop it with a reason.
  2. Review the draft decisions that the agent writes from your answers.

Each draft is a proposal. To put a draft into force, see Accept a decision.

Keep a disagreement visible​

If the brief shows two documents that contradict each other, and you aren't ready to decide, ask the agent to file a report. The next review pass brings the report back to you.

Run a review pass​

A review pass finds what the automatic check can't: an open question that a decision already answered, documents that contradict each other, evidence with no decision, and conclusions whose evidence changed. The sweep-corpus skill runs the pass in one conversation. The agent proposes, and nothing changes until you approve.

Run a pass on a regular schedule, such as weekly or monthly, and after a large change to the knowledge base. To let a scheduler start the pass, see Run the pass on a schedule with Claude Code.

Run the pass​

  1. Run the skill. To narrow the pass, add the steps, the initiatives, or a topic in plain words, such as "only open decisions" or "skip the wiki":

    /reasonry:sweep-corpus
  2. Give the date of the previous pass. The agent uses the date to find what changed. If you don't have the date, the agent takes the last 30 days. On a first pass, the agent checks every binding decision and every binding piece of evidence.

  3. Confirm the scope. The agent says which steps and which initiatives the pass covers.

  4. Answer the questions, one at a time. Each question proposes one status change, with the documents behind it, a quote, and a recommendation. For an example of a proposal, see the excerpt in Act on the report.

  5. Review the plan. Every proposal that changes no status arrives in one numbered list. Each line has its reason, its sources, and the skill that applies it. Approve the list, strike lines by number, or change a line.

  6. Read the result. The agent applies what you approved, validates the knowledge base, and reports what changed.

Choose the steps​

The pass has 7 steps. Each one can run alone: name it in step 1 of the preceding section.

  1. Open decisions: Open questions and draft decisions, each with a proposed outcome. For an open question, the outcome is resolve, record, reject, or keep. For a draft decision, it's accept, accept after a named condition is met, reject, or keep.
  2. Open reports: Each open report, with a proposal to act on it, decline it, or keep it open.
  3. Contradictions and redundancy: Documents in one initiative that contradict each other or say the same thing.
  4. Gaps in the graph: Subjects that no document governs, such as evidence that agrees on an approach with no decision. Also related documents that don't link to each other.
  5. Drift in conclusions: Citations in output/ of a document that is no longer in force, and places that still state a figure or follow a rule that a later document replaced.
  6. Stale wiki pages: Pages whose sources changed after the page was written.
  7. Artifact candidates: Rules, skills, subagents, or hooks that could enforce a decision. You write each one with your own tool, and the pass records which candidates you want.

For how the agent finds each of these, see The review pass: what an automatic check misses.

Read the result​

The result arrives in the chat with these parts:

  • The scope: the steps and the initiatives that ran, and the ones that the pass skipped.
  • Each question, your answer, and what the agent applied.
  • The lines of the plan that you approved, struck, and changed.
  • What the pass couldn't check, and why.
  • The final validation, with the warnings that the pass's own changes caused. For example, a wiki page is stale after the pass changed one of its sources.

To keep a record of the pass, ask the agent to save the result in output/documents/. Write down the date of the pass, because the following pass needs it.

Run the pass on a schedule with Claude Code​

A scheduler can start the pass with a headless run of Claude Code: a run that reads its prompt from a file, works without a person in the conversation, and prints its answer. Every Reasonry skill asks you before it changes a status or writes a document, and a headless run has nobody to answer. Split the work in two: the scheduled run finds and reports, and you read the report and run the same skill in an interactive session to decide and apply. The prompt tells the agent to stop at the first question and to report every finding with its sources.

Caution: Don't ask a headless run to accept decisions or to apply a plan. The challenge gate depends on a person's answers, and a headless run has nobody to give them. A run that reaches the gate reports its findings and leaves the decision as a draft.

What the scheduled run needs​

The machine that runs the schedule needs Claude Code, Node.js 22.18 or later, and the Reasonry plugin, installed in the knowledge base: see Install Reasonry. A headless run loads an installed plugin, and it doesn't prompt to install one.

Write the prompt​

Save the prompt as a file in the knowledge base, such as scripts/weekly-pass-prompt.md. State the limits first, and then the task. The following prompt runs the first step of the review pass for one initiative:

This is an unattended run in a knowledge base. Nobody can answer questions. Follow the procedure
up to the point where it asks the person a question, then report every finding with the document
IDs and the quotes that support it, and stop. Don't write, change, or delete any file.

Run /reasonry:sweep-corpus with only step 1, open decisions, for the initiative team-tooling. The
previous pass was on 2026-01-12.

Name the steps and the initiatives that the run covers, because a full pass over a large knowledge base takes longer and costs more than a narrow one. For the 7 steps, see Choose the steps. Put the date of the previous pass in the prompt, or let the script that starts the run fill it in.

Start the run​

In the knowledge base's folder, start the run with the prompt file as input. The following commands save the report as raw material, in a file that carries the date of the run:

report=$(mktemp)
claude -p --add-dir ~/.claude/plugins/cache/reasonry --allowedTools mcp__plugin_reasonry_reasonry-keeper --max-budget-usd 5 < PROMPT_FILE > "$report" && mv "$report" "source/raw/$(date +%F)-review-pass.md"

Replace PROMPT_FILE with the prompt's path. The report goes to a temporary file first, so that the run doesn't read its own unfinished report, and so that a run that fails leaves no file in the knowledge base.

The options do the following:

  • -p makes the run headless.
  • --add-dir lets the run read the skills' own files. Claude Code keeps an installed plugin in the ~/.claude/plugins/cache/ folder, which is outside the knowledge base. Without the option, the run can't read those files, and it works without the instructions for its read-only agents. If you added the marketplace from a folder on your machine, Claude Code loads the plugin from that folder: pass that folder.
  • --allowedTools approves the tools of the plugin's reasonry-keeper server, so that the run doesn't stop at a permission prompt.
  • --max-budget-usd caps what the run can spend, in US dollars.

Schedule the run​

Use the scheduler that you have: cron, a scheduled workflow in continuous integration, or the scheduled tasks of your AI coding tool. For example, the following crontab entry starts a script every Monday at 9 AM. Replace KB_DIR with the knowledge base's path:

0 9 * * 1 cd KB_DIR && ./scripts/weekly-pass.sh

The script needs three things:

  • The two commands from the preceding section.

  • The full paths of claude and node, or a PATH setting, because a scheduler starts with a small environment.

  • A rebuild of the graph before the claude command. The prompt forbids the run to write files, and a rebuild writes the graph.json file, so a run that follows the prompt works with the graph that it finds:

    npx -y @push-based/reasonry@2 graph build

Check what the run did​

The approved tools include the ones that change documents, and the prompt is the only thing that keeps the run from calling them. After each run, confirm that the run changed no file. The following command lists what changed in the working tree:

git status --short

The output has one line for the report, such as ?? source/raw/2026-01-19-review-pass.md. If git tracks graph.json, the rebuild in the script leaves a second line, M graph.json. Any other line names a file that the run changed in spite of the prompt.

For more safety, run the scheduled job in a copy of the knowledge base, such as a separate clone or a git worktree, and not in the folder where people work.

Act on the report​

The report lists each finding with the documents that support it. The following excerpt comes from the report of a headless run of step 1 on Reasonry's test knowledge base, which belongs to a fictional tram operator. The excerpt is shortened:

## Sweep pass — step 1 (open decisions) — test-initiative

### Inventory taken

- Open questions: Q-VT-0001, Q-VT-0002, Q-VT-0003, Q-VT-0004
- Draft decisions: DEC-VT-0006, DEC-VT-0007

**1. Q-VT-0001 → `resolve`**
- Resolved by: **DEC-VT-0003** (accepted, 2026-05-04).

**Q-VT-0002 — `keep`**
- Reason: No accepted decision proposes a staffing model. DEC-VT-0007 depends on this question but is itself still draft, so it can't settle it.

After you read the report, run the pass in an interactive session with the same scope. The agent finds the same items again and asks you each question. Commit the report with the changes that it led to, so that the knowledge base keeps what each pass found.

Schedule the pass in another tool​

The same split works in any AI coding tool that has a headless mode, with these changes:

  • Install the skills and the reasonry-keeper server for the tool: see Install Reasonry in another AI coding tool.
  • Use the same prompt. It names the limits and the skill, and neither depends on the tool.
  • In the tool's own configuration, approve the tools of the reasonry-keeper server.
  • Start the tool's headless mode in the knowledge base's folder, and save its output in the source/raw/ folder.

For the headless mode and the permission settings, see the tool's own documentation.