Lattice is an OpenCode plugin for running repeatable multi-agent pipelines.
It is a framework — not a product with built-in pipelines. You supply the agents, skills, and pipeline definitions; Lattice handles stage orchestration, session reuse vs cold starts, skill injection, and persisted pipeline state in .lattice/.
Register the npm package directly in opencode.json. OpenCode will download it:
{
"plugin": ["@callumvass/lattice"]
}If you are developing Lattice itself, build from source:
git clone https://github.com/CallumVass/lattice.git ~/dev/lattice
cd ~/dev/lattice
npm install
npm run buildThen point OpenCode at the built plugin file:
{
"plugin": ["~/dev/lattice/dist/plugin/index.js"]
}Lattice discovers content from OpenCode's conventional paths. Project paths override global ones with the same name.
| Content | Project path | Global path |
|---|---|---|
| Pipelines | .opencode/lattice-pipelines/*.ts |
~/.config/opencode/lattice-pipelines/*.ts |
| Agents | .opencode/agents/*.md |
~/.config/opencode/agents/*.md |
| Skills | .opencode/skills/<name>/SKILL.md |
~/.config/opencode/skills/<name>/SKILL.md |
A pipeline file has a default export — either the typed builder (import { pipeline, stage } from "@callumvass/lattice") or a plain object. A pipeline named my-flow registers /my-flow <goal> as a slash command automatically. See docs/custom-pipelines.md.
If you use the typed builder, install @callumvass/lattice where your pipelines live so they can resolve the import:
cd ~/.config/opencode && npm install @callumvass/lattice # for global pipelines
cd <your-project> && npm install --save-dev @callumvass/lattice # for project pipelinesThese three come from Lattice itself, independent of your pipelines:
/lattice-status— show current pipeline state/lattice-abort— stop the active pipeline/lattice-retry [response]— resume a paused pipeline, optionally with a reply to the pause reason
- Author a pipeline file and drop it in one of the pipeline paths above.
- Make sure every agent it references exists under
agents/, and every pinned skill exists underskills/. - Inside OpenCode, run
/<your-pipeline-name> <goal>. - Use
/lattice-statusto watch it progress.
docs/what-lattice-does.md: overview and core conceptsdocs/install.md: setup and plugin registrationdocs/run-a-pipeline.md: running a pipeline, pauses, retriesdocs/custom-pipelines.md: authoring a pipelinedocs/configuration.md: overriding agents, stages, and skill pathsdocs/skills.md: skill discovery and selectiondocs/state-and-completion.md:.lattice/files, completion methods, retry behavior
npm run check
npm run build
npm run release:checkReleases use release-please on main. Conventional commits drive the release PR; rebase-merge that PR and CI publishes to npm via trusted publishing.
GitHub setup:
RELEASE_PLEASE_TOKEN: PAT used by release-please so release PRs trigger CI- npm trusted publishing for this GitHub repo/package pair
MIT