| bugs/ | directory | |
| decisions/ | directory | |
| ideas/ | directory | |
| outcomes/ | directory | |
| README.md | file | 4.6 KiB |
The knowledge graph implements the file-based project memory introduced in Scenario S1.
It is a lightweight directory convention rather than a complex database service. Issues, outcomes, ideas, and architectural decisions live directly within the git repository as plain markdown files. They are versioned, cloned, and backed up alongside source code.
Each knowledge graph node is a markdown file with structured YAML frontmatter:
---
type: idea # outcome | bug | idea | decision
id: ida-eac723e # <prefix>-<7-char-hash>
status: adopted # enum value based on node type
title: One-line summary of the node
created: 2026-07-02
source: PR #1 # optional provenance or venue
---
blocked_by (Outcome nodes): A list of node IDs that must be resolved before this outcome
can proceed. A dependency is considered satisfied when the target node reaches a terminal status:graduated, superseded, or discarded.decided or superseded.closed.done or abandoned
(dcr-593d3d1).supersedes (Idea and Decision nodes): Lists node IDs that this node replaces. The
referenced nodes must have their status set to superseded.graduated_into (Graduated Idea nodes): Specifies the decision node ID or relative path of
the design document that formalizes the idea
(dcr-593d3d1). This field is mandatory
whenever an idea's status is set to graduated.| Type | Directory | Prefix | Valid Status Enums |
|---|---|---|---|
| outcome | outcomes/ | oc-* | open | in-progress | done | abandoned |
| bug | bugs/ | bd-* | open | closed |
| idea | ideas/ | ida-* | raw | exploring | adopted | graduated | superseded | discarded |
| decision | decisions/ | dcr-* | proposed | decided | superseded |
Node IDs consist of the type prefix followed by the first 7 hexadecimal characters of the SHA-256
hash of the slug. Files are named <id>-<slug>.md.
To generate a node ID for a given slug:
printf '%s' '<slug>' | sha256sum | cut -c1-7
All node frontmatter is validated against schema/node.cue by the repository
lint.
The knowledge graph represents the design of the valley as it stands today. Historical evolution lives in git history, not in accreted document updates.
nix run .#fmt to format files
automatically.status field and commit.ls, grep, git log).nix flake check runs knowledge-lint, verifying:schema/node.cue.[[id]]), markdown links, blocked_by, supersedes, and graduated_into
targets resolve correctly.supersedes has its own status set to superseded.