@mmnto/cli 1.106.0 → 1.107.1

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 (49) hide show
  1. package/dist/commands/doctor-qbd.d.ts +40 -0
  2. package/dist/commands/doctor-qbd.d.ts.map +1 -0
  3. package/dist/commands/doctor-qbd.js +156 -0
  4. package/dist/commands/doctor-qbd.js.map +1 -0
  5. package/dist/commands/doctor-qbd.test.d.ts +13 -0
  6. package/dist/commands/doctor-qbd.test.d.ts.map +1 -0
  7. package/dist/commands/doctor-qbd.test.js +548 -0
  8. package/dist/commands/doctor-qbd.test.js.map +1 -0
  9. package/dist/commands/init-templates.js +3 -3
  10. package/dist/commands/init-templates.js.map +1 -1
  11. package/dist/commands/mail-degraded-e4.test.d.ts +5 -1
  12. package/dist/commands/mail-degraded-e4.test.d.ts.map +1 -1
  13. package/dist/commands/mail-degraded-e4.test.js +129 -2
  14. package/dist/commands/mail-degraded-e4.test.js.map +1 -1
  15. package/dist/commands/mail.d.ts +1 -0
  16. package/dist/commands/mail.d.ts.map +1 -1
  17. package/dist/commands/mail.js +16 -3
  18. package/dist/commands/mail.js.map +1 -1
  19. package/dist/commands/orient.d.ts.map +1 -1
  20. package/dist/commands/orient.js +23 -0
  21. package/dist/commands/orient.js.map +1 -1
  22. package/dist/commands/qbd-seam.d.ts +77 -0
  23. package/dist/commands/qbd-seam.d.ts.map +1 -0
  24. package/dist/commands/qbd-seam.js +150 -0
  25. package/dist/commands/qbd-seam.js.map +1 -0
  26. package/dist/commands/qbd-seam.test.d.ts +16 -0
  27. package/dist/commands/qbd-seam.test.d.ts.map +1 -0
  28. package/dist/commands/qbd-seam.test.js +339 -0
  29. package/dist/commands/qbd-seam.test.js.map +1 -0
  30. package/dist/commands/review-fan.d.ts.map +1 -1
  31. package/dist/commands/review-fan.js +26 -0
  32. package/dist/commands/review-fan.js.map +1 -1
  33. package/dist/commands/search.d.ts.map +1 -1
  34. package/dist/commands/search.js +15 -0
  35. package/dist/commands/search.js.map +1 -1
  36. package/dist/commands/shield-classify.d.ts.map +1 -1
  37. package/dist/commands/shield-classify.js +2 -0
  38. package/dist/commands/shield-classify.js.map +1 -1
  39. package/dist/commands/shield-classify.test.js +12 -0
  40. package/dist/commands/shield-classify.test.js.map +1 -1
  41. package/dist/commands/shield.d.ts.map +1 -1
  42. package/dist/commands/shield.js +34 -0
  43. package/dist/commands/shield.js.map +1 -1
  44. package/dist/commands/spec.d.ts.map +1 -1
  45. package/dist/commands/spec.js +16 -0
  46. package/dist/commands/spec.js.map +1 -1
  47. package/dist/index.js +8 -1
  48. package/dist/index.js.map +1 -1
  49. package/package.json +2 -2
@@ -0,0 +1,40 @@
1
+ /**
2
+ * `totem doctor --compliance` — query-before-derive section (mmnto-ai/totem#2510).
3
+ *
4
+ * Renders ONE number: of the derive-class actions in an agent session (spec
5
+ * synthesis, orientation derivation, review grounding), what fraction was
6
+ * preceded by a corpus query correlated to that action — plus its trend and the
7
+ * pre-registered threshold it will be judged against.
8
+ *
9
+ * Sensor, not actuator (Tenet 13): this section renders and returns. It never
10
+ * throws for a compliance verdict and never influences the exit code. Nothing
11
+ * in Totem blocks on this number in v1, by charter.
12
+ *
13
+ * Reads alongside the existing ADR-029 recall-compliance section rather than
14
+ * replacing it: that metric is search-before-COMMIT at commit granularity; this
15
+ * one is query-before-DERIVE at event granularity with explicit correlation IDs.
16
+ * Different denominators, different claims, both printed under `--compliance`.
17
+ */
18
+ export interface QbdComplianceCliOptions {
19
+ /** Test seam — production callers omit and the command uses `process.cwd()`. */
20
+ cwdForTest?: string;
21
+ /** Test seam — inject raw ledger NDJSON instead of reading from disk. */
22
+ ledgerContentForTest?: string;
23
+ /**
24
+ * Test seam — point global-profile resolution at a temp home. Without it a
25
+ * test in a config-less directory resolves the developer's REAL `~/.totem/`
26
+ * profile and reads (or, on the write side, writes) their live ledger.
27
+ */
28
+ homeDirForTest?: string;
29
+ }
30
+ /**
31
+ * Render the query-before-derive compliance section.
32
+ *
33
+ * Degraded-read contract (ADR-115 § 2): a scan that hit malformed lines,
34
+ * correlation-contract violations, or unjoinable correlation IDs renders under
35
+ * an explicit `DEGRADED` / `UNVERIFIED` envelope with per-item counts. A broken
36
+ * ledger scan must never render like a clean 100% or a clean 0% — that
37
+ * indistinguishability IS the defect class, not an acceptable degradation.
38
+ */
39
+ export declare function doctorQbdComplianceCommand(options?: QbdComplianceCliOptions): Promise<void>;
40
+ //# sourceMappingURL=doctor-qbd.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"doctor-qbd.d.ts","sourceRoot":"","sources":["../../src/commands/doctor-qbd.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAOH,MAAM,WAAW,uBAAuB;IACtC,gFAAgF;IAChF,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,yEAAyE;IACzE,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B;;;;OAIG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED;;;;;;;;GAQG;AACH,wBAAsB,0BAA0B,CAC9C,OAAO,GAAE,uBAA4B,GACpC,OAAO,CAAC,IAAI,CAAC,CAgMf"}
@@ -0,0 +1,156 @@
1
+ /**
2
+ * `totem doctor --compliance` — query-before-derive section (mmnto-ai/totem#2510).
3
+ *
4
+ * Renders ONE number: of the derive-class actions in an agent session (spec
5
+ * synthesis, orientation derivation, review grounding), what fraction was
6
+ * preceded by a corpus query correlated to that action — plus its trend and the
7
+ * pre-registered threshold it will be judged against.
8
+ *
9
+ * Sensor, not actuator (Tenet 13): this section renders and returns. It never
10
+ * throws for a compliance verdict and never influences the exit code. Nothing
11
+ * in Totem blocks on this number in v1, by charter.
12
+ *
13
+ * Reads alongside the existing ADR-029 recall-compliance section rather than
14
+ * replacing it: that metric is search-before-COMMIT at commit granularity; this
15
+ * one is query-before-DERIVE at event granularity with explicit correlation IDs.
16
+ * Different denominators, different claims, both printed under `--compliance`.
17
+ */
18
+ const TAG = 'Compliance';
19
+ /** Ledger location, relative to the resolved totemDir. */
20
+ const LEDGER_RELATIVE_PATH = ['ledger', 'events.ndjson'];
21
+ /**
22
+ * Render the query-before-derive compliance section.
23
+ *
24
+ * Degraded-read contract (ADR-115 § 2): a scan that hit malformed lines,
25
+ * correlation-contract violations, or unjoinable correlation IDs renders under
26
+ * an explicit `DEGRADED` / `UNVERIFIED` envelope with per-item counts. A broken
27
+ * ledger scan must never render like a clean 100% or a clean 0% — that
28
+ * indistinguishability IS the defect class, not an acceptable degradation.
29
+ */
30
+ export async function doctorQbdComplianceCommand(options = {}) {
31
+ const fs = await import('node:fs');
32
+ const path = await import('node:path');
33
+ const { computeQbdCompliance, formatQbdRate, QBD_PRE_REGISTERED_WINDOW_SESSIONS, QBD_PRE_REGISTRATION_STATEMENT, sanitizeForTerminal, scanQbdLedger, } = await import('@mmnto/totem');
34
+ const { bold, log } = await import('../ui.js');
35
+ const cwd = options.cwdForTest ?? process.cwd();
36
+ // Resolve the ledger through the SAME helper the write seams use, so the
37
+ // reader can never look somewhere the writers do not write (they diverged
38
+ // once already: seams joined `cwd`, which misses the project ledger whenever
39
+ // a command runs from a subdirectory).
40
+ //
41
+ // There is deliberately NO `?? path.join(cwd, '.totem')` fallback. The writers
42
+ // SKIP when config is unresolved, so a reader that fell back to `<cwd>/.totem`
43
+ // would read a ledger no writer ever writes — reviving the exact divergence
44
+ // the comment above claims is closed, and letting a stale directory render as
45
+ // if it were this project's data. Unresolved is its own honest state.
46
+ const { resolveQbdLedgerDirDetailed } = await import('./qbd-seam.js');
47
+ const resolved = await resolveQbdLedgerDirDetailed(cwd, options.homeDirForTest);
48
+ if (resolved.dir === undefined) {
49
+ log.info(TAG, bold('Query-before-derive compliance'));
50
+ log.dim(TAG, `SKIP — ${resolved.reason ?? 'no ledger could be resolved'}. Nothing is recorded from here either, so there is nothing to read.`);
51
+ return;
52
+ }
53
+ const totemDir = resolved.dir;
54
+ const ledgerPath = path.join(totemDir, ...LEDGER_RELATIVE_PATH);
55
+ // totemDir is repo-controlled config — sanitize before it reaches a terminal.
56
+ const displayPath = sanitizeForTerminal(path.join(totemDir, ...LEDGER_RELATIVE_PATH));
57
+ log.info(TAG, bold('Query-before-derive compliance'));
58
+ let content;
59
+ if (options.ledgerContentForTest !== undefined) {
60
+ content = options.ledgerContentForTest;
61
+ }
62
+ else if (!fs.existsSync(ledgerPath)) {
63
+ // Absent ledger → skip idiom. NOT a fail, and emphatically NOT 0%.
64
+ log.dim(TAG, `SKIP — no ${displayPath} found. Query-before-derive rows are written by \`totem search\`, the MCP search_knowledge tool, and the derive-class commands (spec / orient / review); run some, then re-run totem doctor --compliance.`);
65
+ return;
66
+ }
67
+ else {
68
+ try {
69
+ content = fs.readFileSync(ledgerPath, 'utf-8');
70
+ // totem-context: an unreadable ledger is the honest-absent path for this read-only sensor — degrade to the skip idiom, never crash the doctor pipeline.
71
+ }
72
+ catch (err) {
73
+ // Name the errno. EACCES (permissions), EISDIR (a directory where the
74
+ // file belongs), and ENOTDIR (a component is a file) are three different
75
+ // problems with three different fixes; collapsing them into "unreadable"
76
+ // tells the reader nothing actionable.
77
+ const code = typeof err === 'object' && err !== null
78
+ ? (err.code ?? 'unknown')
79
+ : 'unknown';
80
+ log.dim(TAG, `SKIP — ${displayPath} present but unreadable (${code}).`);
81
+ return;
82
+ }
83
+ }
84
+ const scan = scanQbdLedger(content);
85
+ const report = computeQbdCompliance(scan);
86
+ // ── Degraded envelope FIRST, so the number is never read bare ──
87
+ if (report.degraded) {
88
+ log.warn(TAG, `DEGRADED — the ledger scan hit rows it could not trust; the compliance number below is UNVERIFIED`);
89
+ const a = report.anomalies;
90
+ if (a.malformedJson > 0)
91
+ log.warn(TAG, ` ${a.malformedJson} malformed JSON line(s)`);
92
+ if (a.correlationContractViolations > 0) {
93
+ log.warn(TAG, ` ${a.correlationContractViolations} correlation-contract violation(s) — an ID that could not have been minted when its row was written (backfill)`);
94
+ }
95
+ if (a.unclassifiedInvalid > 0) {
96
+ log.warn(TAG, ` ${a.unclassifiedInvalid} unclassifiable invalid row(s)`);
97
+ }
98
+ if (a.orphanCorrelations > 0) {
99
+ log.warn(TAG, ` ${a.orphanCorrelations} derive(s) citing a correlation ID with no preceding query row`);
100
+ }
101
+ if (a.crossSessionCorrelations > 0) {
102
+ log.warn(TAG, ` ${a.crossSessionCorrelations} derive(s) correlated to a query from another session or seat`);
103
+ }
104
+ if (a.duplicateCorrelations > 0) {
105
+ log.warn(TAG, ` ${a.duplicateCorrelations} derive(s) re-citing a correlation ID an earlier derive already spent (one query grounds one derive)`);
106
+ }
107
+ if (a.backdatedRows > 0) {
108
+ log.warn(TAG, ` ${a.backdatedRows} row(s) with timestamps regressing in an append-only ledger (backdated append)`);
109
+ }
110
+ for (const detail of a.details)
111
+ log.dim(TAG, ` · ${sanitizeForTerminal(detail)}`);
112
+ // Remediation. Degraded is sticky by design — one bad row degrades the whole
113
+ // read, and neither the row nor the verdict expires — so without this the
114
+ // envelope is a permanent unactionable banner. Say which file to open.
115
+ log.dim(TAG, ` to clear: inspect the cited line numbers in ${displayPath} (append-only — repair by appending corrections, never by rewriting history), then re-run.`);
116
+ }
117
+ // Seat-plumbing hint — deliberately OUTSIDE the degraded envelope: one-sided
118
+ // seat plumbing is a config smell, not evidence of tampering.
119
+ if (report.anomalies.seatMismatchHints > 0) {
120
+ log.dim(TAG, `note: ${report.anomalies.seatMismatchHints} uncorrelated derive(s) had an in-window query from a DIFFERENT seat — likely one-sided seat plumbing (e.g. a seated CLI and an unseated MCP server), which drives this number down with no other tell. Seat plumbing is tracked separately in mmnto-ai/totem#2530.`);
121
+ }
122
+ // Advisory — deliberately OUTSIDE the degraded envelope: an event type this
123
+ // build does not know is ordinary version skew, not evidence of tampering.
124
+ if (report.anomalies.unknownTypeRows > 0) {
125
+ log.dim(TAG, `note: ${report.anomalies.unknownTypeRows} row(s) carry an event type this build does not know (version skew — not counted against integrity)`);
126
+ }
127
+ // Every DERIVED line carries the qualifier, not just the headline figure.
128
+ // The verdict line is the one that carries the pre-registered consequence —
129
+ // rendering `verdict: PASS` unqualified beside an UNVERIFIED number is the
130
+ // same indistinguishability the envelope exists to prevent. Trend too: it is
131
+ // computed from the same untrusted rows.
132
+ const unverified = report.degraded ? ' (UNVERIFIED)' : '';
133
+ // ── The number ──
134
+ log.info(TAG, `compliance${unverified}: ${formatQbdRate(report.window)} over ${report.evaluatedSessions} instrumented session(s)`);
135
+ // ── Pre-registration, verbatim (charter requirement) ──
136
+ log.dim(TAG, `pre-registered threshold + window: ${QBD_PRE_REGISTRATION_STATEMENT}`);
137
+ if (report.verdict === 'PENDING') {
138
+ log.dim(TAG, `verdict${unverified}: PENDING — ${report.instrumentedSessions}/${QBD_PRE_REGISTERED_WINDOW_SESSIONS} instrumented sessions recorded; the threshold is not evaluable until the window fills`);
139
+ }
140
+ else if (report.verdict === 'PASS') {
141
+ log.success(TAG, `verdict${unverified}: PASS — at or above the pre-registered floor over the window`);
142
+ }
143
+ else {
144
+ log.warn(TAG, `verdict${unverified}: FAIL — below the pre-registered floor over the window. Per the #2510 pre-registration the adherence claims' Goal: prefixes are recorded as FALSIFIED for this window, and this number leads the next signoff.`);
145
+ }
146
+ // ── Trend ──
147
+ if (report.trend === null) {
148
+ log.dim(TAG, `trend${unverified}: insufficient data (needs at least 4 instrumented sessions)`);
149
+ }
150
+ else {
151
+ log.dim(TAG, `trend${unverified}: earlier ${formatQbdRate(report.trend.earlier)} → recent ${formatQbdRate(report.trend.recent)}`);
152
+ }
153
+ // ── Honest limitation (#2510 falsifier 4) ──
154
+ log.dim(TAG, 'limitation: this senses query-before-derive ADJACENCY, not influence — a query whose results the derive never read still counts as compliant (ritual-query / Goodhart). Named, not solved.');
155
+ }
156
+ //# sourceMappingURL=doctor-qbd.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"doctor-qbd.js","sourceRoot":"","sources":["../../src/commands/doctor-qbd.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,MAA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kCAAkC,wFAAwF,CAC7L,CAAC;IACJ,CAAC;SAAM,IAAI,MAAM,CAAC,OAAO,KAAK,MAAM,EAAE,CAAC;QACrC,GAAG,CAAC,OAAO,CACT,GAAG,EACH,UAAU,UAAU,+DAA+D,CACpF,CAAC;IACJ,CAAC;SAAM,CAAC;QACN,GAAG,CAAC,IAAI,CACN,GAAG,EACH,UAAU,UAAU,iNAAiN,CACtO,CAAC;IACJ,CAAC;IAED,cAAc;IACd,IAAI,MAAM,CAAC,KAAK,KAAK,IAAI,EAAE,CAAC;QAC1B,GAAG,CAAC,GAAG,CAAC,GAAG,EAAE,QAAQ,UAAU,8DAA8D,CAAC,CAAC;IACjG,CAAC;SAAM,CAAC;QACN,GAAG,CAAC,GAAG,CACL,GAAG,EACH,QAAQ,UAAU,aAAa,aAAa,CAAC,MAAM,CAAC,KAAK,CAAC,OAAO,CAAC,aAAa,aAAa,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,EAAE,CACpH,CAAC;IACJ,CAAC;IAED,8CAA8C;IAC9C,GAAG,CAAC,GAAG,CACL,GAAG,EACH,4LAA4L,CAC7L,CAAC;AACJ,CAAC"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Render tests for the `totem doctor --compliance` query-before-derive section
3
+ * (mmnto-ai/totem#2510).
4
+ *
5
+ * The degraded-read block follows the ADR-115 § 2 convention: this is a
6
+ * READ-ONLY path, so the backstop is an explicit `DEGRADED` / `UNVERIFIED`
7
+ * envelope in the rendered output — never a nonzero exit — and the per-item
8
+ * accounting is asserted by the specific failing class being NAMED. The control
9
+ * assertion pins that a clean ledger renders no envelope at all, so the envelope
10
+ * cannot rot into decoration that is always present.
11
+ */
12
+ export {};
13
+ //# sourceMappingURL=doctor-qbd.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"doctor-qbd.test.d.ts","sourceRoot":"","sources":["../../src/commands/doctor-qbd.test.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG"}