Skip to content

Extraction

Extract architecture from your codebase into a Rivière graph.

Why Extract?

Your codebase contains architectural knowledge—APIs, use cases, domain operations, events. Extraction makes this explicit by producing a graph you can visualize, query, and validate.

Choose Your Workflow

AI-Assisted Extraction

For any language or codebase. AI analyzes your code and builds the graph.

Best for:

  • Any programming language
  • Codebases without architectural conventions
  • Initial extraction to understand existing systems

Start AI-Assisted Workflow →


TypeScript Extraction

For TypeScript codebases. Config-driven detection via decorators, JSDoc, or naming conventions.

Best for:

  • TypeScript projects
  • Codebases with architectural conventions
  • CI integration and repeatable extraction

Start TypeScript Workflow →


Extraction and Enforcement

Extraction and enforcement form a reinforcing cycle:

Extraction-Enforcement Cycle: Architecture Definitions guide Codebase, Codebase parsed by Extraction, Extraction validates Enforcement, Enforcement ensures Definitions
  1. Define — Establish component conventions (what's an API, UseCase, etc.)
  2. Build — Write code following those conventions
  3. Extract — Identify components from code
  4. Enforce — Ensure new code follows conventions

Enforcement makes extraction reliable. Extraction validates enforcement works.

Learn about Enforcement →


Reference