Run.Ts

loom-builderarchiveother
Path: loom-builder/_archive/run.ts-versions/run.ts.pre-dispatch-artifact-contract-2026-06-17Relative: _archive/run.ts-versions/run.ts.pre-dispatch-artifact-contract-2026-06-17Subproject: loom-builderCategory: archived
Lines: 292Bytes: 11,116Imports: 0Exports: 0

Content Preview

  1. /**
  2. * loom-builder — homeostatic dispatch harness.
  3. * Runs one DispatchSpec: agent loop (pi-coding-agent SDK) under hard gates,
  4. * machine validation as the only done-criterion, bounded reformulation,
  5. * JSONL trace + digest/manifest outputs.
  6. *
  7. * Usage: bun run src/run.ts <spec.json>
  8. */
  9. import { mkdirSync, readFileSync, writeFileSync } from "node:fs";
  10. import { join, resolve } from "node:path";
  11. import {
  12. AuthStorage,
  13. ModelRegistry,
  14. SessionManager,
  15. createAgentSession,
  16. createCodingTool