Record Component
arch_record_componentRecord or update an architectural component by name, capturing its purpose, boundaries, stable code anchors, and neighbours so semantic code-search context stays current after refactors.
Instructions
Record (or update by name — idempotent) an architectural component. Use when you discover a logical unit not already in arch_context, or when an existing component's boundary changes. The summary field is structured markdown with four sections (Does / Owns / Does not / Touched when); anchors are stable exported symbol names that survive a refactor. Returns status created or updated.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Component name, unique per (group, project). Stable, refactor-resistant — e.g. "file indexer", not "Indexer (in indexer.ts)". | |
| files | No | Repository paths the component spans (e.g. packages/server/src/indexer.ts). | |
| group | Yes | Target group | |
| anchors | No | Exported class / function / constant names that survive refactors. Used later to verify the card is not pointing at deleted code. | |
| project | Yes | Required. Project the component belongs to — the same value the indexer writes as `payload.project` on code chunks (typically the repo directory basename). Components in the same group with the same name but different projects coexist independently. | |
| summary | Yes | Markdown with four sections, each one or two short lines: - **Does:** what it does - **Owns:** state / DB tables / external IO it controls - **Does not:** one or two things it explicitly does NOT do (boundary) - **Touched when:** what kind of change forces editing this component | |
| neighbours | No | Names of related components (matches `name` of other arch_record_component entries). |