Local · deterministic · TypeScript

See where your code goes.

Abstract Flow maps TypeScript source into readable control-flow diagrams—branches, calls, loops, returns, and error exits—without an LLM in the middle.

Input
TypeScript AST
Output
Control-flow graph
Runtime
Your machine
Source code mapped to a control-flow graphA TypeScript function is analyzed into a graph with a branch and a labeled error exit.checkout.ts01export functioncheckout(cart) {02if (!cart.items.length)03throw new EmptyCart()04for (const item of cart)05 reserve(item)06return payment()07}TypeScript sourceAST factscheckout(cart)function entryitems?branchemptyhas itemsEmptyCartthrow exitreserve(item)loop bodynext itempayment()return exit
Static example · every node has a source fact behind it

Evidence, not inference

Source in. Facts out. Flow made visible.

Abstract Flow records the structural facts that lead to each edge, so the diagram stays grounded in the source you are reading.

src/checkout.ts
12if (!cart.items.length) {
13 throw new EmptyCart();
14}
15
16for (const item of cart.items) {
17 reserve(item);
18}
19
20return payment();
  1. 01
    Sourcecheckout.tslines 12–20
  2. 02
    AST factsbranch · throw · loopanchors retained
  3. 03
    Flow graph12 nodes · 14 edgespaths labeled

Built for inspection

Control flow you can verify.

01

Deterministic analysis

The same source produces the same graph. AST facts go in; mapped flow comes out.

02

Local source context

Analyze a project where it lives. Routes, calls, branches, and throws stay connected to source.

03

Navigable control flow

Follow an entrypoint through decisions, loops, functions, and explicit error exits.

Package identity

Keep the source in the conversation.

Abstract Flow ships as a local CLI and a Bun server export in abstract-flow. The first release will make the command available on npm.

Install locally

Put the flow beside your code.

The CLI runs locally. The skill gives a coding agent a short, deterministic path to routes, callers, branches, and SVG flows.

01

Run the CLI

Try it without changing your project, or add it as a local development dependency.

Try now
bunx abstract-flow
Project install
bun add --dev abstract-flow
bunx abstract-flow
Uninstall
bun remove abstract-flow

A bunx-only run does not add a project dependency.

02

Teach your coding agent

Copy the portable SKILL.md directory into the skill root your agent already scans.

Install skill
git clone --depth 1 --branch beta https://github.com/code-salad/abstract-flow.git /tmp/abstract-flow
cp -R /tmp/abstract-flow/skills/abstract-flow <agent-skill-root>/abstract-flow
rm -rf /tmp/abstract-flow
Uninstall skill
rm -rf <agent-skill-root>/abstract-flow

Removing the skill does not remove project code or generated diagrams.