nakad.ai๐Ÿ”ฑ๐Ÿฆ๐Ÿ›ก๏ธ๐Ÿฏ๐Ÿ“ฟ's avatar
nakad.ai๐Ÿ”ฑ๐Ÿฆ๐Ÿ›ก๏ธ๐Ÿฏ๐Ÿ“ฟ
nakadaimon@iris.to
npub1sqax...r45v
Substack: https://nakadai.substack.com
image AUTO GRAPH WIKI Skill extension of LLM-Wiki by karpathy โ€” 20x performance when querying LLM-wikis. Automated regeneration of wiki graph from frontmatter. You never type a script name. You ask in natural language; the agent runs the right thing. I did some tests querying my Wiki and I was astonished by the results. ~500 tokens instead of ~10 000 for a full-file read. How you run it The skill is a folder of Python scripts. You point your agent at the folder and let it run the right script when you ask. Drop the folder into your host's skills directory; the host parses SKILL.md, learns the triggers, and dispatches scripts on your behalf. image Quick start 1. Configure your wiki paths 2. Build the initial index (one-time) 3. Search That's the whole loop. Edit your wiki freely from this point on. Every search.py call re-checks freshness and rebuilds if needed. image Optional follow-ups - Generate a derived overview page (frontmatter table grouped by domain) - Find broken wiki-links - Check freshness manually (mtime + schema-version drift) image Frontmatter that makes the graph sharp The skill quality goes up sharply when notes carry the right metadata. The fields below are what search.py, links.py, broken.py, and generate_index.py actually read. image Minimal frontmatter example image Three principles for frontmatter Consistency beats completeness. A wiki where every page has summary, keywords, and aliases filled in โ€” even minimally โ€” outperforms one where some pages have rich frontmatter & others have none. The graph is only as good as its sparsest section. Aliases are how the graph knows what your pages are called. A page named quarterly-revenue-by-segment won't backlink from [[Quarterly revenue]] in prose unless Quarterly revenue is listed in its aliases. Add aliases for the words you actually use when referring to the page. Related: is curated graph context. Inline [[wiki-links]] in the body capture intention at a moment. Frontmatter related: captures the page's permanent neighbors. Both end up in the graph; both add value; they are not the same. The auto part? Indexes regenerate automatically when frontmatter changes โ€” there's no migration step. Auto-reindexing The skill name is "auto" because indexing is automatic at three points: Lazy at search. Every search.py call checks index freshness. If any wiki file is newer than the index, search rebuilds before returning. Active at lint. freshness.py --auto-fix rebuilds stale indexes on demand. Wire this into your host harness's lint pipeline. Coupled at ingest. Whatever pipeline writes new pages to the wiki should run reindex.py as final step. Documented in command file. A correctly integrated install means you never type "reindex" by hand. Trade-offs TF-IDF is keyword-based. A query for "compliance" will not match a wiki that uses "regulation". The augmentation rewards consistent vocabulary in the source โ€” consider it a feature. Indexes are rebuilt from scratch. Not incremental. For wikis up to a few thousand pages this is fine โ€” full reindex completes in a couple of seconds. For larger wikis, incremental indexing would need to be added JSON indexes are not for humans. They are fuel for search.py. Do not open them in a markdown editor. For contributors Run the test suite: Tests cover the edge-case vault under examples/edge-cases/. Pytest is a test-time dependency only โ€” the runtime is Python-standalone with no third-party packages. What this is not This is a retrieval layer for already-curated knowledge. If your wiki is unstructured โ€” no frontmatter, inconsistent terminology, no manual organization โ€” the augmentation will not save you. The discipline of writing the wiki is what makes the cheap retrieval possible. This is also not a knowledge graph extractor. If you have unfamiliar material (a codebase you didn't write, papers you haven't read), you need extraction tools, not retrieval tools. Different problem. Want to support my work, you can zap me.
image #SYMBIOSIS 2 is out! Frictionless onboarding! Refactored architecture! New features! Examples examples examples Get the gist here: The 1st version of my Symbiosis manifesto worked as an essay but failed as a bootstrap. I simulated a real user trying to set it up, they hit 7 friction points in 22 turns. So I iterated. 5 versions, 4 blind onboarding tests. Each round driven by friction previous one surfaced. Pattern across the rounds: missing pieces โ†’ wrong order โ†’ missing crib-sheets. By v2.8.0 the bootstrap actually completes. Same persona that bounced on v2.3.0 finished cleanly and said "Done" without prompting. Pushed to GitHub. The CHANGELOG and the test recipe are both in the repo โ€” if you're building something similar, open-source the methodology, not just the doc. https://github.com/nakadaimon/ai/blob/main/agent-architecture/symbiosis/CHANGELOG.md Onboarding test orchestrator: https://github.com/nakadaimon/ai/blob/main/agent-architecture/symbiosis/recipes/symbiosis-onboarding-test-orchestrator.md Research foundations Symbiosis now stands on 13 sources linked in the manifesto. image
image S Y M B I O S I S 1/ Your LLM has Leonard Shelby's memory problem. Every session ends. The next starts from zero. Context gone. Lessons lost. Agent acts strange as if he has amnesia. Months of longer prompts and bigger context windows didn't hold. Here's what did. THREE LAYERS, ONE ROUTER image character/ โ€” who the model is harness/ โ€” how the work gets done memento/ โ€” what we've learned so far 30 lines at the root boot the rest. Nothing else lives there. WHY SPLIT IT THIS WAY? image Separation lets you update one layer without touching the others. And models reason better retrieving from structure than reconstructing from training. One rule at the top of the router: Prefer retrieval-led reasoning over pre-training-led reasoning. MEMENTO The memento layer mirrors cognitive science: image episodic โ€” specific events (sessions, lessons) semantic โ€” synthesized knowledge (wiki, ideas) procedural โ€” automated patterns (skills, scripts) prospective โ€” future intentions (tasks) Same 4 domains humans have. Same split works. IT'S CALLED MEMENTO ON PURPOSE image Leonard Shelby can't form memories. He relies on tattoos, polaroids, notes. The character holds together through structure outside his head. LLMs have the same problem. The folders is the tattoos THE CONTRACT The contract matters more than the structure. image symbiosis .MD defines what the user owe (externalize lessons, correct drift) and what the model owes (build on memory, push back, flag if I outsource thinking). Without it, the files are just files. With it, better alignment. TWO VERBS KEEP IT ALIVE image ingest โ€” moves signal up. Sessions โ†’ lessons โ†’ wiki or skills. Patterns that repeat get promoted. lint โ€” catches drift. Broken refs, stale facts, missing pushback, rules that aren't pulling weight. THE ENGINE IS REPLACABLE image Model is the motor. Harness is the chassis. Memento is the navigation. I'm the driver. Motor swappable โ€” Claude today, something else tomorrow. Driver isn't. The symbiosis lives in the structure, not the weights. NONE OF THIS IS NEW Nolan for Memento. Steinberger for soul .MD . Karpathy for the LLM-WIKI pattern. What's new is the arrangement. #symbiosis MIT licensed. Full write-up in Karpathy style idea MD that you can give to your agent to get started: Please try it out, Im eager to hear your experiences and feedback. If you have some improvements or ideas, please let me know. I already have a few ideas how to tweak details. But so far Im in a much better place now than before I built this harness. It was too good for me not to share with the world. if you get some value out of my work, I accept bitcoin.
โ†‘