tickmarkr 1.86.0 → 1.89.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (74) hide show
  1. package/dist/adapters/catalog.d.ts +30 -1
  2. package/dist/adapters/catalog.js +58 -2
  3. package/dist/adapters/fake.d.ts +2 -1
  4. package/dist/adapters/fake.js +7 -0
  5. package/dist/adapters/grok.js +11 -0
  6. package/dist/adapters/kimi.d.ts +2 -1
  7. package/dist/adapters/kimi.js +36 -0
  8. package/dist/adapters/opencode.js +17 -0
  9. package/dist/adapters/pi.js +11 -0
  10. package/dist/adapters/prompt.js +8 -1
  11. package/dist/adapters/registry.d.ts +10 -2
  12. package/dist/adapters/registry.js +126 -67
  13. package/dist/adapters/types.d.ts +34 -3
  14. package/dist/adapters/types.js +99 -1
  15. package/dist/cli/commands/approve.d.ts +2 -0
  16. package/dist/cli/commands/approve.js +104 -84
  17. package/dist/cli/commands/compile.d.ts +1 -1
  18. package/dist/cli/commands/compile.js +29 -12
  19. package/dist/cli/commands/init.js +1 -1
  20. package/dist/cli/commands/plan.d.ts +1 -1
  21. package/dist/cli/commands/plan.js +21 -2
  22. package/dist/cli/commands/report.js +49 -0
  23. package/dist/cli/commands/resume.js +7 -1
  24. package/dist/cli/commands/status.js +298 -96
  25. package/dist/cli/harness.d.ts +13 -0
  26. package/dist/cli/harness.js +50 -0
  27. package/dist/compile/collateral.js +4 -4
  28. package/dist/compile/index.d.ts +14 -3
  29. package/dist/compile/index.js +36 -10
  30. package/dist/compile/native.js +108 -25
  31. package/dist/drivers/subprocess.d.ts +6 -1
  32. package/dist/drivers/subprocess.js +9 -4
  33. package/dist/gates/acceptance.d.ts +21 -1
  34. package/dist/gates/acceptance.js +67 -22
  35. package/dist/gates/artifact-manifest.d.ts +119 -0
  36. package/dist/gates/artifact-manifest.js +357 -0
  37. package/dist/gates/baseline.d.ts +6 -0
  38. package/dist/gates/baseline.js +52 -7
  39. package/dist/gates/llm.js +37 -26
  40. package/dist/gates/review.d.ts +16 -11
  41. package/dist/gates/review.js +44 -150
  42. package/dist/gates/run-gates.d.ts +1 -0
  43. package/dist/gates/run-gates.js +145 -9
  44. package/dist/graph/schema.d.ts +3 -1
  45. package/dist/graph/schema.js +4 -1
  46. package/dist/route/preference.d.ts +1 -1
  47. package/dist/route/preference.js +8 -1
  48. package/dist/run/consult.js +14 -1
  49. package/dist/run/daemon.d.ts +42 -0
  50. package/dist/run/daemon.js +2322 -1963
  51. package/dist/run/git.d.ts +50 -0
  52. package/dist/run/git.js +113 -2
  53. package/dist/run/interactive-seed.d.ts +6 -2
  54. package/dist/run/interactive-seed.js +72 -5
  55. package/dist/run/journal.d.ts +9 -1
  56. package/dist/run/journal.js +99 -9
  57. package/dist/run/lock.d.ts +11 -0
  58. package/dist/run/lock.js +97 -6
  59. package/dist/run/outcome.d.ts +50 -0
  60. package/dist/run/outcome.js +152 -0
  61. package/dist/run/protocol.d.ts +460 -0
  62. package/dist/run/protocol.js +433 -0
  63. package/dist/run/supervision.d.ts +29 -0
  64. package/dist/run/supervision.js +189 -0
  65. package/fixtures/gateway-models.json +1 -0
  66. package/fixtures/wrapped-acceptance.native.md +29 -0
  67. package/package.json +1 -1
  68. package/schema/rungraph.schema.json +21 -2
  69. package/skills/tickmarkr-overseer/SKILL.md +366 -4
  70. package/skills/tickmarkr-overseer/scripts/watch-artifacts.sh +95 -8
  71. package/skills/tickmarkr-overseer/scripts/watch-contamination.sh +77 -0
  72. package/skills/tickmarkr-overseer/scripts/watch-context.sh +86 -0
  73. package/skills/tickmarkr-overseer/scripts/watch-parks.sh +96 -0
  74. package/skills/tickmarkr-overseer/scripts/watch-pending-input.sh +183 -0
@@ -1,6 +1,7 @@
1
1
  import { type WorkerAdapter } from "../adapters/types.js";
2
2
  import { type ModeResolution, type RoutingMode, type TickmarkrConfig } from "../config/config.js";
3
3
  import { type ExecutorDriver } from "../drivers/types.js";
4
+ import type { GateResult } from "../gates/types.js";
4
5
  import { Journal, type JournalEvent } from "./journal.js";
5
6
  export interface RunOptions {
6
7
  runId?: string;
@@ -15,6 +16,7 @@ export interface RunOptions {
15
16
  mode?: RoutingMode;
16
17
  narrate?: (event: JournalEvent) => void;
17
18
  exit?: (code: number) => void;
19
+ supervise?: boolean;
18
20
  }
19
21
  export type ModeSource = "run flag" | "spec" | "repo config" | "global config" | "default";
20
22
  export interface ResolvedRunMode {
@@ -40,8 +42,45 @@ export interface RunSummary {
40
42
  blocked: string[];
41
43
  tipVerify?: "passed" | "failed";
42
44
  lastMergedTask?: string;
45
+ /** T14: did every approval this run accepted actually get enacted, or did the run end over one? */
46
+ approvalDisposition?: "complete" | "outstanding";
47
+ /** the accepted approvals that never reached a dispatch — named, never left to the park buckets */
48
+ outstandingApprovals?: string[];
43
49
  }
50
+ /**
51
+ * T14: approvals the run accepted and never acted on. `approved` above is built ONCE at startup —
52
+ * deliberately, replay determinism depends on it — so an approval written while the daemon is live is
53
+ * inert for that run. Without this the run-end record stated only buckets and tipVerify, both
54
+ * accurate, over a milestone that was silently incomplete: run …230 ended tipVerify "passed" with two
55
+ * upheld approvals and zero subsequent dispatches. Scored per task on its NEWEST approval: a later
56
+ * approval is the live decision, and the events that answer it are the ones after it.
57
+ */
58
+ export declare function outstandingApprovals(events: JournalEvent[]): string[];
44
59
  export declare function formatSummary(s: RunSummary): string;
60
+ /**
61
+ * R3 (OBS-186): a gate that DECLINED to run is not a gate that failed. The review gate's skip branch
62
+ * no longer forges `pass: true` to buy passage, so the merge decision has to read the same predicate
63
+ * the run surfaces already read (src/run/activity.ts): pass, or an honest declared skip. Without this
64
+ * the honesty change would silently park every judge-only task at merge — an unrun gate blocking work
65
+ * it was never asked to review. `skipped` is set only by a gate that says so about ITSELF; a red
66
+ * verdict from a review that actually ran still fails here, exactly as before.
67
+ *
68
+ * ONE pair of predicates, every fold. `!g.pass` was correct only while the sole `pass:false` producer
69
+ * was a gate that actually failed; the moment a decline can be recorded red, every `!g.pass` in this
70
+ * file — the retry feedback brief, the review-fix eligibility test, the failing-battery list the
71
+ * ladder and the fingerprint cap are scored on, the structured findings attached to a blocking
72
+ * verdict — reads an unrun gate as a defect. `gateFailed` is the seam they now share, and the journal
73
+ * write below is the seam every OUT-of-file fold shares.
74
+ */
75
+ /**
76
+ * T9: `meta.infra === true` overrides BOTH clauses above. A runner that died on the machine
77
+ * (spawn EAGAIN, OOM) without completing a suite answered nothing about the work, so the honest
78
+ * report of that fact must not double as authorization to merge — and it is the merge predicate,
79
+ * not the gate, that has to say so: classifying the failure into infra metadata while still
80
+ * reporting `pass: true` is exactly how a run that never verified anything gets merged. A declared
81
+ * skip stays satisfied; a gate that ran and passed stays satisfied.
82
+ */
83
+ export declare const gateSatisfied: (g: GateResult) => boolean;
45
84
  /**
46
85
  * T4 (OBS-265): the journal with the review objections a round did NOT hinge on removed. Judge and
47
86
  * review are now launched together, so a round can journal a failed review that the serial walk would
@@ -97,4 +136,7 @@ export declare function workerTreeCpuMs(marker: string, cwd: string): Promise<{
97
136
  ms: number;
98
137
  resolutionMs: number;
99
138
  } | undefined>;
139
+ /** Test seam — exercise the production observer's total read bound with a small real tree. */
140
+ export declare function setObserveBudgetBytesForTests(bytes: number): void;
141
+ export declare function resetObserveBudgetBytesForTests(): void;
100
142
  export declare function runDaemon(repoRoot: string, opts?: RunOptions): Promise<RunSummary>;