Skip to content

Project context in Archcore

Project context is the knowledge recorded in your repository’s .archcore/ directory: what you intend to build, what the project has decided, and patterns learned from previous work. Agents discover and read it through MCP.

A project can begin with one rule or decision. Add structure when it helps describe the work; you do not need every document type or a complete requirements hierarchy before using Archcore.

Each document is a Markdown file named slug.type.md. The suffix identifies its document type. Frontmatter carries its title, status, and optional tags.

.archcore/
auth/
session-expiry.adr.md
token-validation.spec.md
conventions/
api-errors.rule.md
reporting/
export.plan.md

The directory layout is free-form. Keep documents at the root or group them by domain, feature, or team. You do not need vision/, knowledge/, and experience/ folders, and a document’s location does not determine its type or category.

The body is Markdown, not a rigid form enforced by the parser. The document type still supplies a content contract and writing conventions that the plugin follows. Free-form organization does not remove the filename, frontmatter, or type-specific requirements. Document format explains that distinction.

Archcore also manages settings.json for configuration and .sync-state.json for local document metadata and relations. Change relations through MCP instead of editing their storage file by hand. Configuration explains the settings.

A document’s type determines its category automatically.

CategoryQuestionExamples
VisionWhat are we trying to build or investigate?idea, prd, plan, rnd, research
KnowledgeWhat do we know, require, or propose?adr, rule, spec, rfc, guide, doc, evidence
ExperienceWhat pattern have we learned from work?task-type, cpat

These categories are not a required sequence. A rule can exist before a plan. A decision can change after new research. Document types provides the complete catalog and selection guidance.

StatusMeaning
draftWork in progress, awaiting review
acceptedReviewed and approved
rejectedDeclined or superseded, retained for its history

For an investigation, acceptance applies to its result: an rnd closes on a recommendation; a research closes on coverage of its scope. Accepting evidence confirms the material and recorded extract, not every claim someone could infer from it.

Review the content before changing status. Updating a relation does not change the document’s status automatically.

Relations record a directed connection between two documents. For example, a plan can implement its requirements through an implements relation, while a rule can be related to the decision behind it.

Relation typeDirection and meaning
implementsSpecific document to the requirement it fulfills
extendsNew document to the document it builds on
depends_onDependent document to the document it requires
relatedSource document to an associated document
supportsMaterial to the statement it supports
contradictsChallenger to the statement it disputes
supersedesNewer document to the document it replaces

The first four types are structural; supports and contradicts are evidential; supersedes is temporal. Source and target are distinct local documents. A relation cannot target a mounted global document.

Ask the agent to add the connection through add_relation:

Link the export plan to its requirements document with implements. Show me the source and target.

create_document does not add relations itself. Its nearby-document hint can help the agent identify candidates for a subsequent add_relation call. get_document returns incoming and outgoing relations, so the agent can inspect both directions.

SituationConnection
A plan fulfills product requirementsplan implements prd
An investigation needs a territory surveyrnd depends_on research
An external report backs a findingevidence supports research
A new decision replaces an old oneadr supersedes adr
A formal specification expresses stakeholder needsstrs implements urd

The requirements sources mrd, brd, and urd are peers; connect them with related. A specification can implement its source. PRD and ISO requirements documents can be associated with related rather than treated as successive mandatory steps.

By convention, a research document is not the source of implements or extends. These type-selection conventions guide authors; the engine validates relation values independently of document categories.

Keep a contradicts relation until the disputed document names the materials and records the resolution. Adding a supersedes relation also leaves the older document and its status unchanged.

The engine stores these connections; it does not resolve the dispute or move content. The evidential and temporal relation types do not trigger cascade notices. They require CLI 0.8.3 or later; older readers reject manifests containing them.

A global source exposes another context directory as read-only project context. For example, a team can share standards across repositories while each repository keeps its own decisions locally.

Local documents take precedence when they cover the same topic. Each returned document identifies its source, so the agent can distinguish shared defaults from local context. Writes and relations remain local.

Global sources are explicitly configured, mandatory when declared, and non-transitive: the project loads its direct sources rather than recursively loading their globals. Configure global sources covers paths, vendoring, and startup failures.