Repository navigation
Releases
cospan v0.1.3 — Batch WaitAll, cross-worktree lookup & future agy families
cospan 0.1.3 — Batch WaitAll, Cross-Worktree Lookup & Future agy Model Families
Header illustration generated via cospan-codex.
Highlights
cospan 0.1.3 makes parallel multi-agent workflows and linked Git worktrees work seamlessly end-to-end: collect multiple concurrent jobs in a single WaitAll barrier across CLI and MCP, address sibling worktree jobs directly by <job-id> from the main repository, use future versioned Gemini and Claude models on agy with --effort immediately, and contribute via new agent-first issue/PR templates.
What's New
- Batch
WaitAllacross CLI, MCP, and host skills (#10, #13):cospan wait <id1> <id2> ... [--timeout <dur>]and MCPcospan_wait({ cwd, ids: [...] })now support pureallSettledbatch waiting: all listed jobs run to completion without canceling siblings on early failure, deliverables render in caller-specified order separated by\n---\n\n, and exit codes follow highest-severity precedence (3error/crashed >4canceled >5attention >0all done).- Deduplicates repeated IDs, fails fast on unknown IDs, and keeps 0-arg / 1-arg
cospan wait100% backwards-compatible. - On
--timeoutwhile any job is still running, prints a bounded (<= 8 KiB) JSON summary (status: "running",completed_ids,pending_ids, per-jobstatus) with exit code2without dumping completed bodies yet—preventing duplicate context on subsequentwaitcalls. - Updated all generated host skill templates (
agy,codex,claude,dsh,jobs) to spell out when to batchwait(next step needs all parallel outputs together) vs. issue separatewaitcalls (uneven runtimes where acting on the first completion matters).
- Cross-worktree explicit
<job-id>CLI resolution (#9, #12):- CLI and MCP commands passed an explicit
<job-id>(observe,status <id>,result,wait,cancel,continue --id,restart, and batchwait) now fall back across sibling Git worktrees in the same repository family—matching the jobs surfaced in the unified sidebar (wt:*). continue --idandrestartpreserve the original worktree working directory (cwd) and fail cleanly if a removed worktree directory no longer exists, while read-only lookups (observe,result,status <id>) continue working after worktree removal via the repo index.- All no-ID commands (
status,wait,result,observe,continue --last) remain strictly isolated to the current worktree so--lastnever crosses branches.
- CLI and MCP commands passed an explicit
- Generalized Gemini & Claude effort resolution for
agy(#11, #14):- Extended
agymodel-family detection beyond its hardcoded 10-entry allowlist to recognize future versionedgemini-<digit>*andclaude-(opus|sonnet|haiku)-*model IDs automatically. - Checks existing
-(low|medium|high|xhigh)suffixes before family matching so already-suffixed models never get double-suffixed, while explicit--effortcleanly overrides the suffix. - Preserves known-family clamping (
gemini-4-carbon,claude-opus-5-5, etc. clampxhigh -> high;gemini-4-neon,gemini-4-hydrogen, and unknown futuregemini-\d*families allowxhigh) and verbatim passthrough for custom/enterprise non-family models.
- Extended
- Agent-first contributor docs, human-first PR template & Release Checklist (#8, #15, #17):
- Added
CONTRIBUTING.mdwith the change-surface verification matrix, offlinetests/fakes/*policy,Type + Arealabeling rules, and deterministic 5-stepRelease Checklist, plus structured GitHub Issue Forms and a human-first PR template emphasizing plain-languageTL;DR+Before → Afterexamples instead of diff narration.
- Added
Validation
npm run lintnpm run format:checknpm test(63 offline tests: 57 passing on macOS/Linux with 6win32-only skipped)node bin/cospan.mjs installnode bin/cospan.mjs doctor --check
Upgrade
Tip
Recommended — For coding agents: Paste this into any coding agent to upgrade Cospan to v0.1.3 and verify CLI contracts for your current harness automatically:
Read the raw text of https://raw.githubusercontent.com/keli-wen/cospan/master/docs/INSTALL_FOR_AGENTS.md
(curl it — do not work from a summary) and follow it to upgrade Cospan to v0.1.3 and verify it for the harness you are running in.
Respond in the user's language.
Manual upgrade commands (agy / claude / codex / dsh)
- Antigravity (
agy):git -C ~/.cospan/repo pull --ff-only && node ~/.cospan/repo/bin/cospan.mjs install --host agy - Claude Code (
claude):claude plugin marketplace update cospan && claude plugin update cospan@cospan - OpenAI Codex (
codex):codex plugin marketplace upgrade && codex plugin add cospan@cospan - DeepSeek Harness (
dsh):dsh plugin --profile desktop add 'github:keli-wen/cospan#v0.1.3'
Restart Claude Code or Codex after upgrading, then run node <cospan-root>/bin/cospan.mjs doctor --check (zero tokens). For first-time setup, Windows notes, or cache refreshes, see README.md and docs/INSTALL_FOR_AGENTS.md.
Full Changelog: v0.1.2...v0.1.3
cospan v0.1.2 — First-class Windows runtime & gated CI
cospan 0.1.2 — First-class Windows runtime & gated CI
Header illustration generated via cospan-codex.
Highlights
cospan 0.1.2 delivers first-class Windows runtime and plugin support across Antigravity (agy), OpenAI Codex (codex), Claude Code (claude), and DeepSeek Harness (dsh), backed by a real-OS gated windows-latest CI suite and bilingual 40-second walkthrough demos in the README.
What's New
- Native
.cmdshim unwrapping & Windows binary discovery (src/targets.mjs,src/contract-check.mjs,src/commands/*,src/drivers/*,dsh/index.mjs):- Unwraps npm-generated
.cmdshims directly tonode <entry.js>—eliminating NodeCVE-2024-27980spawn EINVALerrors andcmd.exe%VAR%/&/|/ multiline prompt corruption—with safeComSpec /d /s /cquoting fallback for non-Node batch wrappers andwindowsHide: trueacross every child spawn site. - Evaluates
%USERPROFILE%,%APPDATA%\npm, and%LOCALAPPDATA%\Programs\Antigravity\bindynamically with.exe/.cmd/.batresolution during target discovery.
- Unwraps npm-generated
- Stdin prompt transport for Antigravity (
src/drivers/agy.mjs):- Streams
agyprompts overstdininstead of-p <prompt>argv, removing the WindowsCreateProcessW32,767-characterENAMETOOLONGceiling on large context envelopes while keeping prompts out of process-table listings across all OSes.
- Streams
- Detached worker survival, NTFS
state.lockhardening, and stream-worker timing (src/job-worker.mjs,src/state-lock.mjs,src/job-store.mjs,src/stream-worker.mjs,src/commands/lifecycle.mjs,src/sidebar-state.mjs):- Spawns detached
_workerprocesses withdetached: trueon Windows (DETACHED_PROCESS) and movesprocessIdentity()out of parent dispatch andstate.lockcritical sections so jobs register immediately and survive parent CLI exit. - Protects
~/.cospan/trajectories/<ws>/state.jsonwith cross-processstate.lockacquisition, boundedEBUSY/EPERM/EACCESretry loops for NTFSFileShare.Nonehandles, and non-destructiveloadState()error propagation so transient locks never wipe active jobs. - Attaches child
stdout/stderrlisteners immediately on spawn and starts timeout budgets after initial process-tree snapshotting.
- Spawns detached
- Gated Windows CI, 8.3 short-path / CRLF safety, and README walkthrough videos (
.github/workflows/ci.yml,.gitattributes,src/config.mjs,src/repo-family.mjs,src/ui/sync-dsh-client.mjs,README.md,README.zh-CN.md):- Added environment-gated
Tests (Windows)onwindows-latest(55/55tests passing),.gitattributesLF normalization,fs.realpathSync.nativeWindows 8.3 short-path canonicalization (RUNNER~1), CRLF-resilient DSH client bundle syncing, and 40s English & Simplified Chinese demo videos.
- Added environment-gated
Validation
npm run lintnpm run format:checknpm test(55/55 passing acrosswindows-latest,ubuntu-latest, andmacos-latest)node bin/cospan.mjs installnode bin/cospan.mjs doctor --check
Upgrade
Tip
Recommended — For coding agents: Paste this into any coding agent to upgrade Cospan to v0.1.2 and verify CLI contracts for your current harness automatically:
Read the raw text of https://raw.githubusercontent.com/keli-wen/cospan/master/docs/INSTALL_FOR_AGENTS.md
(curl it — do not work from a summary) and follow it to upgrade Cospan to v0.1.2 and verify it for the harness you are running in.
Respond in the user's language.
Manual upgrade commands (agy / claude / codex / dsh)
- Antigravity (
agy):git -C ~/.cospan/repo pull --ff-only && node ~/.cospan/repo/bin/cospan.mjs install --host agy - Claude Code (
claude):claude plugin marketplace update cospan && claude plugin update cospan@cospan - OpenAI Codex (
codex):codex plugin marketplace upgrade && codex plugin add cospan@cospan - DeepSeek Harness (
dsh):dsh plugin --profile desktop add 'github:keli-wen/cospan#v0.1.2'
Restart Claude Code or Codex after upgrading, then run node <cospan-root>/bin/cospan.mjs doctor --check (zero tokens). For first-time setup, Windows notes, or cache refreshes, see README.md and docs/INSTALL_FOR_AGENTS.md.
Full Changelog: v0.1.1...v0.1.2
cospan v0.1.1 — Gemini 4 Neon is in
cospan 0.1.1 — Gemini 4 Neon is in
Header illustration generated via cospan-codex.
Highlights
cospan 0.1.1 brings first-class Gemini 4 Neon support to the Antigravity (agy) harness—keeping existing agy defaults (gemini-3.8-flash-medium) intact while enabling clean neon shortcut and full reasoning effort resolution across all hosts.
What's New
- Gemini 4 Neon shortcut & effort family (
src/config.mjs,src/drivers/agy-protocol.mjs):- Added
neonandgemini-4-neonbuilt-in mappings foragy, defaulting togemini-4-neon-mediumconsistent with the rest of theagymodel family. - Registered
gemini-4-neoninEFFORT_FAMILIESandXHIGH_EFFORT_FAMILIESso--effort low|medium|high|xhigh(andmax -> xhigh) resolves deterministically togemini-4-neon-{low,medium,high,xhigh}on both fresh dispatches andcontinueturns.
- Added
- Synced host skills, MCP schema, and docs (
src/installer-templates.mjs,src/mcp/tools.mjs,skills/agy/SKILL.md,README.md,README.zh-CN.md):- Updated the verbatim model shortcut contract and
xhigheffort notes acrosscospan-agy/$cospan:agyskills,cospan_*MCP parameter descriptions, and README harness tables.
- Updated the verbatim model shortcut contract and
Validation
npm run lintnpm run format:checknpm test(36/36 passing)node bin/cospan.mjs installnode bin/cospan.mjs doctor --check
Upgrade
Tip
Recommended — For coding agents: Paste this into any coding agent to upgrade Cospan to v0.1.1 and verify CLI contracts for your current harness automatically:
Read the raw text of https://raw.githubusercontent.com/keli-wen/cospan/master/docs/INSTALL_FOR_AGENTS.md
(curl it — do not work from a summary) and follow it to upgrade Cospan to v0.1.1 and verify it for the harness you are running in.
Respond in the user's language.
Manual upgrade commands (agy / claude / codex / dsh)
- Antigravity (
agy):git -C ~/.cospan/repo pull --ff-only && node ~/.cospan/repo/bin/cospan.mjs install --host agy - Claude Code (
claude):claude plugin marketplace update cospan && claude plugin update cospan@cospan - OpenAI Codex (
codex):codex plugin marketplace upgrade && codex plugin add cospan@cospan - DeepSeek Harness (
dsh):dsh plugin --profile desktop add 'github:keli-wen/cospan#v0.1.1'
Restart Claude Code or Codex after upgrading, then run node <cospan-root>/bin/cospan.mjs doctor --check (zero tokens). For first-time setup, Windows notes, or cache refreshes, see README.md and docs/INSTALL_FOR_AGENTS.md.
Full Changelog: v0.1.0...v0.1.1
cospan v0.1.0
cospan 0.1.0 — Unified orchestration across coding agents
Header illustration generated via cospan-codex.
Highlights
cospan 0.1.0 is the initial public release of Cospan—a pure-ESM, zero-runtime-dependency async delegation adapter connecting Antigravity (agy), OpenAI Codex (codex), Claude Code (claude), and DeepSeek Harness (dsh).
1. Unified 4-harness async protocol (src/cli.mjs, src/job-worker.mjs, src/drivers/)
- Point-to-point background lifecycle:
send(detached worker),wait(exit codes0/2/3/4/5),observe(bounded<= 8 KiBJSON snapshot),result,continue(native session resume),restart,cancel,status, and foregroundask. - Workspace hygiene: Out-of-tree job logs, specs, and diffs under
~/.cospan/trajectories/; pre-run dirty path tracking and post-run workspace delta reporting on writable runs, plus--readonlyguard warnings. - Process-tree cleanup & locking: Descendant PID group termination on cancel/timeout and atomic state locking across concurrent jobs.
2. Verbatim Model × Effort & 3-layer sparse config (src/config.mjs)
- No host-side model guessing: Model shortcuts (
flash/carbon/argon/hydrogen/opus/sonnetforagy,sol/terra/astra/lunaforcodex,sonnet/opus/haiku/fableforclaude,v4.1-flash/v4-profordsh) and--efforttiers pass verbatim to Cospan and resolve deterministically at runtime. - Sparse layered config: Built-ins → global (
~/.cospan/config.json) → trajectory → workspace (.cospan/config.json), with override provenance incospan config --jsonand sparse{}initialization.
3. Unified live sidebar & worktree family aggregation (src/ui/, src/sidecar/, dsh/)
- Shared board across
agyanddsh: Sidecar HTTP server (cospan_boardin Antigravity) and Cordis web bundle (dsh/client.jsin DeepSeek Harness) display live background jobs, Q&A outputs, and cancel actions across all four targets. - Git worktree aggregation (
wt:*): Automatically groups sibling worktree trajectories under the same repository family (src/repo-family.mjs).
4. Bundled MCP, host installers, zero-drift contracts & update hygiene (src/mcp/, src/installer.mjs, src/update-check.mjs)
- Stdio MCP & native DSH tools: Exposes
cospan_send,cospan_wait,cospan_observe,cospan_continue,cospan_result,cospan_cancel,cospan_status, andcospan_askoutside host command sandboxes. - Zero-token contract verification & update check:
cospan doctor --checkverifies installed binary--helpflags against driver expectations; non-blocking 24h TTL update check and legacy config override warnings surface new releases and stale model pins cleanly.
Validation
npm run lint(ESLint modularity & complexity gates)npm run format:check(Prettier)npm test(35 offline unit, driver, installer, MCP, sidebar UI, worktree, and update-check smoke tests)node bin/cospan.mjs doctor --check(4-harness--helpcontract probe)
Install & Upgrade
See README.md and the agent guide in docs/INSTALL_FOR_AGENTS.md.



