Loom for llm4j: AI agent workflows
Build, review, test and run multi-agent AI workflows in VS Code. Describe one in a sentence, see it as a graph, review it for cost and security, and test it without a model or an API key.
Repository · Quickstart · Tutorial · Language guide · Full extension reference · Issues

Get started
- Install the extension. It carries its own engine and needs only Java 17 or newer.
- Run Loom: Set Up My Coding Agent. Your coding agent (Claude Code, GitHub Copilot, Cursor or Codex) gets Loom's four skills and can design, build, test and deploy workflows for you. The chat then opens with a starter prompt typed in.
- Run Loom: Try a Demo. It runs a bundled workflow on demo models, so it needs no key and costs nothing.
- Run Loom: Generate Workflow... to turn a sentence into a checked project, or Loom: New Workflow from Starter... to copy one of twenty ready workflows, or open any
.loom file.
The same path is a guided Walkthrough: run Loom: Open Walkthrough. It opens by itself the first time the extension runs.
What it does
- Generate and change. Write a workflow from a sentence. Change it with a diff you accept or reject.
- See the graph. A live graph of the workflow in three views: Outline, Focus and Flow.
- Review. Findings on cost, security and risk beside the graph, with a fix for each and the OWASP Top 10 for LLM Applications mapping.
- Test and evaluate. Tests with scripted models and no keys; evaluations against a dataset.
- Debug. Breakpoints, stepping (and stepping back) and variables, with the models mocked.
- Run and watch. A real run, capped by cost, with a live page for cost, context and incidents.
- Ship. Docker, Compose and Kubernetes files read from the script.
- Set up your coding agent. Teaches Claude Code, Copilot, Cursor or any
AGENTS.md agent to build with Loom.
- Language support. Highlighting, checks from the engine's own parser, completion, hover, go to definition, rename and snippets.

What a workflow looks like
Loom is a small language for workflows of AI agents. The model reads and writes; the script holds the rules. Here the script, not the model, decides when a refund needs a person:
budget { tokens: 100000 calls: 20 }
agent Triage {
model: "gemini-2.5-flash"
system: "Read the customer's email. Say what they want and any refund amount they state."
guard { pii: mask }
}
workflow Main(email) {
delegate "Classify this message:\n{email}" to Triage -> triage expecting {
kind: enum["REFUND", "QUESTION"],
amount: number
}
alt (triage.kind == "REFUND") {
alt (triage.amount > 100) {
human_prompt "Approve a refund of {triage.amount}? (yes/no)" -> decision
note "Decision: {decision}"
} else {
note "Within the limit: refund approved automatically."
}
} else {
note "Not a refund: reply directly."
}
}
Every command, under "Loom" in the Command Palette

Privacy and cost
- Editing, checks, the graph, review, tests and debugging run on your machine and send nothing anywhere.
- Only generate, change and a live run call a model. They use your own keys, are capped by a setting, and a live run asks before it starts.
Learn more
Apache 2.0. Part of llm4j, the Java stack for AI agents.
| |