@productbrain/cli 0.1.0-beta.9927 → 0.1.0-beta.9944

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 (55) hide show
  1. package/dist/__tests__/gateway-timeout-body-phase.test.js +3 -8
  2. package/dist/__tests__/gateway-timeout-body-phase.test.js.map +1 -1
  3. package/dist/__tests__/orient.test.js +1 -13
  4. package/dist/__tests__/orient.test.js.map +1 -1
  5. package/dist/__tests__/read-target-notice.test.js +3 -7
  6. package/dist/__tests__/read-target-notice.test.js.map +1 -1
  7. package/dist/commands/orient.d.ts +0 -4
  8. package/dist/commands/orient.d.ts.map +1 -1
  9. package/dist/commands/orient.js.map +1 -1
  10. package/dist/commands/outcome.d.ts +2 -2
  11. package/dist/commands/outcome.d.ts.map +1 -1
  12. package/dist/commands/questions.js +2 -2
  13. package/dist/commands/questions.js.map +1 -1
  14. package/dist/commands/questions.test.js +1 -1
  15. package/dist/formatters/orient.d.ts +2 -17
  16. package/dist/formatters/orient.d.ts.map +1 -1
  17. package/dist/formatters/orient.js +1 -16
  18. package/dist/formatters/orient.js.map +1 -1
  19. package/dist/formatters/orientDirection.d.ts +1 -23
  20. package/dist/formatters/orientDirection.d.ts.map +1 -1
  21. package/dist/formatters/orientDirection.js +2 -18
  22. package/dist/formatters/orientDirection.js.map +1 -1
  23. package/dist/formatters/orientDirection.test.js +0 -22
  24. package/dist/formatters/orientDirection.test.js.map +1 -1
  25. package/dist/formatters/questions.d.ts +1 -1
  26. package/dist/formatters/questions.js +2 -2
  27. package/dist/index.js +0 -2
  28. package/dist/index.js.map +1 -1
  29. package/dist/lib/client.d.ts +0 -15
  30. package/dist/lib/client.d.ts.map +1 -1
  31. package/dist/lib/client.js +0 -12
  32. package/dist/lib/client.js.map +1 -1
  33. package/dist/lib/workspaceNotice.d.ts +2 -2
  34. package/dist/lib/workspaceNotice.js +2 -2
  35. package/package.json +1 -1
  36. package/dist/commands/shape.d.ts +0 -16
  37. package/dist/commands/shape.d.ts.map +0 -1
  38. package/dist/commands/shape.js +0 -149
  39. package/dist/commands/shape.js.map +0 -1
  40. package/dist/commands/shape.test.d.ts +0 -2
  41. package/dist/commands/shape.test.d.ts.map +0 -1
  42. package/dist/commands/shape.test.js +0 -148
  43. package/dist/commands/shape.test.js.map +0 -1
  44. package/dist/formatters/orient.shapeAdvisorySummary.test.d.ts +0 -2
  45. package/dist/formatters/orient.shapeAdvisorySummary.test.d.ts.map +0 -1
  46. package/dist/formatters/orient.shapeAdvisorySummary.test.js +0 -59
  47. package/dist/formatters/orient.shapeAdvisorySummary.test.js.map +0 -1
  48. package/dist/formatters/shape.d.ts +0 -54
  49. package/dist/formatters/shape.d.ts.map +0 -1
  50. package/dist/formatters/shape.js +0 -97
  51. package/dist/formatters/shape.js.map +0 -1
  52. package/dist/formatters/shape.test.d.ts +0 -2
  53. package/dist/formatters/shape.test.d.ts.map +0 -1
  54. package/dist/formatters/shape.test.js +0 -80
  55. package/dist/formatters/shape.test.js.map +0 -1
@@ -1,80 +0,0 @@
1
- import { describe, expect, it } from 'vitest';
2
- import { formatShapeAdvisoriesList, formatShapeAdvisoryShow, formatShapeDispositionReceipt, } from './shape.js';
3
- const NOW = 1_800_000_000_000;
4
- function item(overrides = {}) {
5
- return {
6
- id: 'row-1',
7
- outcome: 'compound',
8
- disposition: 'pending',
9
- subjectEntryId: 'INB-1',
10
- collectionSlug: 'inbox',
11
- source: 'cli',
12
- at: NOW - 5 * 60 * 1000,
13
- ...overrides,
14
- };
15
- }
16
- describe('shape formatters', () => {
17
- it('renders an empty list cleanly', () => {
18
- expect(formatShapeAdvisoriesList([], NOW)).toBe('No shape advisories match.');
19
- });
20
- it('renders list rows with the non-underscore id (TEN-340), outcome, and disposition', () => {
21
- const output = formatShapeAdvisoriesList([item()], NOW);
22
- expect(output).toContain('Shape advisories (1)');
23
- expect(output).toContain('row-1');
24
- expect(output).toContain('compound');
25
- expect(output).toContain('disposition:pending');
26
- });
27
- // WP-571 sweep (review finding on PR #513/#517): `truncated` surfaces the backend's
28
- // LIST_SCAN_CAP safety-bound signal — the operator must be told a result MAY be
29
- // incomplete, not just handed a plain list indistinguishable from "that's everything."
30
- it('appends a truncation note when truncated is true, with rows', () => {
31
- const output = formatShapeAdvisoriesList([item()], NOW, true);
32
- expect(output).toContain('Shape advisories (1)');
33
- expect(output).toMatch(/incomplete/i);
34
- });
35
- it('appends a truncation note when truncated is true, with zero rows', () => {
36
- const output = formatShapeAdvisoriesList([], NOW, true);
37
- expect(output).toContain('No shape advisories match.');
38
- expect(output).toMatch(/incomplete/i);
39
- });
40
- it('omits the truncation note by default (truncated defaults to false)', () => {
41
- const output = formatShapeAdvisoriesList([item()], NOW);
42
- expect(output).not.toMatch(/incomplete/i);
43
- });
44
- it('renders "advisory not found" for a null show result', () => {
45
- expect(formatShapeAdvisoryShow(null)).toContain('not found');
46
- });
47
- it('review round 1 (Codex P2 fix): renders the proposed split (atoms + links) so a human can inspect it before agreeing/dismissing', () => {
48
- const output = formatShapeAdvisoryShow(item({
49
- proposedAtoms: [
50
- { title: 'Atom A', concern: 'shape', bodyExcerpt: 'first idea' },
51
- { title: 'Atom B', concern: 'shape', bodyExcerpt: 'second idea', suggestedCollection: 'decisions' },
52
- ],
53
- proposedLinks: [
54
- { fromIdx: -1, toIdx: 0, relation: 'relates_to' },
55
- { fromIdx: 0, toIdx: 1, relation: 'relates_to' },
56
- ],
57
- }));
58
- expect(output).toContain('Proposed split (2 atom(s))');
59
- expect(output).toContain('Atom A');
60
- expect(output).toContain('first idea');
61
- expect(output).toContain('suggested collection: decisions');
62
- expect(output).toContain('Proposed links');
63
- expect(output).toContain('original --relates_to--> [0]');
64
- expect(output).toContain('[0] --relates_to--> [1]');
65
- });
66
- it('review round 1 (Codex P2 fix): renders dispositionReason — was write-only before this fix', () => {
67
- const output = formatShapeAdvisoryShow(item({
68
- disposition: 'dismissed',
69
- dispositionBy: { kind: 'agent' },
70
- dispositionReason: 'not actually compound',
71
- }));
72
- expect(output).toContain('Dispositioned by: agent');
73
- expect(output).toContain('Disposition reason: not actually compound');
74
- });
75
- it('renders a disposition receipt naming the recorded verdict and actor', () => {
76
- expect(formatShapeDispositionReceipt({ rowId: 'row-1', disposition: 'agreed', dispositionBy: { kind: 'agent' } }))
77
- .toBe('Advisory row-1 dispositioned: agreed (by agent)');
78
- });
79
- });
80
- //# sourceMappingURL=shape.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"shape.test.js","sourceRoot":"","sources":["../../src/formatters/shape.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,QAAQ,CAAC;AAC9C,OAAO,EACL,yBAAyB,EACzB,uBAAuB,EACvB,6BAA6B,GAE9B,MAAM,YAAY,CAAC;AAEpB,MAAM,GAAG,GAAG,iBAAiB,CAAC;AAE9B,SAAS,IAAI,CAAC,YAAwC,EAAE;IACtD,OAAO;QACL,EAAE,EAAE,OAAO;QACX,OAAO,EAAE,UAAU;QACnB,WAAW,EAAE,SAAS;QACtB,cAAc,EAAE,OAAO;QACvB,cAAc,EAAE,OAAO;QACvB,MAAM,EAAE,KAAK;QACb,EAAE,EAAE,GAAG,GAAG,CAAC,GAAG,EAAE,GAAG,IAAI;QACvB,GAAG,SAAS;KACb,CAAC;AACJ,CAAC;AAED,QAAQ,CAAC,kBAAkB,EAAE,GAAG,EAAE;IAChC,EAAE,CAAC,+BAA+B,EAAE,GAAG,EAAE;QACvC,MAAM,CAAC,yBAAyB,CAAC,EAAE,EAAE,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,4BAA4B,CAAC,CAAC;IAChF,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,kFAAkF,EAAE,GAAG,EAAE;QAC1F,MAAM,MAAM,GAAG,yBAAyB,CAAC,CAAC,IAAI,EAAE,CAAC,EAAE,GAAG,CAAC,CAAC;QACxD,MAAM,CAAC,MAAM,CAAC,CAAC,SAAS,CAAC,sBAA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