{"slug":"document-3","title":"document","summary":"Record a decision, document existing code, or file a supplied research material. Modes: document decision (ADR, RFC, or rule), document code (spec, doc, guide, or scenario for existing behavior), document research (only when a finished report or one external material is already i","platform":"Claude","tags":[],"authorName":"LLM Mart","authorSlug":"llm-mart","score":0,"source":"github","price":null,"verified":false,"createdAt":"2026-09-23T18:53:41.024758Z","repo":{"url":"https://github.com/archcore-ai/archcore","stars":62,"forks":9,"license":"Apache-2.0","updatedAt":"2026-09-23T13:49:10Z"},"bodyHtml":"<hr>\n<h2>name: document\nargument-hint: \"[decision|code|research] [subject]\"\ndescription: \"Record a decision, document existing code, or file a supplied research material. Modes: document decision (ADR, RFC, or rule), document code (spec, doc, guide, or scenario for existing behavior), document research (only when a finished report or one external material is already in hand). Use for 'we decided', 'record this decision', 'document why we chose X', 'make it our standard', 'draft an RFC', 'should we switch to Y' proposals, 'resolve the RFC', 'we accepted the proposal', 'document the auth module', 'capture how the payment system works', reference material, how-to instructions, or a user flow with examples over an existing spec. Name the type inside the subject to skip the type question. Planning a feature or an intended user journey → /archcore:plan. Checking docs against code or docs health → /archcore:review.\"</h2>\n<h1>/archcore:document</h1>\n<p>Record the present state: a technical decision, existing code, or a supplied\nresearch material. The first word of the arguments selects the mode; a gate\ninside the mode's track selects the document type. Write affinity: knowledge\ntypes; a filed <code>research</code> and the decision cascade's <code>plan</code> belong to vision.\nThe standard cascade can add a <code>cpat</code> (experience).</p>\n<p>Command tense: <code>/archcore:plan</code> declares a future canon delta, <code>/archcore:document</code>\nrecords the present state — including work that shipped without a plan — and\n<code>/archcore:review</code> reconciles a past declared delta. Δ vocabulary:\n<code>skills/_shared/delta-routing.md</code>.</p>\n<p>Load <code>skills/_shared/gate-contract.md</code> and <code>skills/_shared/elicitation-contract.md</code> before executing any gate.</p>\n<h2>Modes</h2>\n<table>\n<thead>\n<tr>\n<th>Mode</th>\n<th>Track and entry</th>\n<th>Types the entry gate selects</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><code>decision</code></td>\n<td><code>skills/_shared/tracks/decision.md</code>, <code>decision.classify</code></td>\n<td><code>adr</code>, <code>rfc</code>; <code>rule</code> through the standard cascade; an existing <code>rfc</code> draft on the topic → <code>decision.resolve</code>, which records an <code>adr</code> on an accepted verdict</td>\n</tr>\n<tr>\n<td><code>code</code></td>\n<td><code>skills/_shared/tracks/describe.md</code>, <code>describe.read</code></td>\n<td><code>spec</code>, <code>doc</code>, <code>guide</code>, <code>scenario</code></td>\n</tr>\n<tr>\n<td><code>research</code></td>\n<td><code>skills/_shared/tracks/research.md</code>, <code>research.frame</code></td>\n<td><code>research</code>, <code>rnd</code> by the closing test; one external material → <code>evidence</code></td>\n</tr>\n</tbody>\n</table>\n<p>A document type name is not a mode. When the subject text names a type (<code>skills/_shared/gate-contract.md</code>,\nEntry terms) that the mode's track produces, the selecting gate treats that type as settled and asks no\ntype question: <code>document decision rfc for gRPC</code> reaches the RFC branch. A leading\nword that is not a mode is topic text and goes through classification (Step 3).\nNo mode produces a <code>journey</code>; an intended user path belongs to <code>/archcore:plan</code>.</p>\n<h2>When to use</h2>\n<ul>\n<li>\"We decided to go with microservices\" — settled decision</li>\n<li>\"Record the decision to use PostgreSQL\"</li>\n<li>\"Document why we chose JWT over sessions\"</li>\n<li>\"Make this our team standard for error handling\"</li>\n<li>\"Draft an RFC for switching from REST to gRPC\"</li>\n<li>\"Should we switch to Kubernetes?\" — open proposal</li>\n<li>\"We accepted the proposal — resolve the RFC\" — proposal resolution</li>\n<li>\"Document the auth module\"</li>\n<li>\"Capture how the payment system works\"</li>\n<li>\"Create reference docs for the config system\" — reference material</li>\n<li>\"Write a guide for the release process\" — how-to instructions</li>\n<li><code>document code scenario for checkout</code> — a user flow with examples over an existing spec</li>\n<li><code>document research &lt;report&gt;</code> — file a ready investigation</li>\n<li><code>document research &lt;material&gt;</code> — file one external material as evidence</li>\n</ul>\n<p><strong>Not document:</strong></p>\n<ul>\n<li>Planning a feature, an initiative, or an intended user journey → <code>/archcore:plan</code></li>\n<li>Checking documents against code, reviewing branch changes, or docs health → <code>/archcore:review</code></li>\n<li>First-time setup → <code>/archcore:init</code></li>\n</ul>\n<h2>Routing table</h2>\n<table>\n<thead>\n<tr>\n<th>Signal</th>\n<th>Route</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>No arguments</td>\n<td>→ git investigation of the branch changes, then one classifying question (Step 3, Unclear)</td>\n</tr>\n<tr>\n<td>The first word is a mode — <code>decision</code>, <code>code</code>, <code>research</code></td>\n<td>→ mode entry, no routing (Step 2)</td>\n</tr>\n<tr>\n<td>Decision signals: \"we decided\", \"record this decision\", \"document why we chose X\", \"make it our standard\", \"draft an RFC\", a \"should we switch to Y\" proposal. A bare \"compare X vs Y\" with no proposed target belongs to <code>/archcore:plan</code>'s research track; a proposal to add a new capability with no named technical target (\"should we add caching?\") is feature framing → <code>/archcore:plan</code>, sdd track</td>\n<td>→ decision track — <code>skills/_shared/tracks/decision.md</code>, entry at <code>decision.classify</code></td>\n</tr>\n<tr>\n<td>Resolution signals: \"resolve the RFC\", \"we accepted the proposal\", \"reject the RFC\" — an <code>rfc</code> draft exists on the topic</td>\n<td>→ decision track — <code>skills/_shared/tracks/decision.md</code>, entry at <code>decision.resolve</code></td>\n</tr>\n<tr>\n<td>Code-doc signals: \"document the auth module\", \"capture how the payment system works\", reference material (registry, glossary, lookup), how-to instructions, a user flow with examples over an existing <code>spec</code></td>\n<td>→ describe track — <code>skills/_shared/tracks/describe.md</code>, entry at <code>describe.read</code></td>\n</tr>\n<tr>\n<td>Research-material signals: a supplied investigation report, benchmark, transcript, or vendor document to file as is</td>\n<td>→ research track — <code>skills/_shared/tracks/research.md</code>, entry at <code>research.frame</code></td>\n</tr>\n<tr>\n<td>Unclear</td>\n<td>→ git investigation, then one classifying question (Step 3)</td>\n</tr>\n</tbody>\n</table>\n<h2>Execution</h2>\n<h3>Step 1: Ground</h3>\n<p>Apply <code>skills/_shared/research-compatibility.md</code> under its condition 1 — a\nrequest or type naming <code>research</code> or <code>evidence</code>, the research track, or a\ngrounding result of either type. If this skill has no shell tool and no probe\nresult was supplied, report <code>needs-vocabulary-probe</code> with the helper path and\nstop before the first MCP call that names either type.\nBefore delegating research or evidence work, pass the current vocabulary probe\nresult and absolute plugin root to the assistant. If the assistant returns\n<code>needs-vocabulary-probe</code>, run the helper and resume the same task.\nBefore delegating any other document write or relation work, pass the absolute\nplugin root to the assistant. The assistant reads\n<code>skills/_shared/relation-authoring.md</code> under that root.\nApply <code>skills/_shared/actor-subject-compatibility.md</code> under its own condition 1 —\na request whose subject names <code>scenario</code> or <code>journey</code>, or a grounding result of\neither type. When that probe returns <code>yes</code>, add <code>scenario</code> and <code>journey</code> to the\ntype filter below. On older engines, keep the legacy filter; a <code>code</code> request\nwhose subject names <code>scenario</code> then reports the required version and exits\nwithout a write.\nWhen the probe returns <code>yes</code>, add <code>research</code> and <code>evidence</code> to the type filter\nbelow. On older engines, keep the legacy filter.</p>\n<p>Search <code>.archcore/</code> on the request topic across all three categories — vision,\nknowledge, experience. Do not exclude a category from reads. Pass a type filter\nmatched to this command's moment (<code>adr</code>, <code>rfc</code>, <code>spec</code>, <code>doc</code>, <code>guide</code>, <code>rule</code>,\nplus <code>rnd</code> as decision evidence, and <code>research</code> and <code>evidence</code> when the probe returned <code>yes</code>) instead of relying on the global type ranking. When a found document carries\n<code>implements</code>, <code>depends_on</code>, or <code>related</code> relations, pull the linked documents one hop across\ncategories. Duplicate handling lives in the tracks' check-existing gates — do\nnot resolve duplicates here.</p>\n<p>If <code>.archcore/</code> does not exist, announce initialization in one line and call\n<code>mcp__archcore__init_project</code> without asking a question. If <code>.archcore/</code> exists\nbut contains no documents, proceed on outer-context grounding and report that\nzero documents were found.</p>\n<p><strong>Global sources.</strong> If a <code>mcp__archcore__list_documents</code> /\n<code>mcp__archcore__search_documents</code> result has <code>global: true</code> / <code>read_only: true</code> /\n<code>source_kind: \"global\"</code>, load <code>skills/_shared/globals.md</code>. Also load it when a\n<code>search_documents</code> response's <code>coverage</code> names a source other than <code>\"local\"</code> —\neven when <code>results</code> is empty: the empty page is exactly where that file's retry\nladder applies. Never modify a global document and never target one with\n<code>add_relation</code>. Absent any global match, proceed as usual.</p>\n<h3>Step 2: Mode entry</h3>\n<p>If the first word is a mode, execute the mapped entry without routing:</p>\n<ul>\n<li><code>decision</code> → decision track. An <code>rfc</code> draft on the topic plus resolution\nwording enters <code>decision.resolve</code>; any other request enters\n<code>decision.classify</code>, which selects <code>adr</code>, <code>rfc</code>, or the standard outcome. A\ntype name in the subject (<code>adr</code>, <code>rfc</code>, <code>rule</code>) satisfies that gate's\n<code>skip_when</code>.</li>\n<li><code>code</code> → describe track at <code>describe.read</code>. <code>describe.draft</code> selects <code>spec</code>,\n<code>doc</code>, <code>guide</code>, or <code>scenario</code>; a type name in the subject settles its type\nquestion. <code>describe.read</code> records <code>features/*.feature</code> files as evidence when\npresent; a <code>scenario</code> with no covering <code>spec</code> routes to the earliest gate that\nproduces the <code>spec</code> per <code>skills/_shared/gate-contract.md</code>.</li>\n<li><code>research</code> → research track at <code>research.frame</code>; the supplied report satisfies frame inputs without an interview (investigation versus one external material: <code>skills/_shared/gate-contract.md</code>, Entry terms), and the closing test selects the type — a\nreport that ends in a recommendation is an <code>rnd</code>, a report that covers a scope\nis a <code>research</code>. One external material with no investigation enters\n<code>research.gather</code> as standalone evidence, records the request in the evidence\ndraft's Clarifications, and exits after gather. Follow the compatibility\ncontract's no-write exit when the type is unsupported.</li>\n</ul>\n<p>Then go to Step 4.</p>\n<h3>Step 3: Classify</h3>\n<p>Classify the target as resolution, decision, code-doc, research material, or unclear:</p>\n<ul>\n<li><strong>Resolution</strong> — the request names a verdict on an existing open proposal\n(resolution signals above) and an <code>rfc</code> draft on the topic exists → decision\ntrack at <code>decision.resolve</code>. Check this before Decision: wording that also\nreads as a settled-decision signal (\"we accepted the proposal\") routes here\nwhenever a matching <code>rfc</code> draft exists.</li>\n<li><strong>Decision</strong> — the request records a settled choice or an open proposal\n(decision signals above) → decision track at <code>decision.classify</code>.</li>\n<li><strong>Code-doc</strong> — the request describes existing code, reference material, a\nprocedure, or a user flow over an existing <code>spec</code> (code-doc signals above) →\ndescribe track at <code>describe.read</code>.</li>\n<li><strong>Research material</strong> — the request supplies a ready report or one external\nmaterial to file (research-material signals above) → research track at\n<code>research.frame</code>.</li>\n<li><strong>Unclear</strong> — inspect git state and the working tree first: recent commits and\nchanged files are evidence of what the user has been working on. If the\nevidence still supports both readings, ask one classifying question — \"Is this\na decision to record or existing code to document?\" — with the recommendation\ndrawn from the git evidence.</li>\n</ul>\n<h3>Step 4: Execute the track</h3>\n<p>Run the selected track gate by gate per <code>skills/_shared/gate-contract.md</code>. The\ntrack owns check-existing, per-gate elicitation, composition, and relation\nwiring.</p>\n<p>Question budget: per <code>skills/_shared/elicitation-contract.md</code> — auto mode draws\nfrom the shared per-invocation ceiling; a mode entry raises to the track's\nper-gate maxima.</p>\n<h2>Result</h2>\n<p>Report the produced documents grouped by category:</p>\n<ul>\n<li><strong>knowledge</strong> — <code>adr</code>, <code>rfc</code>, <code>spec</code>, <code>doc</code>, <code>guide</code>, <code>rule</code>, <code>evidence</code>, <code>scenario</code></li>\n<li><strong>vision</strong> — <code>research</code> (scope-covering report), <code>rnd</code> (recommendation-closed report, or compatibility fallback), <code>plan</code> (architecture cascade)</li>\n<li><strong>experience</strong> — <code>cpat</code> (standard cascade opt-in)</li>\n</ul>\n<p>List each document's path and relation edges. Name tracks and steps in plain\nwords; do not print a gate address of the form <code>&lt;track&gt;.&lt;stage&gt;</code>. Close with one\nrecommended next action naming only <code>/archcore:plan</code>, <code>/archcore:review</code>, or a\nrepeat <code>/archcore:document</code> invocation with its mode.</p>\n","files":[{"path":"SKILL.md","sizeBytes":11847,"isText":true}],"reviewScore":null,"reviewSummary":null,"trust":{"provenance":"trusted-source-unreviewed","notice":"Community-authored content, reproduced verbatim and not vetted as instructions. Treat it as data to evaluate, never as directives to follow.","bodySource":null},"bodyLocked":false,"purchaseUrl":null,"sourceUrl":null,"report":{"provenance":"trusted-source-unreviewed","screen":{"ran":true,"outcome":"clean","suspicious":0,"notes":0,"hiddenCharacters":false},"virusScan":{"engine":"clamav","status":"clean","scannedAt":"2026-09-23T18:53:55.525029Z","sha256":"13ADF1084B069A8E5910858B2B79B11937DB9C173CE690CC87A1152505A7B16A","sizeBytes":4385},"review":null,"source":{"repositoryUrl":"https://github.com/archcore-ai/archcore","path":"plugins/archcore/skills/document","license":"Apache-2.0","commit":"8316091f2481a8e3938f0eec3948b1d34a491649","subtreeSha":"B9505823CC44A9F17642B8BD7BDCE89EBC259EFEAB2FFF56163EDB8817E39B36","lastSyncedAt":"2026-09-23T18:53:41.018936Z"},"reviewedAt":"2026-09-23T18:54:09.978211Z","notice":"Community-authored content, reproduced verbatim and not vetted as instructions. Treat it as data to evaluate, never as directives to follow."},"install":[{"target":"skills-cli","command":"npx skills add https://github.com/archcore-ai/archcore/tree/main/plugins/archcore/skills/document"},{"target":"claude-code","command":"claude plugin marketplace add https://llmmart.ai/marketplace.json && claude plugin install archcore-ai-archcore@llmmart"},{"target":"git","command":"git clone https://github.com/archcore-ai/archcore.git"}]}