Extract team conventions from git history, serve via MCP to any AI coding tool
Project description
Extract team conventions from git history. Serve them to any AI coding tool via MCP.
Quick Start · Setup AI Tool · Modes · MCP Tools
Three commands. Zero API keys. Works with Claude Code, Cursor, Codex, Copilot, and 10+ more.
pip install kronode
kronode init .
kronode ingest
kronode serve
What it does
Kronode reads your local git repository and extracts:
- Conventions — commit message patterns, team naming rules, directory structure
- Documentation — README, docs/, architecture decisions from markdown files
- PR review knowledge — what reviewers actually teach in code reviews (optional)
Then serves it all via MCP to any AI coding tool — so your AI assistant knows your team's patterns, not just generic best practices.
Quick Start
# Install
pip install kronode
# Point to your repo
cd ~/projects/your-repo
kronode init .
# Extract conventions + docs from git history
kronode ingest
# Optional: also fetch PR review comments (uses gh CLI auth)
kronode ingest --with-prs
# Start MCP server
kronode serve
Then connect your AI tool (see Setup below).
How it works
Your Git Repo Kronode AI Coding Tool
┌──────────────┐ ┌──────────────────┐ ┌──────────────────┐
│ git log │────▸│ Convention │ │ Claude Code │
│ git blame │ │ Extraction │ │ Cursor │
│ docs/*.md │────▸│ │◂───▸│ Codex │
│ PR reviews │────▸│ SQLite DB │ MCP │ Copilot │
│ (optional) │ │ Local Embeddings │ │ Windsurf │
└──────────────┘ └──────────────────┘ │ + 7 more │
└──────────────────┘
Everything runs locally. No data leaves your machine unless you opt into BYOK mode.
CLI Reference
| Command | Description |
|---|---|
kronode init . |
Initialize for a local repo |
kronode ingest |
Extract conventions + docs from git history |
kronode ingest --with-prs |
Also fetch PR review comments (uses gh CLI or --token) |
kronode serve |
Start MCP server (stdio) |
kronode serve --http |
Start MCP server (HTTP/SSE for Cursor, remote) |
kronode query "task" -f file.py |
Test context retrieval from terminal |
kronode setup <tool> |
Print MCP config for an AI tool |
kronode status |
Show convention/doc counts |
kronode add "convention rule" |
Manually add a convention |
kronode purge |
Delete all ingested data |
Setup Your AI Tool
Claude Code
claude mcp add kronode -- kronode serve
Cursor
Add to .cursor/mcp.json:
{
"mcpServers": {
"kronode": {
"command": "kronode",
"args": ["serve"]
}
}
}
OpenAI Codex
Add to ~/.codex/config.toml:
[mcp_servers.kronode]
command = "kronode"
args = ["serve"]
[mcp_servers.kronode.tools.get_context]
approval_mode = "approve"
[mcp_servers.kronode.tools.get_doc]
approval_mode = "approve"
GitHub Copilot (VS Code)
Add to .vscode/mcp.json:
{
"servers": {
"kronode": {
"command": "kronode",
"args": ["serve"]
}
}
}
Run kronode setup --list to see all supported tools.
Modes
Local Mode (default)
Zero API keys, zero network. Reads from your .git/ directory.
- Conventions from commit message patterns + git structure
- Documentation from markdown files
- Local embeddings via fastembed (ONNX, ~50MB)
Local + PRs
Add --with-prs to also fetch PR review comments. If gh CLI is installed and authenticated, no token needed. Otherwise pass --token <PAT>.
# With gh CLI (recommended)
gh auth login
kronode ingest --with-prs
# Or with explicit PAT
kronode ingest --with-prs --token ghp_xxx
BYOK Mode
Set OPENAI_API_KEY for richer LLM-based convention extraction from PR diffs.
OPENAI_API_KEY=sk-xxx kronode ingest --with-prs
Configuration
Copy .env.example to ~/.kronode/.env:
# Number of PRs to analyze (default: 200)
KRONODE_PR_COUNT=200
# Minimum confidence threshold (default: 0.5)
KRONODE_MIN_CONFIDENCE=0.5
# Max conventions per query (default: 20)
KRONODE_MAX_CONVENTIONS=20
MCP Tools
Kronode exposes 2 MCP tools:
get_context
Returns everything an AI needs before coding:
- Top conventions ranked by file-level relevance (with match reasons)
- Related documentation from repo markdown
- Action plan summary
- Directly and loosely related issues (if indexed)
get_doc
Returns the full content of a documentation page when get_context returned a truncated snippet.
Tech Stack
- Python 3.11+ — async throughout
- SQLite — zero-config local database (PostgreSQL optional)
- fastembed — ONNX local embeddings (~50MB, not 2GB PyTorch)
- MCP — Model Context Protocol for AI tool integration
- click + rich — CLI framework
Development
git clone https://github.com/GauravGill90/kronode.git
cd kronode
uv venv .venv && source .venv/bin/activate
uv pip install -e ".[byok]"
kronode --help
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file kronode-0.2.0.tar.gz.
File metadata
- Download URL: kronode-0.2.0.tar.gz
- Upload date:
- Size: 57.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6a1122f502baf22a77232d41929daa719e106a0b4878cd2b7e98c316eace859c
|
|
| MD5 |
5f96bd9637545b0d7a1c580bca83468d
|
|
| BLAKE2b-256 |
98a5527000929f53023d20c04c84ab6f06670e4bfe208eae4842043daaf80f9b
|
File details
Details for the file kronode-0.2.0-py3-none-any.whl.
File metadata
- Download URL: kronode-0.2.0-py3-none-any.whl
- Upload date:
- Size: 71.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
904f2db0ecd9e75de72df8e08efd58e042ce573f8ad921dc3a77bb7a9b224762
|
|
| MD5 |
168c7d4ad95f240f4f5ea529318353d2
|
|
| BLAKE2b-256 |
d26476b0704ab271f0f0141df876d5f9336bbb718b0d1005ef9ec577f69239a9
|