Skip to main content

axiom-graph

PyPI version Python versions Documentation License: MIT

axiom-graph indexes a project's code, docs and tests into one graph, and when the code changes it tells you which docs and tests are now out of date. It is built for AI coding agents: its MCP server lets an agent search the project, read one function or one doc section at a time, follow the links between code, docs and tests, and update the docs a change made stale. A CLI and a browser dashboard give people the same view.

It runs locally. Install it with pip; there is no account, and the index is a SQLite file in your project.

Quick start

Requires Python 3.10 or later. From your project's root:

pip install axiom-graph
axiom-graph init .      # scan the project and build the index

Change the body of a function that one of your tests calls, then run:

axiom-graph check .
own: 2 CONTENT_UPDATED / 0 DESC_UPDATED / 0 RENAMED / 0 NOT_FOUND · link: 2 LINKED_STALE / 0 BROKEN_LINK · 0 VERIFIED

NODE                                              OWN_STATUS       LINK_STATUS
----------------------------------------------------------------------------------------
myproject::reports                                CONTENT_UPDATED  VERIFIED
myproject::reports::build_report                  CONTENT_UPDATED  VERIFIED
myproject::tests.test_reports                     VERIFIED         LINKED_STALE
myproject::tests.test_reports::test_build_report  VERIFIED         LINKED_STALE  via myproject::reports::build_report

The edited function and its module are CONTENT_UPDATED, and the test that calls it is LINKED_STALE. Doc sections that link to the function are flagged the same way. After reviewing, run axiom-graph mark-clean <node id> . on the function and the test to clear them. Run axiom-graph build . when you add files, so they join the index.

How it works

Every module, class, function, test, doc section and annotated workflow becomes a node, joined by typed edges. A test validates the functions it calls (found automatically), a doc section documents the code it links to, and a @workflow or @task marker annotates its function. When a function's body or docstring changes, the nodes linked to it become LINKED_STALE and stay that way until someone verifies them. Drift follows only these edges, not every caller.

  • Docs are DocJSON files in your docs folders (docs/ by default; docs_dirs in axiom-graph.toml changes it). Each section is its own node with its own links, so an agent can read one section instead of a whole document. Markdown docs are indexed too.
  • Languages: Python out of the box. JavaScript and TypeScript need pip install "axiom-graph[js]" and a js_paths setting in axiom-graph.toml.
  • Workflow markers: @workflow, @task, Step and AutoStep come from the axiom-annotations package. They name the steps of your main pipelines so the graph shows what runs in what order.

Ways to use it

  • MCP server, for agents: tools to search, read source and doc sections, follow edges, check drift, write, copy and link docs, and export workflows with their code to one page you can share. Setup is below.
  • CLI: init, build, check and mark-clean, plus commands to explore the graph, show history, render docs and export workflows. axiom-graph carry-forward copies the verifications made in a merged git worktree into your main checkout's index. axiom-graph check --fail-on stale . exits 1 while anything is stale, for CI.
  • Dashboard: pip install "axiom-graph[viz]", then axiom-graph viz . opens a browser UI with Graph, List, Docs, Workflows and Tests tabs.

Connect an agent

The server reads the index, so run axiom-graph init . first. It talks to the client over stdio. For Claude Code, create .mcp.json in your project root:

{
  "mcpServers": {
    "axiom-graph": {
      "type": "stdio",
      "command": "/path/to/your/venv/bin/python",
      "args": ["-m", "axiom_graph.mcp_server"]
    }
  }
}

Point command at the Python in the virtualenv where axiom-graph is installed (Scripts/python.exe on Windows), then restart Claude Code. Other MCP clients take the same command, or the axiom-graph-mcp console script. If the client shows the server as failed, run the command by hand to see the error. Setup for other clients, logging and troubleshooting are in the documentation.

PEV Agent Nexus

The PEV Agent Nexus is a Claude Code plugin, shipped from this repository, that runs code changes through Plan, Execute and Validate phases. Separate agents plan, implement, review, and update the docs the change made stale, with a human approval gate between phases. They work through the axiom-graph MCP tools. Installation and use are covered in the documentation.

License

MIT

Metadata

Release files for axiom-graph 3.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for axiom-graph 3.1.0
File Size Uploaded Provenance Actions
axiom_graph-3.1.0.tar.gz 893.1 kB Without provenance Details for axiom_graph-3.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for axiom-graph 3.1.0
File Interpreter ABI Platform Actions
axiom_graph-3.1.0-py3-none-any.whl Python 3 none any Details for axiom_graph-3.1.0-py3-none-any.whl

Total release size: 1.9 MB

Release files / axiom_graph-3.1.0.tar.gz

Download URL axiom_graph-3.1.0.tar.gz
Size 893.1 kB
Tags Source
SHA-256 checksum
How to use checksums
dd99e792c2bdc5bdec40652dc20911ff8607ff3bfac746a22985db7818753733
BLAKE2b-256 checksum
How to use checksums
c61bfa1d78b87c0a3686f0a23d3f7d52220a26f8f5d556123ef83739c3f7bc3e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.2 CPython/3.10.9 Windows/10

Release files / axiom_graph-3.1.0-py3-none-any.whl

Download URL axiom_graph-3.1.0-py3-none-any.whl
Size 966.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f747d71f2db5cce84ea37a20d33c33d961cd64e0d0751bc07e3f0d1457d88270
BLAKE2b-256 checksum
How to use checksums
279b7737714fb61c30d611bfdf88d8c6808b39c2f4b86148ae3161952333a701
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.2 CPython/3.10.9 Windows/10

Security for axiom-graph 3.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page