Back to browse
GitHub Repository

A Context Compiler for TypeScript. Deterministic, diffable architectural contracts and dependency graphs for AI coding workflows.

86 starsTypeScript

Detect Drift in TypeScript codebases

by AmiteK·Mar 15, 2026·1 point·0 comments

AI Analysis

●●SolidNiche GemBig Brain

AST-based contracts beat raw code for AI, but codebase analyzers are increasingly crowded.

Strengths
  • Deterministic contracts mean reproducible diffs across git baselines and CI pipelines.
  • MCP server integration lets Cursor and Claude query architecture instead of parsing source.
  • Watch mode regenerates contracts in real-time as you refactor components.
Weaknesses
  • TypeScript-only limits adoption compared to language-agnostic competitors like Sourcegraph.
  • Structural drift detection solves a problem many teams don't know they have yet.
Target Audience

TypeScript developers, teams managing large codebases, AI-assisted coding workflows

Similar To

Sourcegraph Cody · Cursor · Continue

Post Description

I’ve been building LogicStamp Context, an open-source CLI that analyzes TypeScript codebases using the TypeScript AST and compiles them into deterministic JSON “contracts”.

These describe components, props, hooks, routes, API signatures and dependencies in a structured way.

The goal is to make codebase structure observable and diffable, especially as codebases grow and change.

You can use it to:

• detect drift during refactors

• generate compact machine-readable context for AI tools

• watch mode that detects structural changes while you code

The latest release also adds git baseline comparison:

stamp context compare --baseline git:main

This generates contracts for both versions and produces a structural diff.

There’s also an MCP server (logicstamp-mcp) so agents like Cursor or Claude can query architectural context instead of raw source files.

Repo: https://github.com/LogicStamp/logicstamp-context

Docs: https://logicstamp.dev

Curious how others track structural changes in large TypeScript codebases.

Similar Projects