diff --git a/AGENTS.md b/AGENTS.md index 2caec16..cbd112b 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,99 +1,8 @@ # LLM Wiki — Agent Instructions -You are a wiki maintainer. This repo is a personal knowledge base you build and -maintain incrementally. You never modify files in `raw/`. You own everything in -`wiki/`. - -## Directory layout - -``` -raw/ Source documents (immutable — read only) -raw/assets/ Images, PDFs, attachments -wiki/ Your domain — create, edit, maintain freely -wiki/index.md Catalog of all wiki pages (you maintain this) -wiki/log.md Append-only operation log (you maintain this) -``` - -## Page schema - -Every wiki page must have YAML frontmatter: - -```yaml ---- -type: concept | entity | source | synthesis | comparison -title: "" -tags: [] -sources: [] # filenames from raw/ that support this page -related: [] # wiki page filenames this page links to -updated: YYYY-MM-DD -confidence: high | medium | low ---- -``` - -For `updated`, always use a tool to get the current date - never hardcode or -guess it. For any measurement or metric field, always use a tool to retrieve or -compute the value rather than estimating. - -Follow the frontmatter with a one-paragraph summary, then the body. - -## Operations - -### ingest \ - -1. Read the source file in `raw/`. -2. Discuss key takeaways with the user. -3. Write `wiki/src-.md` (type: source) summarizing the source. -4. For each significant entity or concept: find or create its wiki page, update - it with new information, update `sources:` and `related:` frontmatter. -5. Note contradictions with existing pages explicitly in the relevant pages. -6. Update `wiki/index.md` — add new pages, update summaries of changed pages. -7. Append to `wiki/log.md`: - ``` - ## [YYYY-MM-DD] ingest | - Pages created: ... - Pages updated: ... - ``` - -### query \ - -1. Read `wiki/index.md` to identify relevant pages. -2. Read those pages. -3. Synthesize an answer with citations linking to wiki pages. -4. Ask the user: "File this as a new wiki page?" If yes, write it as type: - synthesis and update the index. -5. Append to `wiki/log.md`: - ``` - ## [YYYY-MM-DD] query | - Pages read: ... - Filed: yes/no - ``` - -### lint - -1. Read all pages in `wiki/`. -2. Report: - - Contradictions between pages - - Orphan pages with no inbound links - - Concepts mentioned but lacking their own page - - Missing `related:` cross-references - - Low-confidence claims without a source -3. For each issue, propose a fix. Apply fixes the user approves. -4. Append to `wiki/log.md`: - ``` - ## [YYYY-MM-DD] lint - Issues found: ... - Fixed: ... - ``` - -## Conventions - -- Filenames: lowercase hyphenated slugs — `transformer-architecture.md` -- Source summaries: prefix `src-` — `src-attention-is-all-you-need.md` -- Never delete a wiki page without user confirmation -- When a concept lacks a source, create a stub and mark `confidence: low` rather - than leaving it undocumented -- `wiki/index.md` is sorted by type, then alphabetically within each type -- `wiki/log.md` entries start with `## [YYYY-MM-DD]` so they are grep-parseable +This repo is a personal knowledge base. Wiki operations are handled by the +`llmwiki` skill (see `.pi/skills/llmwiki/SKILL.md`). Never modify files in +`raw/`; you own everything in `wiki/`. ## Shell Scripts