Skip to main content

Shared, git-synced, LLM-maintained wiki — one knowledge base for all your AI agents

Project description

MyWiki

A shared, git-synced, LLM-maintained wiki — one knowledge base that any agent (Claude Code, Codex, ouro-cli, GoaLoop, …) on any machine reads from and writes to.

Inspired by Andrej Karpathy's LLM-wiki note: instead of re-retrieving raw documents on every query (RAG), an LLM incrementally maintains a structured markdown wiki whose knowledge compounds over time.

Idea in one picture

sources/   immutable snapshots (id = content hash)
   │  mywiki ingest  →  work order
   ▼
wiki/pages/*.md   one concept per page, every claim cited [^src-id]
   │  mywiki query  →  cited answers
   ▼
git push/pull   sync across machines, agents, users
  • The CLI does the mechanical work — hashing, routing, indexing, linting, git.
  • The calling agent does the reasoning — extract facts, write prose, merge conflicts — guided by PLAYBOOK.md.
  • git is the coordination layer — push to GitHub/GitLab to share.

The split matters: the CLI can't call a model, so the intelligence lives in markdown (PLAYBOOK.md, exposed via mywiki help) and is executed by whatever LLM is running. That's what lets every tool share one brain.

Install

Zero-dependency Python 3 (stdlib only). Install from PyPI:

uv tool install my-wiki       # or: uv pip install my-wiki  /  pip install my-wiki

(The distribution is my-wiki; the command it installs is mywiki.)

Then create your first wiki and wire it into Claude:

mywiki init ~/my-wiki         # create + register a wiki (becomes default)
mywiki install                # deploy the bundled skill into ~/.claude/skills

Use

mywiki help                       # learn the commands
mywiki ingest notes.md            # freeze a source, get a work order
#   …agent edits wiki/pages/* per the work order…
mywiki commit-ingest src-1a2b -m "ingest: meeting notes" --push
mywiki query raft leader election # cited answers
mywiki lint                       # broken/stale/uncited check
mywiki sync                       # git pull --rebase before/after work

Multiple wikis

Each wiki is its own git repo, so you can run several independent ones (e.g. a work and a personal knowledge base). A per-machine registry (~/.config/mywiki/registry.json, not synced) gives them stable names:

mywiki init ~/work-wiki work          # create + register, first becomes default
mywiki init ~/personal-wiki personal
mywiki use research ~/some/existing    # register an existing wiki
mywiki list                            # show all, marking default + active
mywiki default personal                # change the default
mywiki -w work query raft              # target a specific wiki on any command
mywiki forget research                 # drop from registry (files untouched)

Which wiki a command hits, in order: -w <name>$MYWIKI_HOME → the wiki you are cd'd into → the registry default.

Make agents aware of it

Each tool just needs a one-line pointer to the CLI (there is no per-tool logic — the usage lives in mywiki help):

  • Claude Code: run mywiki install (deploys the bundled skills/mywiki/SKILL.md to ~/.claude/skills/).
  • Codex / others: add to AGENTS.md: "A mywiki CLI maintains a shared knowledge base; run mywiki help to use it."

Layout

This repo is the tool's source. Actual wikis are created elsewhere with mywiki init and have their own sources/, wiki/pages/, wiki/log/, wiki/index.md, plus a copy of PLAYBOOK.md / .schema.md.

Path What
mywiki/cli.py the CLI (mechanical engine + self-docs)
PLAYBOOK.md the workflow/prompts, served by mywiki help (canonical template)
.schema.md what a page looks like (canonical template)
mywiki/resources/ symlinks to the templates + skill, bundled into the wheel
skills/mywiki/ the Claude skill, deployed by mywiki install
pyproject.toml packaging (entry point mywiki = mywiki.cli:main)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

my_wiki-0.1.0.tar.gz (19.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

my_wiki-0.1.0-py3-none-any.whl (24.5 kB view details)

Uploaded Python 3

File details

Details for the file my_wiki-0.1.0.tar.gz.

File metadata

  • Download URL: my_wiki-0.1.0.tar.gz
  • Upload date:
  • Size: 19.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for my_wiki-0.1.0.tar.gz
Algorithm Hash digest
SHA256 15420394216fbd2eadc18d2bb6133452b8587de5ae2a78a221180461fdb2b6d0
MD5 978c03369934b64e9a572973a8b2df6f
BLAKE2b-256 12069dc30b4f965c5b7cc74dee4cf5889dd1f82e8d021d6b8244906432e5d9d4

See more details on using hashes here.

Provenance

The following attestation bundles were made for my_wiki-0.1.0.tar.gz:

Publisher: release.yml on luohaha/MyWiki

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file my_wiki-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: my_wiki-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 24.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for my_wiki-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cf21edd813ae5ad23c9b001e9291f462350e9790fd433c0a72cfeabb7b4c83bf
MD5 9353823f64f7ad0d888e47e3dfedadce
BLAKE2b-256 23a3e9ea5301bd2412fb17fd2144ba96e4af08b7f3126b99212ff676f33a065f

See more details on using hashes here.

Provenance

The following attestation bundles were made for my_wiki-0.1.0-py3-none-any.whl:

Publisher: release.yml on luohaha/MyWiki

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page