Skip to content

Quickstart

twin needs Node 22 or newer.

npm install -g @crypticsaiyan/twincli

This installs the twin command. To try it without installing, prefix a command with npx @crypticsaiyan/twincli.

You have a command that fails on your machine. Nothing is uploaded and no account is needed.

  1. In the project where the command fails, run it through twin:

    twin capture -- npm test

    twin runs the command as usual and shows its output.

  2. twin prints a summary of what it recorded and asks:

    Write twin-capsule.json? [y]es / [n]o / [v]iew full JSON:

    Press v to read the full JSON first, y to write it, n to stop.

  3. Attach twin-capsule.json to the issue. On GitHub, drag the file into the comment box.

The repository contains the capsules for apache/echarts#21538. With a key set, from a clone:

twin replay examples/echarts-21538/new-york.json
twin bisect examples/echarts-21538/new-york.json --good examples/echarts-21538/kolkata.json
twin verify examples/echarts-21538/new-york.json --patch examples/echarts-21538/fix.patch

Each takes about 70 seconds.

git clone https://github.com/crypticsaiyan/twin
cd twin
pnpm install
pnpm dev replay examples/echarts-21538/new-york.json # runs from source, Node 22.18 or newer
pnpm build && node dist/bin.js --help # or build first
  • Capture: what is recorded and how to share values.
  • Issue template: ask for capsules when the issue is filed.
  • AI agents: let a coding agent work in the reporter’s environment.