# Tessera: Code Analysis with a Versioned Knowledge Graph

> Source: <https://blog.stackademic.com/tessera-code-analysis-with-a-versioned-knowledge-graph-99e1ea30568f?source=rss----d1baaa8417a4---4>
> Published: 2026-08-14 08:07:26+00:00

Analyzing code is more than reading file after file. You want to understand the architecture: who calls whom, what the hidden dependencies are, what breaks if a function changes, whether a new PR violates project rules. Those answers don’t live in any single file — they live in the relationships *between* files.

That’s what drove **Tessera**: connect a Git repository and it builds a **versioned knowledge graph** of your codebase. Classes, interfaces, methods, calls, dependencies — all mapped. And the important part: every *commit* produces an immutable snapshot. You can ask “what breaks if I change X?” at any version of the code.

The first temptation in a project like this is to dump the whole repository into an LLM and ask it to “understand.” Spoiler: that doesn’t work well. Models hallucinate structure, invent relationships that don’t exist, and you lose trust in the entire system.

Tessera does the opposite. **tree-sitter** (static AST analysis) is the source of truth, at ~1.0 confidence. It decides what exists: classes, methods, inheritance, calls, dependencies. AI only comes in afterwards, to summarize and infer semantics — on top of a structure already decided deterministically.

The result: useful descriptions, but always correct structure.

Every graph node has two hashes:

This gives true **incremental** processing. Five files changed in a 10,000-file repository?

The AI processes 5 nodes, not the monolith. And because snapshots are immutable and content-addressed, every query is “time-travel”: architectural diffs between versions, versioned queries, no global state to manage.

The dashboard becomes a toolbox for analysis:

Not everyone wants to spin up Docker just to analyze a codebase. The tessera binary runs the same parse → summarize → link → graph pipeline, but **100% offline**: no database, no API, no AI, no upload. It only needs the .NET runtime, git, and the parsing sidecar.

That means: architecture rules validated in CI, Markdown reports generated locally, and the same results as the dashboard — because it reuses the same rule engine and the same graph algorithms.

Open source, with a spec-driven development history documented along the way. If you want to understand the architecture of a codebase before touching it — including your own — take a look here: [https://github.com/rcarubbi/tessera](https://github.com/rcarubbi/tessera)

[Tessera: Code Analysis with a Versioned Knowledge Graph](https://blog.stackademic.com/tessera-code-analysis-with-a-versioned-knowledge-graph-99e1ea30568f) was originally published in [Stackademic](https://blog.stackademic.com) on Medium, where people are continuing the conversation by highlighting and responding to this story.
