Create or update concept
upsert_conceptWrite a concept note into the vault (creates or overwrites the markdown file, then reindexes it). Use to capture new product knowledge discovered during a task — a decision made, a constraint hit, a pattern adopted — so future agents can find it. Omit id to derive a slug from the title; pass an existing id to update that note. Body is markdown; [[wiki-links]] to other concept ids create graph edges. Returns the saved concept's metadata.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | Concept id (slug). Omit to derive from title; pass an existing id to update. | |
| body | Yes | Markdown body. [[other-id]] wiki-links become graph edges. | |
| tags | No | Tags for filtering. | |
| type | No | Concept type (default "concept"). The 11 built-in types are concept, domain, feature, story, spec, workflow, task, decision, constraint, pattern, glossary; a vault may also define custom types. An unknown type falls back to "concept". | |
| title | Yes | Human-readable title (required, non-empty). | |
| doneAt | No | For tasks: ISO timestamp when completed. | |
| status | No | Lifecycle status (default "active"). | |
| product | No | Product grouping key. | |
| takenAt | No | For tasks: ISO timestamp when claimed. | |
| takenBy | No | For tasks: label of the agent/orchestrator that claimed it. | |
| codeAreas | No | Rough codebase paths/globs where this knowledge lives, e.g. ["packages/core/src/vault.ts", "apps/web/src/routes/**"] — lets agents briefed by get_context know where to apply it. | |
| relations | No | Typed edges, e.g. {"depends_on": ["auth-system"]}. Conventions: part_of (feature/story/task → domain), realized_by (story → features), realizes (task → stories/features), governs (spec → what it constrains), governed_by (task → specs), depends_on, constrains, supersedes, related_to. For domain concepts, prefer linking to OTHER domains (related_to / depends_on) wherever they share a boundary or hand off responsibility — connected domains reveal how the product's areas overlap instead of floating as isolated islands. | |
| taskStatus | No | For type="task" concepts: lifecycle "open" | "taken" | "done" (default "open"). Prefer the task tools (create_task / take_task / complete_task) over setting this directly. |