@gitroll/tacitt-cli 0.6.11 → 0.6.13

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 (57) hide show
  1. package/README.md +4 -0
  2. package/bin/INDEX.md +6 -4
  3. package/bin/tacitt.cjs +1 -0
  4. package/dist/{agent-setup-DdfF3zch.mjs → agent-setup-Doy_AnPY.mjs} +2 -2
  5. package/dist/agent-setup-worker.mjs +5 -5
  6. package/dist/cli.mjs +32 -32
  7. package/dist/codex-title-worker.mjs +2 -2
  8. package/dist/configured-preview-worker.mjs +5 -5
  9. package/dist/configured-session-worker.mjs +23 -25
  10. package/dist/{frame-Bq2zRh-i.mjs → frame-BPbypzmt.mjs} +1 -1
  11. package/dist/{heap-CV8Eca8V.mjs → heap-DCS_WXIA.mjs} +264 -23
  12. package/dist/inspection-worker.mjs +4 -4
  13. package/dist/{job-BKsifhyv.mjs → job--zxwgaPy.mjs} +155 -41
  14. package/dist/{locate-Cx52Zqxv.mjs → locate-PLEyLYW-.mjs} +292 -236
  15. package/dist/{model-C1UXkHh9.mjs → model-CyXvsWLz.mjs} +1 -1
  16. package/dist/operation-executor.mjs +3 -3
  17. package/dist/preview-worker.mjs +1 -1
  18. package/dist/privacy-validator.mjs +28 -8
  19. package/dist/{query-AMZerUh8.mjs → query-BC7MIaWc.mjs} +1914 -759
  20. package/dist/{run-CaPktPhH.mjs → run-Dod7Vykp.mjs} +6 -6
  21. package/dist/session-process.mjs +20 -0
  22. package/dist/{src-DlVbGB32.mjs → src-CP-K2PBv.mjs} +2100 -1649
  23. package/dist/{src-D1iONla3.mjs → src-CttNuxOn.mjs} +925 -630
  24. package/dist/{src-wZx_v0Ih.mjs → src-dL6y2mcu.mjs} +180 -30
  25. package/dist/store-database-worker.mjs +1 -1
  26. package/dist/web/assets/index-BgDdPL1c.js +172 -0
  27. package/dist/web/index.html +2 -1
  28. package/package.json +2 -1
  29. package/skills/INDEX.md +6 -4
  30. package/skills/tacitt/INDEX.md +7 -6
  31. package/skills/tacitt/SKILL.md +7 -7
  32. package/skills/tacitt/references/INDEX.md +14 -11
  33. package/skills/tacitt/references/b-method.md +6 -4
  34. package/skills/tacitt/references/bootstrap.md +18 -4
  35. package/skills/tacitt/references/classification.md +1 -1
  36. package/skills/tacitt/references/commands.md +34 -10
  37. package/skills/tacitt/references/journey.md +7 -7
  38. package/skills/tacitt/references/parallel-review.md +31 -12
  39. package/skills/tacitt/references/remote-workers.md +6 -2
  40. package/skills/tacitt/references/send.md +7 -3
  41. package/skills/tacitt/scripts/INDEX.md +40 -37
  42. package/skills/tacitt/scripts/answer.mjs +31 -2
  43. package/skills/tacitt/scripts/describe.mjs +3 -2
  44. package/skills/tacitt/scripts/journey-card-consolidation.mjs +1 -1
  45. package/skills/tacitt/scripts/journey-classification-tasks.mjs +28 -8
  46. package/skills/tacitt/scripts/journey-classification.mjs +1 -0
  47. package/skills/tacitt/scripts/journey-panel-host.d.mts +2 -0
  48. package/skills/tacitt/scripts/journey-panel-host.mjs +25 -2
  49. package/skills/tacitt/scripts/journey-scan-timing.d.mts +4 -0
  50. package/skills/tacitt/scripts/journey-scan-timing.mjs +15 -2
  51. package/skills/tacitt/scripts/journey-state.mjs +11 -0
  52. package/skills/tacitt/scripts/journey-tasks.mjs +12 -5
  53. package/skills/tacitt/scripts/journey.mjs +11 -3
  54. package/skills/tacitt/scripts/privacy-validator.mjs +112 -40
  55. package/skills/tacitt/scripts/review.d.mts +1 -0
  56. package/skills/tacitt/scripts/review.mjs +680 -119
  57. package/dist/web/assets/index-CYl7eDUu.js +0 -172
@@ -1,4 +1,4 @@
1
- import { n as assertPreviewHeap, o as previewInputSchema, t as runPreview } from "./run-CaPktPhH.mjs";
1
+ import { n as assertPreviewHeap, o as previewInputSchema, t as runPreview } from "./run-Dod7Vykp.mjs";
2
2
  import { parentPort, workerData } from "node:worker_threads";
3
3
  //#region packages/harnesses/src/preview/worker/index.ts
4
4
  function notify(message) {
@@ -1,32 +1,52 @@
1
- import { Mt as privacyTermKey, Ot as decisionCardInputSchema, jt as privacyResolveSchema, r as reviewReadPages, t as locateTerms } from "./locate-Cx52Zqxv.mjs";
1
+ import { At as decisionCardInputSchema, Nt as privacyResolveSchema, Pt as privacyTermKey, a as reviewReadPages, t as locateTerms } from "./locate-PLEyLYW-.mjs";
2
2
  import { z } from "zod";
3
3
  //#region apps/cli/src/skill-install/privacy-validator.ts
4
4
  const sourceReferenceSchema = z.object({
5
5
  chunkId: z.uuid(),
6
- start: z.number().int().nonnegative(),
7
- end: z.number().int().positive()
6
+ start: z.number().int(),
7
+ end: z.number().int()
8
8
  }).strict();
9
9
  /** Resolve sensitive spans locally against the projected, assigned core text. */
10
10
  function resolvePrivacySources(raw, batches) {
11
11
  if (!Array.isArray(raw)) throw new Error("INVALID_FINDING");
12
12
  if (!raw.some((term) => typeof term === "object" && term !== null && "source" in term)) return raw;
13
13
  const chunks = new Map(batches.flatMap(({ chunks }) => chunks.map((chunk) => [chunk.id, chunk])));
14
- return raw.map((term, index) => {
14
+ const diagnostics = [];
15
+ let invalidCount = 0;
16
+ const resolved = raw.map((term, index) => {
15
17
  if (typeof term !== "object" || term === null || !("source" in term)) return term;
18
+ const invalid = (reason) => {
19
+ invalidCount++;
20
+ if (diagnostics.length < 32) diagnostics.push(`draft.terms[${index}].source: ${reason}`);
21
+ };
16
22
  const reference = sourceReferenceSchema.safeParse(term.source);
17
- const invalid = () => new Error("INVALID_REVIEW_SPAN", { cause: [`draft.terms[${index}].source`] });
18
- if (!reference.success || "value" in term) throw invalid();
23
+ if (!reference.success || "value" in term) return invalid("use only a chunkId and integer start/end offsets for the source");
19
24
  const { chunkId, start, end } = reference.data;
20
25
  const chunk = chunks.get(chunkId);
21
- if (!chunk?.core || end <= start || end > chunk.text.length || end - start > 8e3 || chunk.displayMasks?.some((range) => range.start < end && start < range.end)) throw invalid();
26
+ if (!chunk?.core) return invalid("select an assigned core chunk");
27
+ if (start < 0 || end <= start || end > chunk.text.length) return invalid("check chunk-relative UTF-16 bounds");
28
+ if (end - start > 8e3) return invalid("span exceeds the length limit");
29
+ if (chunk.displayMasks?.some((range) => range.start < end && start < range.end)) return invalid("span intersects masked text");
22
30
  const value = chunk.text.slice(start, end);
23
- if (!value.isWellFormed() || value.includes("█") || !value.trim() || Array.from(value).length > 4e3) throw invalid();
31
+ if (!value.isWellFormed()) {
32
+ if ((chunk.text.codePointAt(start - 1) ?? 0) > 65535 || (chunk.text.codePointAt(end - 1) ?? 0) > 65535) return invalid("offset splits a UTF-16 surrogate pair");
33
+ return invalid("span contains invalid UTF-16");
34
+ }
35
+ if (value.includes("█")) return invalid("span intersects masked text");
36
+ if (!value.trim()) return invalid("span contains only whitespace");
37
+ if (Array.from(value).length > 4e3) return invalid("span exceeds the length limit");
24
38
  const { source: _source, ...rest } = term;
25
39
  return {
26
40
  ...rest,
27
41
  value
28
42
  };
29
43
  });
44
+ if (invalidCount) {
45
+ const remaining = invalidCount - diagnostics.length;
46
+ if (remaining) diagnostics.push(`${remaining} additional invalid source references`);
47
+ throw new Error("INVALID_REVIEW_SPAN", { cause: diagnostics });
48
+ }
49
+ return resolved;
30
50
  }
31
51
  const suppliedTerms = z.array(z.object({
32
52
  key: z.string(),