Convert arbitrary codebases into structured Obsidian wikis with human-in-the-loop iterative refinement. Use when user asks to analyze, document, or create a wiki for a codebase...
Convert codebases into structured, navigable Obsidian knowledge graphs through iterative collaboration with the user.
.wiki-progress.mdThe .wiki-progress.md file captures all decisions immediately after they are made. This enables continuation from any interruption point. After each checkpoint: record the decision, update status fields, log the session action.
On every invocation, determine the current phase:
1. Check: Does wiki exist at target path?
├─ NO → PHASE: Fresh (Planning)
└─ YES → Check: .wiki-progress.md exists and valid?
├─ YES, status: debugging → PHASE: Debug (Fix)
├─ YES, status: complete → Ask user intent (extend? debug?)
└─ OTHERWISE → PHASE: Midway (Continue)
Midway handles all continuation scenarios: valid in-progress state, missing progress file, or malformed progress file. Read whatever state exists (or infer from wiki structure) and continue.
User-defined depth (not enforced to 3 levels). Work top-down: define higher levels first, approach granularity iteratively.
wiki-root/
├── HOME.md # Codebase level (mermaid + index paragraph)
├── .wiki-progress.md # Progress tracking (hidden)
├── ModuleA/
│ ├── ModuleA.md # Module narrative (mermaid + index paragraph)
│ ├── node1.md # Atomic node
│ └── SubModule/ # Optional deeper nesting
│ ├── SubModule.md # Sub-narrative
│ └── subnode.md
└── ModuleB/
└── ...
Rules:
<Module>.md in their folderFour node kinds exist. See references/templates.md for full frontmatter schemas.
| Kind | Description | Source Field |
|---|---|---|
code-bound |
1:1 mapping to file/function/class | path + function/class |
code-spanning |
Concept across multiple files | Multiple path entries |
conceptual |
No direct code (math, architecture) | Optional related_code globs |
external |
Third-party dependencies | package + version |
STEP 1: Initial Scan
.wiki-progress.mdSTEP 2: Module Definition (Top-Down)
.wiki-progress.mdSTEP 3: Granularity Calibration
.wiki-progress.mdSTEP 4: Configuration Options
tested_by, last_reviewed, complexity.wiki-progress.mdSTEP 5: Generate Plan
.wiki-progress.md with full checklist (status: in-progress)STEP 1: Load State
IF .wiki-progress.md exists and valid:
ELSE (missing or malformed):
.wiki-progress.md from inferred stateSTEP 2: Document Batch
.wiki-progress.md after each nodeSTEP 3: Checkpoint
STEP 1: Diagnosis
broken_links: Note references non-existent noteorphan_notes: Not linked from any parentstale_notes: Source file no longer exists or was renamedmissing_notes: Code exists, no documentationstructural: Wrong hierarchy levelSTEP 2: Plan Proposal
.wiki-progress.md (status: debugging)STEP 3: Execute
.wiki-progress.md after each fixSTEP 4: Completion
Non-atomic notes MUST include a narrative paragraph with embedded wikilinks serving as both documentation AND navigation:
## Overview
The Authentication module handles user identity verification and session
management. It consists of [[validateToken]] for JWT verification,
[[refreshSession]] for token renewal, [[logout]] for session termination,
and [[authMiddleware]] which guards protected routes. This module depends
on [[Database]] for user lookups and [[Config]] for secret management.
Narratives are composable: module narratives can be referenced from higher levels (e.g., [[Vision Module|visual perception]] in HOME.md).
All non-atomic levels MUST include a mermaid graph. External dependencies MUST be visually distinguished using CSS class + subgraph.
See references/mermaid-patterns.md for:
When user enables test coverage:
## Tests
| Test | Description | Status |
|------|-------------|--------|
| `test_validate_valid_token` | Accepts well-formed JWT | ✅ |
| `test_validate_expired` | Rejects expired tokens | ✅ |