@contractspec/lib.product-intent-utils 1.57.0 → 1.59.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 (42) hide show
  1. package/dist/browser/index.js +1592 -0
  2. package/dist/impact-engine.d.ts +10 -14
  3. package/dist/impact-engine.d.ts.map +1 -1
  4. package/dist/index.d.ts +9 -9
  5. package/dist/index.d.ts.map +1 -0
  6. package/dist/index.js +1593 -10
  7. package/dist/node/index.js +1592 -0
  8. package/dist/project-management-sync.d.ts +17 -21
  9. package/dist/project-management-sync.d.ts.map +1 -1
  10. package/dist/prompts.d.ts +41 -45
  11. package/dist/prompts.d.ts.map +1 -1
  12. package/dist/ticket-pipeline-runner.d.ts +22 -25
  13. package/dist/ticket-pipeline-runner.d.ts.map +1 -1
  14. package/dist/ticket-pipeline.d.ts +29 -32
  15. package/dist/ticket-pipeline.d.ts.map +1 -1
  16. package/dist/ticket-prompts.d.ts +13 -16
  17. package/dist/ticket-prompts.d.ts.map +1 -1
  18. package/dist/ticket-validators.d.ts +4 -8
  19. package/dist/ticket-validators.d.ts.map +1 -1
  20. package/dist/validators.d.ts +24 -28
  21. package/dist/validators.d.ts.map +1 -1
  22. package/dist/validators.test.d.ts +2 -0
  23. package/dist/validators.test.d.ts.map +1 -0
  24. package/package.json +20 -15
  25. package/dist/impact-engine.js +0 -168
  26. package/dist/impact-engine.js.map +0 -1
  27. package/dist/project-management-sync.js +0 -80
  28. package/dist/project-management-sync.js.map +0 -1
  29. package/dist/prompts.js +0 -372
  30. package/dist/prompts.js.map +0 -1
  31. package/dist/schema/dist/SchemaModelType.d.ts +0 -50
  32. package/dist/schema/dist/SchemaModelType.d.ts.map +0 -1
  33. package/dist/ticket-pipeline-runner.js +0 -97
  34. package/dist/ticket-pipeline-runner.js.map +0 -1
  35. package/dist/ticket-pipeline.js +0 -425
  36. package/dist/ticket-pipeline.js.map +0 -1
  37. package/dist/ticket-prompts.js +0 -131
  38. package/dist/ticket-prompts.js.map +0 -1
  39. package/dist/ticket-validators.js +0 -106
  40. package/dist/ticket-validators.js.map +0 -1
  41. package/dist/validators.js +0 -277
  42. package/dist/validators.js.map +0 -1
@@ -1,25 +1,21 @@
1
- import { ContractPatchIntent, ImpactReport, Ticket } from "@contractspec/lib.contracts/product-intent/types";
2
- import { ProjectManagementWorkItemInput, ProjectManagementWorkItemPriority } from "@contractspec/lib.contracts/integrations/providers/project-management";
3
-
4
- //#region src/project-management-sync.d.ts
5
- interface ProjectManagementSyncOptions {
6
- includeSummary?: boolean;
7
- summaryTitle?: string;
8
- defaultPriority?: ProjectManagementWorkItemPriority;
9
- baseTags?: string[];
1
+ import type { ContractPatchIntent, ImpactReport, Ticket } from '@contractspec/lib.contracts/product-intent/types';
2
+ import type { ProjectManagementWorkItemInput, ProjectManagementWorkItemPriority } from '@contractspec/lib.contracts/integrations/providers/project-management';
3
+ export interface ProjectManagementSyncOptions {
4
+ includeSummary?: boolean;
5
+ summaryTitle?: string;
6
+ defaultPriority?: ProjectManagementWorkItemPriority;
7
+ baseTags?: string[];
10
8
  }
11
- interface ProjectManagementSyncPayload {
12
- summary?: ProjectManagementWorkItemInput;
13
- items: ProjectManagementWorkItemInput[];
9
+ export interface ProjectManagementSyncPayload {
10
+ summary?: ProjectManagementWorkItemInput;
11
+ items: ProjectManagementWorkItemInput[];
14
12
  }
15
- declare function buildProjectManagementSyncPayload(params: {
16
- question: string;
17
- tickets: Ticket[];
18
- patchIntent?: ContractPatchIntent;
19
- impact?: ImpactReport;
20
- options?: ProjectManagementSyncOptions;
13
+ export declare function buildProjectManagementSyncPayload(params: {
14
+ question: string;
15
+ tickets: Ticket[];
16
+ patchIntent?: ContractPatchIntent;
17
+ impact?: ImpactReport;
18
+ options?: ProjectManagementSyncOptions;
21
19
  }): ProjectManagementSyncPayload;
22
- declare function buildWorkItemsFromTickets(tickets: Ticket[], options?: ProjectManagementSyncOptions): ProjectManagementWorkItemInput[];
23
- //#endregion
24
- export { ProjectManagementSyncOptions, ProjectManagementSyncPayload, buildProjectManagementSyncPayload, buildWorkItemsFromTickets };
20
+ export declare function buildWorkItemsFromTickets(tickets: Ticket[], options?: ProjectManagementSyncOptions): ProjectManagementWorkItemInput[];
25
21
  //# sourceMappingURL=project-management-sync.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"project-management-sync.d.ts","names":[],"sources":["../src/project-management-sync.ts"],"mappings":";;;;UAWiB,4BAAA;EACf,cAAA;EACA,YAAA;EACA,eAAA,GAAkB,iCAAA;EAClB,QAAA;AAAA;AAAA,UAGe,4BAAA;EACf,OAAA,GAAU,8BAAA;EACV,KAAA,EAAO,8BAAA;AAAA;AAAA,iBAGO,iCAAA,CAAkC,MAAA;EAChD,QAAA;EACA,OAAA,EAAS,MAAA;EACT,WAAA,GAAc,mBAAA;EACd,MAAA,GAAS,YAAA;EACT,OAAA,GAAU,4BAAA;AAAA,IACR,4BAAA;AAAA,iBAiBY,yBAAA,CACd,OAAA,EAAS,MAAA,IACT,OAAA,GAAS,4BAAA,GACR,8BAAA"}
1
+ {"version":3,"file":"project-management-sync.d.ts","sourceRoot":"","sources":["../src/project-management-sync.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,mBAAmB,EACnB,YAAY,EACZ,MAAM,EAEP,MAAM,kDAAkD,CAAC;AAC1D,OAAO,KAAK,EACV,8BAA8B,EAC9B,iCAAiC,EAClC,MAAM,uEAAuE,CAAC;AAE/E,MAAM,WAAW,4BAA4B;IAC3C,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,eAAe,CAAC,EAAE,iCAAiC,CAAC;IACpD,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;CACrB;AAED,MAAM,WAAW,4BAA4B;IAC3C,OAAO,CAAC,EAAE,8BAA8B,CAAC;IACzC,KAAK,EAAE,8BAA8B,EAAE,CAAC;CACzC;AAED,wBAAgB,iCAAiC,CAAC,MAAM,EAAE;IACxD,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,WAAW,CAAC,EAAE,mBAAmB,CAAC;IAClC,MAAM,CAAC,EAAE,YAAY,CAAC;IACtB,OAAO,CAAC,EAAE,4BAA4B,CAAC;CACxC,GAAG,4BAA4B,CAe/B;AAED,wBAAgB,yBAAyB,CACvC,OAAO,EAAE,MAAM,EAAE,EACjB,OAAO,GAAE,4BAAiC,GACzC,8BAA8B,EAAE,CASlC"}
package/dist/prompts.d.ts CHANGED
@@ -1,6 +1,4 @@
1
- import { EvidenceChunk } from "@contractspec/lib.contracts/product-intent/types";
2
-
3
- //#region src/prompts.d.ts
1
+ import type { EvidenceChunk } from '@contractspec/lib.contracts/product-intent/types';
4
2
  /**
5
3
  * Prompt construction helpers for the product intent workflow.
6
4
  */
@@ -8,97 +6,95 @@ import { EvidenceChunk } from "@contractspec/lib.contracts/product-intent/types"
8
6
  * Format evidence chunks as JSON suitable for embedding in prompts.
9
7
  * Long texts are truncated to a configurable maximum number of characters.
10
8
  */
11
- declare function formatEvidenceForModel(chunks: EvidenceChunk[], maxChars?: number): string;
9
+ export declare function formatEvidenceForModel(chunks: EvidenceChunk[], maxChars?: number): string;
12
10
  /**
13
11
  * Rules that instruct the model to output only JSON.
14
12
  */
15
- declare const JSON_ONLY_RULES = "\nYou MUST output valid JSON ONLY.\n- Do not wrap in markdown fences.\n- Do not include any commentary.\n- Do not include trailing commas.\n- Use double quotes for all keys and string values.\n";
13
+ export declare const JSON_ONLY_RULES = "\nYou MUST output valid JSON ONLY.\n- Do not wrap in markdown fences.\n- Do not include any commentary.\n- Do not include trailing commas.\n- Use double quotes for all keys and string values.\n";
16
14
  /**
17
15
  * Citation rules used in prompts that require citations.
18
16
  */
19
- declare const CITATION_RULES = "\nCITATION RULES (strict):\n- You may ONLY cite from the provided evidenceChunks.\n- Each citation must include:\n - \"chunkId\": exactly one of the provided chunkId values\n - \"quote\": an exact substring copied from that chunk's text\n- Do NOT invent quotes.\n- Keep quotes short (<= 240 chars).\n- If you cannot support a claim with evidence, do not make the claim.\n";
17
+ export declare const CITATION_RULES = "\nCITATION RULES (strict):\n- You may ONLY cite from the provided evidenceChunks.\n- Each citation must include:\n - \"chunkId\": exactly one of the provided chunkId values\n - \"quote\": an exact substring copied from that chunk's text\n- Do NOT invent quotes.\n- Keep quotes short (<= 240 chars).\n- If you cannot support a claim with evidence, do not make the claim.\n";
20
18
  /**
21
19
  * Prompt for extracting atomic, evidence-grounded insights.
22
20
  */
23
- declare function promptExtractInsights(params: {
24
- question: string;
25
- evidenceJSON: string;
21
+ export declare function promptExtractInsights(params: {
22
+ question: string;
23
+ evidenceJSON: string;
26
24
  }): string;
27
25
  /**
28
26
  * Prompt for synthesizing an opportunity brief from extracted insights.
29
27
  */
30
- declare function promptSynthesizeBrief(params: {
31
- question: string;
32
- insightsJSON: string;
33
- allowedChunkIds: string[];
28
+ export declare function promptSynthesizeBrief(params: {
29
+ question: string;
30
+ insightsJSON: string;
31
+ allowedChunkIds: string[];
34
32
  }): string;
35
33
  /**
36
34
  * Prompt for a skeptic pass. The model should audit a brief and return
37
35
  * unsupported claims or citation misuse.
38
36
  */
39
- declare function promptSkepticCheck(params: {
40
- briefJSON: string;
41
- evidenceJSON: string;
37
+ export declare function promptSkepticCheck(params: {
38
+ briefJSON: string;
39
+ evidenceJSON: string;
42
40
  }): string;
43
41
  /**
44
42
  * Prompt to generate a ContractPatchIntent from an OpportunityBrief.
45
43
  */
46
- declare function promptGeneratePatchIntent(params: {
47
- briefJSON: string;
44
+ export declare function promptGeneratePatchIntent(params: {
45
+ briefJSON: string;
48
46
  }): string;
49
47
  /**
50
48
  * Prompt to generate a generic spec overlay from a patch intent and
51
49
  * base spec snippet.
52
50
  */
53
- declare function promptGenerateGenericSpecOverlay(params: {
54
- baseSpecSnippet: string;
55
- patchIntentJSON: string;
51
+ export declare function promptGenerateGenericSpecOverlay(params: {
52
+ baseSpecSnippet: string;
53
+ patchIntentJSON: string;
56
54
  }): string;
57
55
  /**
58
56
  * Prompt to generate an impact report given a patch intent, overlay and
59
57
  * optional compiler output.
60
58
  */
61
- declare function promptGenerateImpactReport(params: {
62
- patchIntentJSON: string;
63
- overlayJSON: string;
64
- compilerOutputText?: string;
59
+ export declare function promptGenerateImpactReport(params: {
60
+ patchIntentJSON: string;
61
+ overlayJSON: string;
62
+ compilerOutputText?: string;
65
63
  }): string;
66
64
  /**
67
65
  * Prompt to generate an agent-ready task pack.
68
66
  */
69
- declare function promptGenerateTaskPack(params: {
70
- briefJSON: string;
71
- patchIntentJSON: string;
72
- impactJSON: string;
73
- repoContext?: string;
67
+ export declare function promptGenerateTaskPack(params: {
68
+ briefJSON: string;
69
+ patchIntentJSON: string;
70
+ impactJSON: string;
71
+ repoContext?: string;
74
72
  }): string;
75
73
  /**
76
74
  * Prompt for generating a wireframe image using a generative API.
77
75
  */
78
- declare function promptWireframeImage(params: {
79
- screenName: string;
80
- device: 'mobile' | 'desktop';
81
- currentScreenSummary: string;
82
- proposedChanges: string[];
76
+ export declare function promptWireframeImage(params: {
77
+ screenName: string;
78
+ device: 'mobile' | 'desktop';
79
+ currentScreenSummary: string;
80
+ proposedChanges: string[];
83
81
  }): string;
84
82
  /**
85
83
  * Prompt for generating a fallback UI layout when image generation is
86
84
  * unavailable.
87
85
  */
88
- declare function promptWireframeLayoutJSON(params: {
89
- screenName: string;
90
- device: 'mobile' | 'desktop';
91
- proposedChanges: string[];
86
+ export declare function promptWireframeLayoutJSON(params: {
87
+ screenName: string;
88
+ device: 'mobile' | 'desktop';
89
+ proposedChanges: string[];
92
90
  }): string;
93
91
  /**
94
92
  * Prompt to generate synthetic interview transcripts for testing or
95
93
  * demonstration.
96
94
  */
97
- declare function promptGenerateSyntheticInterviews(params: {
98
- productContext: string;
99
- personas: string[];
100
- count: number;
95
+ export declare function promptGenerateSyntheticInterviews(params: {
96
+ productContext: string;
97
+ personas: string[];
98
+ count: number;
101
99
  }): string;
102
- //#endregion
103
- export { CITATION_RULES, JSON_ONLY_RULES, formatEvidenceForModel, promptExtractInsights, promptGenerateGenericSpecOverlay, promptGenerateImpactReport, promptGeneratePatchIntent, promptGenerateSyntheticInterviews, promptGenerateTaskPack, promptSkepticCheck, promptSynthesizeBrief, promptWireframeImage, promptWireframeLayoutJSON };
104
100
  //# sourceMappingURL=prompts.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"prompts.d.ts","names":[],"sources":["../src/prompts.ts"],"mappings":";;;;;AAUA;;;;;iBAAgB,sBAAA,CACd,MAAA,EAAQ,aAAA,IACR,QAAA;;;;cAgBW,eAAA;;;;cAWA,cAAA;AAAb;;;AAAA,iBAcgB,qBAAA,CAAsB,MAAA;EACpC,QAAA;EACA,YAAA;AAAA;;;;iBAuCc,qBAAA,CAAsB,MAAA;EACpC,QAAA;EACA,YAAA;EACA,eAAA;AAAA;;;;;iBA4Cc,kBAAA,CAAmB,MAAA;EACjC,SAAA;EACA,YAAA;AAAA;;AAFF;;iBAkCgB,yBAAA,CAA0B,MAAA;EACxC,SAAA;AAAA;;;;;iBA6Bc,gCAAA,CAAiC,MAAA;EAC/C,eAAA;EACA,eAAA;AAAA;;AAFF;;;iBAkCgB,0BAAA,CAA2B,MAAA;EACzC,eAAA;EACA,WAAA;EACA,kBAAA;AAAA;;AAHF;;iBA+CgB,sBAAA,CAAuB,MAAA;EACrC,SAAA;EACA,eAAA;EACA,UAAA;EACA,WAAA;AAAA;;;AAJF;iBAmDgB,oBAAA,CAAqB,MAAA;EACnC,UAAA;EACA,MAAA;EACA,oBAAA;EACA,eAAA;AAAA;;;;;iBAyBc,yBAAA,CAA0B,MAAA;EACxC,UAAA;EACA,MAAA;EACA,eAAA;AAAA;;;;;iBA+Bc,iCAAA,CAAkC,MAAA;EAChD,cAAA;EACA,QAAA;EACA,KAAA;AAAA"}
1
+ {"version":3,"file":"prompts.d.ts","sourceRoot":"","sources":["../src/prompts.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa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AAC;IACxB,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,GAAG,MAAM,CAyCT;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,MAAM,EAAE;IAC3C,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,QAAQ,GAAG,SAAS,CAAC;IAC7B,oBAAoB,EAAE,MAAM,CAAC;IAC7B,eAAe,EAAE,MAAM,EAAE,CAAC;CAC3B,GAAG,MAAM,CAkBT;AAED;;;GAGG;AACH,wBAAgB,yBAAyB,CAAC,MAAM,EAAE;IAChD,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,QAAQ,GAAG,SAAS,CAAC;IAC7B,eAAe,EAAE,MAAM,EAAE,CAAC;CAC3B,GAAG,MAAM,CAwBT;AAED;;;GAGG;AACH,wBAAgB,iCAAiC,CAAC,MAAM,EAAE;IACxD,cAAc,EAAE,MAAM,CAAC;IACvB,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;CACf,GAAG,MAAM,CAwBT"}
@@ -1,30 +1,27 @@
1
- //#region src/ticket-pipeline-runner.d.ts
2
- interface TicketPipelineModelRunner {
3
- generateJson: (prompt: string) => Promise<string>;
1
+ export interface TicketPipelineModelRunner {
2
+ generateJson: (prompt: string) => Promise<string>;
4
3
  }
5
- type TicketPipelineStage = 'extractEvidence' | 'groupProblems' | 'generateTickets' | 'suggestPatch';
6
- interface TicketPipelineLogEntry {
7
- stage: TicketPipelineStage;
8
- phase: 'request' | 'response' | 'validation_error' | 'model_error' | 'repair';
9
- attempt: number;
10
- prompt: string;
11
- response?: string;
12
- error?: string;
13
- timestamp: string;
4
+ export type TicketPipelineStage = 'extractEvidence' | 'groupProblems' | 'generateTickets' | 'suggestPatch';
5
+ export interface TicketPipelineLogEntry {
6
+ stage: TicketPipelineStage;
7
+ phase: 'request' | 'response' | 'validation_error' | 'model_error' | 'repair';
8
+ attempt: number;
9
+ prompt: string;
10
+ response?: string;
11
+ error?: string;
12
+ timestamp: string;
14
13
  }
15
- interface TicketPipelineLogger {
16
- log: (entry: TicketPipelineLogEntry) => void | Promise<void>;
14
+ export interface TicketPipelineLogger {
15
+ log: (entry: TicketPipelineLogEntry) => void | Promise<void>;
17
16
  }
18
- interface TicketPipelineRunOptions<T> {
19
- stage: TicketPipelineStage;
20
- prompt: string;
21
- modelRunner: TicketPipelineModelRunner;
22
- validate: (raw: string) => T;
23
- logger?: TicketPipelineLogger;
24
- maxAttempts?: number;
25
- repair?: (raw: string, error: string) => string | null;
17
+ export interface TicketPipelineRunOptions<T> {
18
+ stage: TicketPipelineStage;
19
+ prompt: string;
20
+ modelRunner: TicketPipelineModelRunner;
21
+ validate: (raw: string) => T;
22
+ logger?: TicketPipelineLogger;
23
+ maxAttempts?: number;
24
+ repair?: (raw: string, error: string) => string | null;
26
25
  }
27
- declare function runWithValidation<T>(options: TicketPipelineRunOptions<T>): Promise<T>;
28
- //#endregion
29
- export { TicketPipelineLogEntry, TicketPipelineLogger, TicketPipelineModelRunner, TicketPipelineRunOptions, TicketPipelineStage, runWithValidation };
26
+ export declare function runWithValidation<T>(options: TicketPipelineRunOptions<T>): Promise<T>;
30
27
  //# sourceMappingURL=ticket-pipeline-runner.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ticket-pipeline-runner.d.ts","names":[],"sources":["../src/ticket-pipeline-runner.ts"],"mappings":";UAEiB,yBAAA;EACf,YAAA,GAAe,MAAA,aAAmB,OAAA;AAAA;AAAA,KAGxB,mBAAA;AAAA,UAMK,sBAAA;EACf,KAAA,EAAO,mBAAA;EACP,KAAA;EACA,OAAA;EACA,MAAA;EACA,QAAA;EACA,KAAA;EACA,SAAA;AAAA;AAAA,UAGe,oBAAA;EACf,GAAA,GAAM,KAAA,EAAO,sBAAA,YAAkC,OAAA;AAAA;AAAA,UAGhC,wBAAA;EACf,KAAA,EAAO,mBAAA;EACP,MAAA;EACA,WAAA,EAAa,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AAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,MAAM,GAAG,IAAI,CAAC;CACxD;AAwBD,wBAAsB,iBAAiB,CAAC,CAAC,EACvC,OAAO,EAAE,wBAAwB,CAAC,CAAC,CAAC,GACnC,OAAO,CAAC,CAAC,CAAC,CA2FZ"}
@@ -1,38 +1,35 @@
1
- import { TicketPipelineLogger, TicketPipelineModelRunner } from "./ticket-pipeline-runner.js";
2
- import { ContractPatchIntent, EvidenceChunk, EvidenceFinding, ProblemStatement, Ticket } from "@contractspec/lib.contracts/product-intent/types";
3
-
4
- //#region src/ticket-pipeline.d.ts
5
- interface RetrieveChunksOptions {
6
- chunkSize?: number;
7
- sourceId?: string;
8
- meta?: Record<string, unknown>;
1
+ import { type ContractPatchIntent, type EvidenceChunk, type EvidenceFinding, type ProblemStatement, type Ticket } from '@contractspec/lib.contracts/product-intent/types';
2
+ import { type TicketPipelineLogger, type TicketPipelineModelRunner } from './ticket-pipeline-runner';
3
+ export type { TicketPipelineLogger, TicketPipelineModelRunner };
4
+ export interface RetrieveChunksOptions {
5
+ chunkSize?: number;
6
+ sourceId?: string;
7
+ meta?: Record<string, unknown>;
9
8
  }
10
- interface ExtractEvidenceOptions {
11
- modelRunner?: TicketPipelineModelRunner;
12
- maxFindings?: number;
13
- logger?: TicketPipelineLogger;
14
- maxAttempts?: number;
9
+ export interface ExtractEvidenceOptions {
10
+ modelRunner?: TicketPipelineModelRunner;
11
+ maxFindings?: number;
12
+ logger?: TicketPipelineLogger;
13
+ maxAttempts?: number;
15
14
  }
16
- interface GroupProblemsOptions {
17
- modelRunner?: TicketPipelineModelRunner;
18
- logger?: TicketPipelineLogger;
19
- maxAttempts?: number;
15
+ export interface GroupProblemsOptions {
16
+ modelRunner?: TicketPipelineModelRunner;
17
+ logger?: TicketPipelineLogger;
18
+ maxAttempts?: number;
20
19
  }
21
- interface GenerateTicketsOptions {
22
- modelRunner?: TicketPipelineModelRunner;
23
- logger?: TicketPipelineLogger;
24
- maxAttempts?: number;
20
+ export interface GenerateTicketsOptions {
21
+ modelRunner?: TicketPipelineModelRunner;
22
+ logger?: TicketPipelineLogger;
23
+ maxAttempts?: number;
25
24
  }
26
- interface SuggestPatchOptions {
27
- modelRunner?: TicketPipelineModelRunner;
28
- logger?: TicketPipelineLogger;
29
- maxAttempts?: number;
25
+ export interface SuggestPatchOptions {
26
+ modelRunner?: TicketPipelineModelRunner;
27
+ logger?: TicketPipelineLogger;
28
+ maxAttempts?: number;
30
29
  }
31
- declare function retrieveChunks(transcript: string, question: string, options?: RetrieveChunksOptions): EvidenceChunk[];
32
- declare function extractEvidence(chunks: EvidenceChunk[], question: string, options?: ExtractEvidenceOptions): Promise<EvidenceFinding[]>;
33
- declare function groupProblems(findings: EvidenceFinding[], question: string, options?: GroupProblemsOptions): Promise<ProblemStatement[]>;
34
- declare function generateTickets(problems: ProblemStatement[], findings: EvidenceFinding[], question: string, options?: GenerateTicketsOptions): Promise<Ticket[]>;
35
- declare function suggestPatch(ticket: Ticket, options?: SuggestPatchOptions): Promise<ContractPatchIntent>;
36
- //#endregion
37
- export { ExtractEvidenceOptions, GenerateTicketsOptions, GroupProblemsOptions, RetrieveChunksOptions, SuggestPatchOptions, extractEvidence, generateTickets, groupProblems, retrieveChunks, suggestPatch };
30
+ export declare function retrieveChunks(transcript: string, question: string, options?: RetrieveChunksOptions): EvidenceChunk[];
31
+ export declare function extractEvidence(chunks: EvidenceChunk[], question: string, options?: ExtractEvidenceOptions): Promise<EvidenceFinding[]>;
32
+ export declare function groupProblems(findings: EvidenceFinding[], question: string, options?: GroupProblemsOptions): Promise<ProblemStatement[]>;
33
+ export declare function generateTickets(problems: ProblemStatement[], findings: EvidenceFinding[], question: string, options?: GenerateTicketsOptions): Promise<Ticket[]>;
34
+ export declare function suggestPatch(ticket: Ticket, options?: SuggestPatchOptions): Promise<ContractPatchIntent>;
38
35
  //# sourceMappingURL=ticket-pipeline.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ticket-pipeline.d.ts","names":[],"sources":["../src/ticket-pipeline.ts"],"mappings":";;;;UAuCiB,qBAAA;EACf,SAAA;EACA,QAAA;EACA,IAAA,GAAO,MAAA;AAAA;AAAA,UAGQ,sBAAA;EACf,WAAA,GAAc,yBAAA;EACd,WAAA;EACA,MAAA,GAAS,oBAAA;EACT,WAAA;AAAA;AAAA,UAGe,oBAAA;EACf,WAAA,GAAc,yBAAA;EACd,MAAA,GAAS,oBAAA;EACT,WAAA;AAAA;AAAA,UAGe,sBAAA;EACf,WAAA,GAAc,yBAAA;EACd,MAAA,GAAS,oBAAA;EACT,WAAA;AAAA;AAAA,UAGe,mBAAA;EACf,WAAA,GAAc,yBAAA;EACd,MAAA,GAAS,oBAAA;EACT,WAAA;AAAA;AAAA,iBAgTc,cAAA,CACd,UAAA,UACA,QAAA,UACA,OAAA,GAAS,qBAAA,GACR,aAAA;AAAA,iBAmBmB,eAAA,CACpB,MAAA,EAAQ,aAAA,IACR,QAAA,UACA,OAAA,GAAS,sBAAA,GACR,OAAA,CAAQ,eAAA;AAAA,iBAiCW,aAAA,CACpB,QAAA,EAAU,eAAA,IACV,QAAA,UACA,OAAA,GAAS,oBAAA,GACR,OAAA,CAAQ,gBAAA;AAAA,iBA+CW,eAAA,CACpB,QAAA,EAAU,gBAAA,IACV,QAAA,EAAU,eAAA,IACV,QAAA,UACA,OAAA,GAAS,sBAAA,GACR,OAAA,CAAQ,MAAA;AAAA,iBA0CW,YAAA,CACpB,MAAA,EAAQ,MAAA,EACR,OAAA,GAAS,mBAAA,GACR,OAAA,CAAQ,mBAAA"}
1
+ {"version":3,"file":"ticket-pipeline.d.ts","sourceRoot":"","sources":["../src/ticket-pipeline.ts"],"names":[],"mappings":"AAAA,OAAO,EAKL,KAAK,mBAAmB,EACxB,KAAK,aAAa,EAClB,KAAK,eAAe,EAGpB,KAAK,gBAAgB,EACrB,KAAK,MAAM,EAEZ,MAAM,kDAAkD,CAAC;AAkB1D,OAAO,EAEL,KAA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QAAQ,EAAE,MAAM,EAChB,OAAO,GAAE,oBAAyB,GACjC,OAAO,CAAC,gBAAgB,EAAE,CAAC,CA6C7B;AAED,wBAAsB,eAAe,CACnC,QAAQ,EAAE,gBAAgB,EAAE,EAC5B,QAAQ,EAAE,eAAe,EAAE,EAC3B,QAAQ,EAAE,MAAM,EAChB,OAAO,GAAE,sBAA2B,GACnC,OAAO,CAAC,MAAM,EAAE,CAAC,CAwCnB;AAED,wBAAsB,YAAY,CAChC,MAAM,EAAE,MAAM,EACd,OAAO,GAAE,mBAAwB,GAChC,OAAO,CAAC,mBAAmB,CAAC,CA6B9B"}
@@ -1,21 +1,18 @@
1
- //#region src/ticket-prompts.d.ts
2
- declare function promptExtractEvidenceFindings(params: {
3
- question: string;
4
- evidenceJSON: string;
1
+ export declare function promptExtractEvidenceFindings(params: {
2
+ question: string;
3
+ evidenceJSON: string;
5
4
  }): string;
6
- declare function promptGroupProblems(params: {
7
- question: string;
8
- findingsJSON: string;
9
- findingIds: string[];
5
+ export declare function promptGroupProblems(params: {
6
+ question: string;
7
+ findingsJSON: string;
8
+ findingIds: string[];
10
9
  }): string;
11
- declare function promptGenerateTickets(params: {
12
- question: string;
13
- problemsJSON: string;
14
- findingsJSON: string;
10
+ export declare function promptGenerateTickets(params: {
11
+ question: string;
12
+ problemsJSON: string;
13
+ findingsJSON: string;
15
14
  }): string;
16
- declare function promptSuggestPatchIntent(params: {
17
- ticketJSON: string;
15
+ export declare function promptSuggestPatchIntent(params: {
16
+ ticketJSON: string;
18
17
  }): string;
19
- //#endregion
20
- export { promptExtractEvidenceFindings, promptGenerateTickets, promptGroupProblems, promptSuggestPatchIntent };
21
18
  //# sourceMappingURL=ticket-prompts.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ticket-prompts.d.ts","names":[],"sources":["../src/ticket-prompts.ts"],"mappings":";iBAEgB,6BAAA,CAA8B,MAAA;EAC5C,QAAA;EACA,YAAA;AAAA;AAAA,iBAkCc,mBAAA,CAAoB,MAAA;EAClC,QAAA;EACA,YAAA;EACA,UAAA;AAAA;AAAA,iBAoCc,qBAAA,CAAsB,MAAA;EACpC,QAAA;EACA,YAAA;EACA,YAAA;AAAA;AAAA,iBAoCc,wBAAA,CAAyB,MAAA;EACvC,UAAA;AAAA"}
1
+ {"version":3,"file":"ticket-prompts.d.ts","sourceRoot":"","sources":["../src/ticket-prompts.ts"],"names":[],"mappings":"AAEA,wBAAgB,6BAA6B,CAAC,MAAM,EAAE;IACpD,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,CAAC;CACtB,GAAG,MAAM,CA+BT;AAED,wBAAgB,mBAAmB,CAAC,MAAM,EAAE;IAC1C,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,EAAE,CAAC;CACtB,GAAG,MAAM,CAiCT;AAED,wBAAgB,qBAAqB,CAAC,MAAM,EAAE;IAC5C,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,CAAC;IACrB,YAAY,EAAE,MAAM,CAAC;CACtB,GAAG,MAAM,CAiCT;AAED,wBAAgB,wBAAwB,CAAC,MAAM,EAAE;IAC/C,UAAU,EAAE,MAAM,CAAC;CACpB,GAAG,MAAM,CAuBT"}
@@ -1,9 +1,5 @@
1
- import { EvidenceChunk, EvidenceFinding, EvidenceFindingExtraction, ProblemGrouping, TicketCollection } from "@contractspec/lib.contracts/product-intent/types";
2
-
3
- //#region src/ticket-validators.d.ts
4
- declare function validateEvidenceFindingExtraction(raw: string, chunks: EvidenceChunk[]): EvidenceFindingExtraction;
5
- declare function validateProblemGrouping(raw: string, findings: EvidenceFinding[]): ProblemGrouping;
6
- declare function validateTicketCollection(raw: string, findings: EvidenceFinding[]): TicketCollection;
7
- //#endregion
8
- export { validateEvidenceFindingExtraction, validateProblemGrouping, validateTicketCollection };
1
+ import { type EvidenceChunk, type EvidenceFinding, type EvidenceFindingExtraction, type ProblemGrouping, type TicketCollection } from '@contractspec/lib.contracts/product-intent/types';
2
+ export declare function validateEvidenceFindingExtraction(raw: string, chunks: EvidenceChunk[]): EvidenceFindingExtraction;
3
+ export declare function validateProblemGrouping(raw: string, findings: EvidenceFinding[]): ProblemGrouping;
4
+ export declare function validateTicketCollection(raw: string, findings: EvidenceFinding[]): TicketCollection;
9
5
  //# sourceMappingURL=ticket-validators.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ticket-validators.d.ts","names":[],"sources":["../src/ticket-validators.ts"],"mappings":";;;iBAwEgB,iCAAA,CACd,GAAA,UACA,MAAA,EAAQ,aAAA,KACP,yBAAA;AAAA,iBA2Ba,uBAAA,CACd,GAAA,UACA,QAAA,EAAU,eAAA,KACT,eAAA;AAAA,iBAyBa,wBAAA,CACd,GAAA,UACA,QAAA,EAAU,eAAA,KACT,gBAAA"}
1
+ {"version":3,"file":"ticket-validators.d.ts","sourceRoot":"","sources":["../src/ticket-validators.ts"],"names":[],"mappings":"AACA,OAAO,EACL,KAAK,aAAa,EAClB,KAAK,eAAe,EACpB,KAAK,yBAAyB,EAE9B,KAAK,eAAe,EAEpB,KAAK,gBAAgB,EAEtB,MAAM,kDAAkD,CAAC;AA8D1D,wBAAgB,iCAAiC,CAC/C,GAAG,EAAE,MAAM,EACX,MAAM,EAAE,aAAa,EAAE,GACtB,yBAAyB,CAyB3B;AAED,wBAAgB,uBAAuB,CACrC,GAAG,EAAE,MAAM,EACX,QAAQ,EAAE,eAAe,EAAE,GAC1B,eAAe,CAuBjB;AAED,wBAAgB,wBAAwB,CACtC,GAAG,EAAE,MAAM,EACX,QAAQ,EAAE,eAAe,EAAE,GAC1B,gBAAgB,CAuClB"}
@@ -1,65 +1,61 @@
1
- import { SchemaModelType } from "./schema/dist/SchemaModelType.js";
2
- import { ContractPatchIntent, EvidenceChunk, ImpactReport, InsightExtraction, OpportunityBrief, TaskPack } from "@contractspec/lib.contracts/product-intent/types";
3
-
4
- //#region src/validators.d.ts
1
+ import type { SchemaModelType } from '@contractspec/lib.schema';
2
+ import { type ContractPatchIntent, type EvidenceChunk, type ImpactReport, type InsightExtraction, type OpportunityBrief, type TaskPack } from '@contractspec/lib.contracts/product-intent/types';
5
3
  /**
6
4
  * Parse a raw string as JSON and validate it against a SchemaModelType.
7
5
  */
8
- declare function parseStrictJSON<T>(schema: SchemaModelType, raw: string): T;
6
+ export declare function parseStrictJSON<T>(schema: SchemaModelType, raw: string): T;
9
7
  /**
10
8
  * Build an index of evidence chunks keyed by chunkId.
11
9
  */
12
- declare function buildChunkIndex(chunks: EvidenceChunk[]): Map<string, EvidenceChunk>;
10
+ export declare function buildChunkIndex(chunks: EvidenceChunk[]): Map<string, EvidenceChunk>;
13
11
  /**
14
12
  * Validate a single citation. Ensures the referenced chunk exists and
15
13
  * the quoted text is an exact substring of the chunk text.
16
14
  */
17
- declare function validateCitation(citation: unknown, chunkIndex: Map<string, EvidenceChunk>, opts?: {
18
- maxQuoteLen?: number;
19
- requireExactSubstring?: boolean;
15
+ export declare function validateCitation(citation: unknown, chunkIndex: Map<string, EvidenceChunk>, opts?: {
16
+ maxQuoteLen?: number;
17
+ requireExactSubstring?: boolean;
20
18
  }): {
21
- chunkId: string;
22
- quote: string;
19
+ chunkId: string;
20
+ quote: string;
23
21
  };
24
22
  /**
25
23
  * Validate citations embedded within a text block.
26
24
  */
27
- declare function validateCitationsInTextBlock(block: {
28
- text: string;
29
- citations: unknown[];
25
+ export declare function validateCitationsInTextBlock(block: {
26
+ text: string;
27
+ citations: unknown[];
30
28
  }, chunkIndex: Map<string, EvidenceChunk>): {
31
- text: string;
32
- citations: {
33
- chunkId: string;
34
- quote: string;
35
- }[];
29
+ text: string;
30
+ citations: {
31
+ chunkId: string;
32
+ quote: string;
33
+ }[];
36
34
  };
37
35
  /**
38
36
  * Validate a raw JSON string as an OpportunityBrief, ensuring citations
39
37
  * reference actual chunks and quotes are exact substrings.
40
38
  */
41
- declare function validateOpportunityBrief(raw: string, chunks: EvidenceChunk[]): OpportunityBrief;
39
+ export declare function validateOpportunityBrief(raw: string, chunks: EvidenceChunk[]): OpportunityBrief;
42
40
  /**
43
41
  * Validate a raw JSON string as an InsightExtraction.
44
42
  */
45
- declare function validateInsightExtraction(raw: string, chunks: EvidenceChunk[]): InsightExtraction;
43
+ export declare function validateInsightExtraction(raw: string, chunks: EvidenceChunk[]): InsightExtraction;
46
44
  /**
47
45
  * Validate a raw JSON string as a ContractPatchIntent.
48
46
  */
49
- declare function validatePatchIntent(raw: string): ContractPatchIntent;
47
+ export declare function validatePatchIntent(raw: string): ContractPatchIntent;
50
48
  /**
51
49
  * Validate a raw JSON string as an ImpactReport.
52
50
  */
53
- declare function validateImpactReport(raw: string): ImpactReport;
51
+ export declare function validateImpactReport(raw: string): ImpactReport;
54
52
  /**
55
53
  * Validate a raw JSON string as a TaskPack.
56
54
  */
57
- declare function validateTaskPack(raw: string): TaskPack;
55
+ export declare function validateTaskPack(raw: string): TaskPack;
58
56
  /**
59
57
  * Build a repair prompt from a validation error.
60
58
  */
61
- declare function buildRepairPrompt(error: string): string;
62
- declare function buildRepairPromptWithOutput(error: string, previousOutput: string, maxOutputChars?: number): string;
63
- //#endregion
64
- export { buildChunkIndex, buildRepairPrompt, buildRepairPromptWithOutput, parseStrictJSON, validateCitation, validateCitationsInTextBlock, validateImpactReport, validateInsightExtraction, validateOpportunityBrief, validatePatchIntent, validateTaskPack };
59
+ export declare function buildRepairPrompt(error: string): string;
60
+ export declare function buildRepairPromptWithOutput(error: string, previousOutput: string, maxOutputChars?: number): string;
65
61
  //# sourceMappingURL=validators.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"validators.d.ts","names":[],"sources":["../src/validators.ts"],"mappings":";;;;;;AAuEA;iBAAgB,eAAA,GAAA,CAAmB,MAAA,EAAQ,eAAA,EAAiB,GAAA,WAAc,CAAA;;;;iBAkB1D,eAAA,CACd,MAAA,EAAQ,aAAA,KACP,GAAA,SAAY,aAAA;;;;;iBAYC,gBAAA,CACd,QAA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,CAAC;IAAC,qBAAqB,CAAC,EAAE,OAAO,CAAA;CAAE;;;EAqBjE;AAED;;GAEG;AACH,wBAAgB,4BAA4B,CAC1C,KAAK,EAAE;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,OAAO,EAAE,CAAA;CAAE,EAC7C,UAAU,EAAE,GAAG,CAAC,MAAM,EAAE,aAAa,CAAC;;;;;;EAQvC;AAED;;;GAGG;AACH,wBAAgB,wBAAwB,CACtC,GAAG,EAAE,MAAM,EACX,MAAM,EAAE,aAAa,EAAE,GACtB,gBAAgB,CAyClB;AAED;;GAEG;AACH,wBAAgB,yBAAyB,CACvC,GAAG,EAAE,MAAM,EACX,MAAM,EAAE,aAAa,EAAE,GACtB,iBAAiB,CA4BnB;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,GAAG,EAAE,MAAM,GAAG,mBAAmB,CAoBpE;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,GAAG,EAAE,MAAM,GAAG,YAAY,CA2D9D;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,MAAM,GAAG,QAAQ,CAkCtD;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAOvD;AAOD,wBAAgB,2BAA2B,CACzC,KAAK,EAAE,MAAM,EACb,cAAc,EAAE,MAAM,EACtB,cAAc,SAAO,GACpB,MAAM,CAWR"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=validators.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"validators.test.d.ts","sourceRoot":"","sources":["../src/validators.test.ts"],"names":[],"mappings":""}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contractspec/lib.product-intent-utils",
3
- "version": "1.57.0",
3
+ "version": "1.59.0",
4
4
  "description": "Prompt builders and validators for product-intent workflows.",
5
5
  "keywords": [
6
6
  "contractspec",
@@ -19,35 +19,40 @@
19
19
  "scripts": {
20
20
  "publish:pkg": "bun publish --tolerate-republish --ignore-scripts --verbose",
21
21
  "publish:pkg:canary": "bun publish:pkg --tag canary",
22
- "build": "bun build:types && bun build:bundle",
23
- "build:bundle": "tsdown",
24
- "build:types": "tsc --noEmit",
25
- "dev": "bun build:bundle --watch",
22
+ "build": "bun run prebuild && bun run build:bundle && bun run build:types",
23
+ "build:bundle": "contractspec-bun-build transpile",
24
+ "build:types": "contractspec-bun-build types",
25
+ "dev": "contractspec-bun-build dev",
26
26
  "clean": "rimraf dist .turbo",
27
27
  "lint": "bun lint:fix",
28
28
  "lint:fix": "eslint src --fix",
29
29
  "lint:check": "eslint src",
30
- "test": "bun test"
30
+ "test": "bun test",
31
+ "prebuild": "contractspec-bun-build prebuild",
32
+ "typecheck": "tsc --noEmit"
31
33
  },
32
34
  "peerDependencies": {},
33
35
  "dependencies": {
34
- "@contractspec/lib.contracts": "1.57.0"
36
+ "@contractspec/lib.contracts": "1.59.0"
35
37
  },
36
38
  "devDependencies": {
37
- "@contractspec/tool.tsdown": "1.57.0",
38
- "@contractspec/tool.typescript": "1.57.0",
39
- "tsdown": "^0.20.3",
40
- "typescript": "^5.9.3"
39
+ "@contractspec/tool.typescript": "1.59.0",
40
+ "typescript": "^5.9.3",
41
+ "@contractspec/tool.bun": "1.58.0"
41
42
  },
42
43
  "exports": {
43
- ".": "./dist/index.js",
44
- "./*": "./*"
44
+ ".": "./src/index.ts"
45
45
  },
46
46
  "publishConfig": {
47
47
  "access": "public",
48
48
  "exports": {
49
- ".": "./dist/index.js",
50
- "./*": "./*"
49
+ ".": {
50
+ "types": "./dist/index.d.ts",
51
+ "bun": "./dist/index.js",
52
+ "node": "./dist/node/index.mjs",
53
+ "browser": "./dist/browser/index.js",
54
+ "default": "./dist/index.js"
55
+ }
51
56
  },
52
57
  "registry": "https://registry.npmjs.org/"
53
58
  },