From claude-commands
Enforces Karpathy LLM Wiki pattern for ingesting sources, querying, linting, and building knowledge graphs in structured Markdown directories.
npx claudepluginhub joshuarweaver/cascade-code-general-misc-2 --plugin jleechanorg-claude-commandsThis skill uses the workspace's default tool permissions.
When working with an LLM wiki (Karpathy pattern) - ingesting sources, querying, linting, or building the knowledge graph.
Builds and maintains an LLM-curated personal knowledge base from sources like papers, articles, transcripts, and notes. Supports ingestion, querying accumulated notes, linting, auditing, and scaling.
Manages LLM-compiled knowledge bases in .wiki/ or ~/wiki/: ingests sources to raw/, compiles interconnected markdown articles with indexes, queries, lints, and supports topic sub-wikis.
Builds LLM-maintained markdown wikis for external knowledge from raw sources like articles and papers, supporting ingest, query, lint, and promote operations.
Share bugs, ideas, or general feedback.
When working with an LLM wiki (Karpathy pattern) - ingesting sources, querying, linting, or building the knowledge graph.
Enforces the exact Karpathy LLM Wiki pattern from https://gist.github.com/karpathy/442a6bf555914893e9891c11519de94f
llm_wiki/
├── raw/ # Immutable source documents (NEVER edit these)
├── wiki/ # LLM owns this layer entirely - single source of truth
│ ├── index.md # Catalog of ALL pages with curated one-line summaries
│ ├── log.md # Append-only chronological record (format: ## [YYYY-MM-DD] operation | title)
│ ├── overview.md # Living synthesis across all sources
│ ├── sources/ # Source summary pages (kebab-case.md)
│ ├── entities/ # Entity pages (TitleCase.md - people, companies, projects)
│ ├── concepts/ # Concept pages (TitleCase.md - ideas, methods, theories)
│ └── syntheses/ # Saved query answers
└── (no root-level wiki files - ALL must be under wiki/)
---
title: "Page Title"
type: source | entity | concept | synthesis
tags: []
sources: [] # list of source slugs that inform this page
last_updated: YYYY-MM-DD
---
json-display-bugs-analysis-report.md)PR278.md, OpenAI.md, SamAltman.md)StructuredResponse.md, RAG.md)Use [[PageName]] for internal links - these become the knowledge graph edges.
# Wiki Index
## Overview
- [Overview](overview.md) — one-line synthesis
## Sources
- [Source Title](sources/slug.md) — CURATED one-line summary (NOT raw email subject)
## Entities
- [Entity Name](entities/EntityName.md) — one-line description
## Concepts
- [Concept Name](concepts/ConceptName.md) — one-line description
## Syntheses
- [Analysis Title](syntheses/slug.md) — what question it answers
## [YYYY-MM-DD] operation | title
Key claims: ...
Operations: ingest, query, lint, graph
raw/wiki/index.md and wiki/overview.md for contextwiki/sources/<slug>.md with Source Page Formatwiki/index.md — add entry under correct sectionwiki/overview.md — revise synthesiswiki/log.md---
title: "Source Title"
type: source
tags: []
date: YYYY-MM-DD
source_file: raw/...
sources: []
last_updated: YYYY-MM-DD
---
## Summary
2–4 sentence summary.
## Key Claims
- Claim 1
- Claim 2
## Key Quotes
> "Quote here" — context
## Connections
- [[EntityName]] — how they relate
- [[ConceptName]] — how it connects
## Contradictions
- Contradicts [[OtherPage]] on: ...
wiki/index.md to find relevant pages[[PageName]] citationswiki/syntheses/<slug>.mdCheck for:
[[links]][[WikiLinks]] to non-existent pages[[wikilinks]] → deterministic EXTRACTED edgesINFERRED edges with confidencegraph/graph.json + graph/graph.htmlIf wiki exists in both root AND wiki/ subdirectory:
wiki/ subdirectory onlyindex.md, log.md, overview.md if duplicates existwiki/ subdirectoryIf index contains raw email subjects instead of curated summaries:
If few entity/concept pages created: