A CLI that uses Claude Code via the Agent Communication Protocol (ACP) to generate and maintain documentation wikis for codebases. It connects to Claude Code through ccb --acp, can ingest local knowledge sources through built-in connectors, and synthesizes them into a structured wiki.
npm install -g claude-code-wikiOn Windows, prefer installing with Node.js package managers such as npm or pnpm:
npm install -g claude-code-wiki
# or
pnpm add -g claude-code-wikiClaude Code Wiki uses the ACP provider which connects to Claude Code via ccb --acp. Make sure Claude Code is installed:
git clone https://github.com/claude-code-best/claude-code
cd claude-code
npm install && npm run build && npm linkYou may also need an Anthropic API key configured for Claude Code — see the documentation for details.
By default, the ACP provider is used. You can explicitly set it:
export CLAUDE_WIKI_PROVIDER=acp
# Optional: customize the ACP agent command
export CLAUDE_WIKI_ACP_COMMAND="ccb --acp"Configuration is saved to ~/.claude-wiki/.env on your local machine.
Two modes are available:
- Code mode — builds repository documentation in
claude-wiki/for the current codebase. - Personal mode — builds a local personal brain wiki in
~/.claude-wiki/wikifrom configured sources like local repositories, Gmail, Notion, Web Search, Hacker News, and X/Twitter.
# Initialize repository documentation
claude-wiki --init
# Initialize personal brain wiki
claude-wiki personal --initBare claude-wiki --init and claude-wiki --update run in code mode by default.
# Interactive chat for the current repository
claude-wiki
# Interactive personal brain
claude-wiki personal
# Send a message directly
claude-wiki "Generate documentation for this repository"
# Run once and exit (prints final output)
claude-wiki -p "Summarize the key concepts"
claude-wiki --print "What connector tools are available?"
# Update repository docs
claude-wiki --update
# Update personal brain (including connector ingestion)
claude-wiki personal --update "Refresh the wiki from configured connectors"
# Show help
claude-wiki --helpBare claude-wiki runs in code mode. Use claude-wiki personal for the local general-purpose wiki. The CLI stays open after each run by default. Use -p/--print for a one-shot non-interactive run.
On each code run, Claude Code Wiki maintains both AGENTS.md and CLAUDE.md at the repository root. Each file is created if it does not exist; if already present, only the <!-- CLAUDE_WIKI:START -->…<!-- CLAUDE_WIKI:END --> block is rewritten, leaving your content untouched.
Repository-specific wiki instructions are stored in claude-wiki/INSTRUCTIONS.md. This file is user-authored — Claude Code Wiki reads it for scope and priorities but does not overwrite it during normal runs.
Add a CI workflow to automatically keep documentation up-to-date:
- GitHub Actions: copy claude-wiki-update.yml into
.github/workflows/claude-wiki-update.yml. - GitLab CI: copy claude-wiki-update.gitlab-ci.yml into
.gitlab-ci.ymlor include it from your existing GitLab pipeline. - Bitbucket Pipelines: copy claude-wiki-update.bitbucket-pipelines.yml into
bitbucket-pipelines.yml, then schedule theclaude-wiki-updatecustom pipeline from Repository settings > Pipelines > Schedules.
For repository documentation in CI, use claude-wiki code --update --print. --update will create the initial docs if they don't exist yet.
Scheduled/CI runs send anonymous reliability telemetry. Set CLAUDE_WIKI_TELEMETRY_DISABLED=1 to disable.
Claude Code Wiki emits Google Open Knowledge Format (OKF) v0.1 bundles in both code and personal modes.
- Every non-reserved Markdown concept has YAML front matter with a non-empty
type. - Valid
timestampvalues and producer-defined extension fields are accepted and preserved during updates. index.mdandlog.mdare reserved documents rather than concepts.- Standard Markdown links between concept documents express relationships.
Claude Code Wiki's first-run onboarding offers connector setup for local Git repositories, Notion, Gmail, X/Twitter, Web Search, and Hacker News. During ingestion, connector tools write raw data under ~/.claude-wiki/connectors/<connector>/raw/, then the agent synthesizes the wiki under ~/.claude-wiki/wiki/.
You can configure the same connector more than once (e.g. two Web Search sources for different topics). Run all instances with claude-wiki ingest all, one connector with claude-wiki ingest web-search, or one instance with claude-wiki ingest web-search-2.
| Connector | Description |
|---|---|
| git-repo | Reads configured local repository paths and writes compact manifests. |
| notion | Uses the Notion MCP server for read-only search and retrieval from configured pages. |
| gmail | Fetches recent mail from the Gmail API using the configured query (defaults to newer_than:1d). |
| x | Uses the X API with OAuth user-context credentials for home timeline, posts, mentions, bookmarks, and lists. |
| web-search | Uses Tavily free API (1000 queries/month) directly — no LangChain wrapper dependency. Requires TAVILY_API_KEY. |
| hackernews | Fetches configured public HN feeds and Algolia search queries. |
| slack | Uses Slack's user-token API for self-message search and recent conversation ingestion. |
claude-wiki auth slack
claude-wiki auth gmail
claude-wiki auth notion
claude-wiki auth xStart an ngrok tunnel for Slack OAuth:
claude-wiki ngrok startFor custom ngrok domain:
claude-wiki ngrok start https://<your-ngrok-domain>Claude Code (ccb --acp) has native Langfuse monitoring built in. To enable it, set the following environment variables:
export LANGFUSE_PUBLIC_KEY="pk-xxx"
export LANGFUSE_SECRET_KEY="sk-xxx"
export LANGFUSE_BASE_URL="https://cloud.langfuse.com"Or configure via .claude/settings.json (recommended — persists across sessions):
{
"env": {
"LANGFUSE_PUBLIC_KEY": "pk-xxx",
"LANGFUSE_SECRET_KEY": "sk-xxx",
"LANGFUSE_BASE_URL": "https://cloud.langfuse.com"
}
}Optional parameters:
| Variable | Default | Description |
|---|---|---|
LANGFUSE_TRACING_ENVIRONMENT |
development |
Environment label |
LANGFUSE_FLUSH_AT |
20 |
Batch span count threshold |
LANGFUSE_FLUSH_INTERVAL |
10 |
Flush interval (seconds) |
LANGFUSE_EXPORT_MODE |
batched |
batched or immediate |
LANGFUSE_TIMEOUT |
5 |
Request timeout (seconds) |
Langfuse traces include agent runs, LLM calls, tool executions, and are automatically sanitized (no sensitive data is sent). See the ccb Langfuse docs for details.
Note: the original LangSmith telemetry has been removed in favor of ccb's native Langfuse integration.
# Clone and install
git clone https://github.com/<your-org>/claude-code-wiki
cd claude-code-wiki
pnpm install
# Run locally
pnpm dev
# Build
pnpm build
# Run tests
pnpm test
# Type check
pnpm typecheck
# Lint
pnpm lint- Node.js >= 22
- Claude Code (
ccb --acp)
