Gate Analyzer

loom-builder-solarchivetypescript
Path: loom-builder-sol/_archive/pre-080/gate-analyzer.tsRelative: _archive/pre-080/gate-analyzer.tsSubproject: loom-builder-solCategory: archived
Lines: 573Bytes: 18,277Imports: 6Exports: 7

Content Preview

  1. /**
  2. * gate-analyzer — preflight gate complexity review.
  3. *
  4. * Runs on EVERY dispatch after spec lint, before the executor launches.
  5. * Two layers:
  6. * Layer A — deterministic heuristics (pure code, no LLM)
  7. * Layer B — LLM review (cheap model, read-only analysis)
  8. *
  9. * Design: always on (no config flag), like the artifact contract and escalation loop.
  10. */
  11. import { readFileSync } from "node:fs";
  12. import { join } from "node:path";
  13. import type { DispatchSpec, ValidationCmd, GateAnalysisFinding,