Skip to main content

llmcc brings multi-depth architecture graphs for code understanding and generation.

Project description

llmcc

llmcc brings multi-depth architecture graphs for code understanding and generation.

Our goal is to build a multi-depth, tree-like context / architecture view of a codebase, so a coding agent can walk up (zoom out) for structure and intent, then walk down (zoom in) to the exact crates/modules/files/symbols it needs—getting a highly comprehensive understanding of any codebase (any programming language).

Supported Languages

Language Status Notes
Rust ✅ Supported Full support for crates, modules, and symbols
TypeScript ✅ Supported Includes TSX, supports ES modules
C++ 🔜 Planned Coming soon
Python 🔜 Planned Coming soon

Why multi-depth graphs?

People (and coding agents) need to understand systems from different dimensions. Sometimes you need the high-level architecture to see boundaries, ownership, and how subsystems connect; other times you need the low-level implementation details to make a safe, precise change. llmcc provides multiple depths so you can choose the right “distance” from the code for the task.

Depth Perspective Best for
0 Project multi-workspace / repo-to-repo relationships
1 Library/Crate ownership boundaries, public API flow
2 Module subsystem structure, refactor planning
3 File + symbol implementation details, edit planning

Walkthrough: Codex (midterm size multi-crate rust project)

This repo includes many examples under sample. Download and open them in browser for the best viewing experience.

Depth 1: crate graph

Codex crate graph (depth 1)

Depth 2: module graph

Codex module graph (depth 2)

Depth 3: file + symbol graph

Codex file and symbol graph (depth 3)

Here's a small portion of the graph at depth 3, showing the core abstraction layer for prompt handling in Codex. Developers and AI agents can quickly grasp the architecture by examining this view.

codex core logic

Performance

llmcc is designed to be very fast, and we will try to make it faster.

The repo contains benchmark for many famous project output here: sample/benchmark_results_16.md.

Excerpt (PageRank timing, depth=3, top-200):

Project Files LoC Total
databend 3130 627K 2.53s
ruff 1661 418K 1.73s
codex 617 224K 0.46s

Installation

npm / npx (Recommended)

The easiest way to use llmcc is via npm. No build required:

# Run directly without installing
npx llmcc-cli --help

# Or install globally
npm install -g llmcc-cli
llmcc --help

Cargo (Rust)

cargo install llmcc

From Source

git clone https://github.com/allenanswerzq/llmcc.git
cd llmcc
cargo build --release
./target/release/llmcc --help

CLI: generate graphs

Generate a crate-level graph for Codex (DOT to stdout):

llmcc \
	-d sample/repos/codex/codex-rs \
	--graph \
	--depth 1

Generate a PageRank-filtered file+symbol graph (write to a file):

llmcc \
	-d sample/repos/codex/codex-rs \
	--graph \
	--depth 3 \
	--pagerank-top-k 200 \
	-o /tmp/codex_depth3_pagerank.dot

Render DOT to SVG (requires Graphviz):

dot -Tsvg /tmp/codex_depth3_pagerank.dot -o /tmp/codex_depth3_pagerank.svg

For generating sample graphs:

just gen rust

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

llmcc-0.2.63.tar.gz (192.7 kB view details)

Uploaded Source

Built Distributions

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

llmcc-0.2.63-cp38-abi3-win_amd64.whl (1.2 MB view details)

Uploaded CPython 3.8+Windows x86-64

llmcc-0.2.63-cp38-abi3-manylinux_2_34_x86_64.whl (1.4 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.34+ x86-64

llmcc-0.2.63-cp38-abi3-macosx_11_0_arm64.whl (1.2 MB view details)

Uploaded CPython 3.8+macOS 11.0+ ARM64

File details

Details for the file llmcc-0.2.63.tar.gz.

File metadata

  • Download URL: llmcc-0.2.63.tar.gz
  • Upload date:
  • Size: 192.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for llmcc-0.2.63.tar.gz
Algorithm Hash digest
SHA256 67f9d6d5002c55be3d3cc357707c0dede96aca55f4ce6970af23dab07f01a549
MD5 b1ca082e8ed44155f30d3065585733cd
BLAKE2b-256 5e2401ab772945a1487e9d9c150d2e8b5e7fad946789ecf72ffa886c96396b07

See more details on using hashes here.

File details

Details for the file llmcc-0.2.63-cp38-abi3-win_amd64.whl.

File metadata

  • Download URL: llmcc-0.2.63-cp38-abi3-win_amd64.whl
  • Upload date:
  • Size: 1.2 MB
  • Tags: CPython 3.8+, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for llmcc-0.2.63-cp38-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 35ae4eab4d5fc485db4289c64612b1176ca342ad737b56cb603461afa4eb8d2d
MD5 dac79ed1e52d4c3c983f9af79ad20ccd
BLAKE2b-256 45ffc6d9c050f9be52607d1e9d59a9d6a03c1f13eb25c8ebd0c51a750a029c63

See more details on using hashes here.

File details

Details for the file llmcc-0.2.63-cp38-abi3-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for llmcc-0.2.63-cp38-abi3-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 dc3e0ead55efb6513badd71cdcf616deedf58976352ddbdcf8d767a1d4e9de28
MD5 ab89235d15d51c6478c9977ba3dffe02
BLAKE2b-256 38d7a9681d8b651cd18e7e03474b410a39d4b66d23ca29d8892a46806d529f6e

See more details on using hashes here.

File details

Details for the file llmcc-0.2.63-cp38-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for llmcc-0.2.63-cp38-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 34d0b36e1fd7df939449751bac73b019a66255f46ccf7620f7db7b4a3f85b479
MD5 d4a6590326313f114ebfbce0ce693ea5
BLAKE2b-256 4641d59eda52e876cfe9b81154153edf7eb41e0c9bcdf87d8a4ad85ebf1c5d8c

See more details on using hashes here.

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