@makerkit/prd 0.0.0-stage → 0.0.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 (54) hide show
  1. package/.turbo/turbo-build.log +46 -0
  2. package/.turbo/turbo-test.log +21 -0
  3. package/.turbo/turbo-typecheck.log +1 -0
  4. package/README.md +64 -2
  5. package/dist/LICENSE +21 -0
  6. package/dist/README.md +65 -0
  7. package/dist/index.d.ts +227 -0
  8. package/dist/index.js +1897 -0
  9. package/dist/index.mjs +1791 -0
  10. package/dist/mcp.d.ts +9 -0
  11. package/dist/mcp.js +532 -0
  12. package/dist/mcp.mjs +531 -0
  13. package/dist/node.d.ts +19 -0
  14. package/dist/node.js +94 -0
  15. package/dist/node.mjs +92 -0
  16. package/dist/package.json +49 -0
  17. package/dist/prd.service-DSBp8sMl.d.ts +2327 -0
  18. package/dist/prompts-Bber0S1Z.mjs +778 -0
  19. package/dist/prompts-CIX8IeAx.js +1233 -0
  20. package/package.json +66 -4
  21. package/src/__tests__/agent-workflow.test.ts +377 -0
  22. package/src/__tests__/attachments.test.ts +475 -0
  23. package/src/__tests__/node.test.ts +141 -0
  24. package/src/__tests__/plan-check.test.ts +229 -0
  25. package/src/__tests__/planning.test.ts +1059 -0
  26. package/src/__tests__/prd-operations.test.ts +423 -0
  27. package/src/__tests__/prd.service.test.ts +477 -0
  28. package/src/__tests__/prd.tool.test.ts +282 -0
  29. package/src/__tests__/templates.test.ts +141 -0
  30. package/src/applicability.ts +73 -0
  31. package/src/attachment-paths.ts +78 -0
  32. package/src/attachments.ts +160 -0
  33. package/src/edge-cases.ts +52 -0
  34. package/src/index.ts +35 -0
  35. package/src/markdown.ts +268 -0
  36. package/src/mcp/index.ts +839 -0
  37. package/src/mcp/tool-response.ts +85 -0
  38. package/src/node.ts +146 -0
  39. package/src/open-questions.ts +93 -0
  40. package/src/plan-check.ts +282 -0
  41. package/src/planning-operations.ts +429 -0
  42. package/src/prd-operations.ts +690 -0
  43. package/src/prd.service.ts +1051 -0
  44. package/src/prompts.ts +110 -0
  45. package/src/safe-file-name.ts +42 -0
  46. package/src/schema.ts +976 -0
  47. package/src/templates.ts +173 -0
  48. package/src/testing/fake-mcp-server.ts +81 -0
  49. package/src/types.ts +333 -0
  50. package/tsconfig.json +23 -0
  51. package/tsconfig.lib.json +8 -0
  52. package/tsconfig.spec.json +7 -0
  53. package/tsdown.config.mts +11 -0
  54. package/vitest.config.mts +8 -0
@@ -0,0 +1,173 @@
1
+ /**
2
+ * Starting points for new PRDs. A template fills sections the author would
3
+ * otherwise start empty, and gives `shape_prd` extra questions that matter for
4
+ * that kind of work. Everything it adds can be edited or removed afterwards.
5
+ */
6
+ export interface PrdTemplate {
7
+ id: TemplateId;
8
+ name: string;
9
+ description: string;
10
+ /** Sentence an agent can use to pick the right template. */
11
+ whenToUse: string;
12
+ defaults: {
13
+ nonGoals?: string[];
14
+ outOfScope?: string[];
15
+ openQuestions?: string[];
16
+ globalAcceptanceCriteria?: string[];
17
+ qualityStandards?: string[];
18
+ technicalConstraints?: string[];
19
+ rolloutPhases?: string[];
20
+ rollbackConditions?: string[];
21
+ };
22
+ /** Extra questions for the shaping interview. */
23
+ interviewFocus: string[];
24
+ }
25
+
26
+ export const TEMPLATE_IDS = [
27
+ 'saas-feature',
28
+ 'internal-tool',
29
+ 'integration',
30
+ 'mvp',
31
+ ] as const;
32
+
33
+ export type TemplateId = (typeof TEMPLATE_IDS)[number];
34
+
35
+ export const PRD_TEMPLATES: readonly PrdTemplate[] = [
36
+ {
37
+ id: 'saas-feature',
38
+ name: 'SaaS feature',
39
+ description:
40
+ 'A new feature in a multi-tenant SaaS: data scoped to accounts or teams, roles and permissions, and possibly plan limits.',
41
+ whenToUse:
42
+ 'Customers of an existing SaaS will use it, and its data belongs to an account or team.',
43
+ defaults: {
44
+ openQuestions: [
45
+ 'Does the data belong to a personal account, a team account, or both?',
46
+ 'Which roles can view, create, edit and delete it?',
47
+ 'Is it limited by billing plan, and what happens when a limit is reached?',
48
+ ],
49
+ globalAcceptanceCriteria: [
50
+ 'Members of one account cannot read or change another account’s data, including through the database API directly.',
51
+ 'Every action respects the role permissions agreed in this PRD.',
52
+ 'Empty, loading and error states are handled on every new screen.',
53
+ ],
54
+ qualityStandards: [
55
+ 'Access rules are enforced in the database (e.g. row-level security), not only in the UI.',
56
+ 'New database changes ship as migrations with tests for the access rules.',
57
+ ],
58
+ technicalConstraints: [
59
+ 'Follow the existing project conventions for data access, server actions and UI components.',
60
+ ],
61
+ rolloutPhases: [
62
+ 'Release behind a feature flag to internal accounts',
63
+ 'Enable for all accounts',
64
+ ],
65
+ rollbackConditions: [
66
+ 'Errors or data-access problems reported after release: turn the flag off',
67
+ ],
68
+ },
69
+ interviewFocus: [
70
+ 'Who owns the data: a personal account, a team, or both?',
71
+ 'Which roles can do what, and is anything limited by plan?',
72
+ 'What does a new account see before any data exists?',
73
+ ],
74
+ },
75
+ {
76
+ id: 'internal-tool',
77
+ name: 'Internal tool',
78
+ description:
79
+ 'A tool for yourself or your own team, where speed matters more than configurability.',
80
+ whenToUse:
81
+ 'Only you or your team will use it; it will not be sold to other organisations.',
82
+ defaults: {
83
+ nonGoals: [
84
+ 'Settings screens for things that can be hard-coded for our own use',
85
+ 'Support for other organisations or tenants',
86
+ ],
87
+ openQuestions: [
88
+ 'Who exactly will use it, and how often?',
89
+ 'What is hard-coded (stages, categories, fields) rather than configurable?',
90
+ ],
91
+ globalAcceptanceCriteria: [
92
+ 'Works on the devices the team actually uses (desktop and phone if needed).',
93
+ 'Only signed-in team members can access it.',
94
+ ],
95
+ qualityStandards: [
96
+ 'Prefer the simplest working version; no configuration UI unless asked for.',
97
+ ],
98
+ },
99
+ interviewFocus: [
100
+ 'What can be hard-coded because only we use it?',
101
+ 'Which existing tool or spreadsheet does this replace, and what annoys us about it?',
102
+ ],
103
+ },
104
+ {
105
+ id: 'integration',
106
+ name: 'Third-party integration',
107
+ description:
108
+ 'Connecting to an external service: an API, webhooks, OAuth, or a data sync.',
109
+ whenToUse: 'The work depends on an external service you do not control.',
110
+ defaults: {
111
+ openQuestions: [
112
+ 'Which direction does data flow: we call them, they call us (webhooks), or both?',
113
+ 'How do users connect their account (API key, OAuth), and where are credentials stored?',
114
+ 'What happens when the service is down, slow or rate-limits us?',
115
+ ],
116
+ globalAcceptanceCriteria: [
117
+ 'Credentials and tokens are stored encrypted or in secrets, never in client code or logs.',
118
+ 'Incoming webhooks are verified (signature) and safe to receive twice.',
119
+ 'Failures are retried or surfaced to the user; nothing fails silently.',
120
+ ],
121
+ qualityStandards: [
122
+ 'The external service is called through one module, so it can be faked in tests.',
123
+ ],
124
+ technicalConstraints: [
125
+ 'Respect the service’s rate limits and terms of use.',
126
+ ],
127
+ rollbackConditions: [
128
+ 'The integration can be disconnected without losing the user’s own data',
129
+ ],
130
+ },
131
+ interviewFocus: [
132
+ 'What exactly do we read from and write to the service?',
133
+ 'What does the user see while the service is unavailable?',
134
+ 'How is the integration disconnected, and what happens to synced data?',
135
+ ],
136
+ },
137
+ {
138
+ id: 'mvp',
139
+ name: 'First version (MVP)',
140
+ description:
141
+ 'The first version of a new product, cut down to what proves the idea.',
142
+ whenToUse:
143
+ 'The product does not exist yet and the goal is to learn whether it works.',
144
+ defaults: {
145
+ openQuestions: [
146
+ 'What is the one thing a first user must be able to do?',
147
+ 'How will we know it works (a number or a behaviour we can observe)?',
148
+ 'What is the deadline or budget for this first version?',
149
+ ],
150
+ outOfScope: ['Features that are not needed to prove the main idea'],
151
+ globalAcceptanceCriteria: [
152
+ 'A new user can sign up and reach the main action without help.',
153
+ ],
154
+ qualityStandards: ['Cut scope before cutting quality on the main flow.'],
155
+ },
156
+ interviewFocus: [
157
+ 'What is the smallest version that proves the idea?',
158
+ 'Which features can wait until after the first users try it?',
159
+ ],
160
+ },
161
+ ];
162
+
163
+ export function getTemplate(id: TemplateId): PrdTemplate {
164
+ const template = PRD_TEMPLATES.find((candidate) => candidate.id === id);
165
+
166
+ if (!template) {
167
+ throw new Error(
168
+ `Unknown template "${id}". Templates: ${TEMPLATE_IDS.join(', ')}.`,
169
+ );
170
+ }
171
+
172
+ return template;
173
+ }
@@ -0,0 +1,81 @@
1
+ import type { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
2
+ import type { ToolAnnotations } from '@modelcontextprotocol/sdk/types.js';
3
+ import type { ZodTypeAny } from 'zod/v3';
4
+
5
+ /**
6
+ * Minimal stand-in for McpServer used by tool adapter tests. Captures every
7
+ * registerTool call so tests can assert names, annotations and that the
8
+ * handler's structuredContent satisfies the declared outputSchema.
9
+ */
10
+ export interface RegisteredTool {
11
+ name: string;
12
+ config: {
13
+ title?: string;
14
+ description?: string;
15
+ inputSchema?: ZodTypeAny;
16
+ outputSchema?: ZodTypeAny;
17
+ annotations?: ToolAnnotations;
18
+ };
19
+ handler: (input: unknown) => Promise<Record<string, unknown>>;
20
+ }
21
+
22
+ export interface RegisteredPrompt {
23
+ name: string;
24
+ handler: (args: Record<string, unknown>) => {
25
+ messages: Array<{ role: string; content: { type: string; text: string } }>;
26
+ };
27
+ }
28
+
29
+ export function createFakeMcpServer() {
30
+ const tools: RegisteredTool[] = [];
31
+ const prompts: RegisteredPrompt[] = [];
32
+
33
+ const server = {
34
+ registerTool(
35
+ name: string,
36
+ config: RegisteredTool['config'],
37
+ handler: RegisteredTool['handler'],
38
+ ) {
39
+ tools.push({ name, config, handler });
40
+ return {};
41
+ },
42
+ registerPrompt(
43
+ name: string,
44
+ _config: unknown,
45
+ handler: RegisteredPrompt['handler'],
46
+ ) {
47
+ prompts.push({ name, handler });
48
+ return {};
49
+ },
50
+ };
51
+
52
+ return {
53
+ server: server as unknown as McpServer,
54
+ tools,
55
+ prompts,
56
+ tool(name: string) {
57
+ const tool = tools.find((item) => item.name === name);
58
+
59
+ if (!tool) {
60
+ throw new Error(`Tool "${name}" was not registered`);
61
+ }
62
+
63
+ return tool;
64
+ },
65
+ /** Call a tool and validate the result against its own outputSchema. */
66
+ async call(name: string, input: unknown = {}) {
67
+ const tool = this.tool(name);
68
+ const result = await tool.handler(input);
69
+
70
+ if (result.isError) {
71
+ return result;
72
+ }
73
+
74
+ if (tool.config.outputSchema) {
75
+ tool.config.outputSchema.parse(result.structuredContent);
76
+ }
77
+
78
+ return result;
79
+ },
80
+ };
81
+ }
package/src/types.ts ADDED
@@ -0,0 +1,333 @@
1
+ export interface CustomPhase {
2
+ id: string;
3
+ name: string;
4
+ description: string;
5
+ color: string;
6
+ order: number;
7
+ userStoryIds: string[];
8
+ }
9
+
10
+ export type StoryStatus =
11
+ | 'not_started'
12
+ | 'research'
13
+ | 'in_progress'
14
+ | 'review'
15
+ | 'completed'
16
+ | 'blocked';
17
+
18
+ export type StoryPriority = 'P0' | 'P1' | 'P2' | 'P3';
19
+
20
+ export type StoryComplexity = 'XS' | 'S' | 'M' | 'L' | 'XL';
21
+
22
+ /** Recorded when a story is marked completed and the project checks passed. */
23
+ export interface StoryVerification {
24
+ verifiedAt: string;
25
+ checks: string[];
26
+ passed: true;
27
+ }
28
+
29
+ /**
30
+ * A hand-off note an agent writes when it finishes working on a story, so the
31
+ * next story (often a fresh session with an empty context) knows what changed.
32
+ */
33
+ export interface StoryLogEntry {
34
+ at: string;
35
+ /** Plain-language list of what a human should now be able to try. */
36
+ whatsNew: string[];
37
+ /** Decisions, gotchas and file locations for the next agent. */
38
+ technicalNotes: string[];
39
+ /**
40
+ * Where the work departed from the PRD and why, so the person approving
41
+ * the story and the review_story prompt can judge it. Absent when there
42
+ * were none, and on logs written before it existed.
43
+ */
44
+ deviations?: string[];
45
+ }
46
+
47
+ export interface UserStory {
48
+ id: string;
49
+ title: string;
50
+ userStory: string;
51
+ businessValue: string;
52
+ acceptanceCriteria: string[];
53
+ status: StoryStatus;
54
+ priority: StoryPriority;
55
+ estimatedComplexity: StoryComplexity;
56
+ dependencies: string[];
57
+ notes?: string;
58
+ completedAt?: string;
59
+ verification?: StoryVerification;
60
+ log?: StoryLogEntry[];
61
+ /**
62
+ * Where this story is tested: the public entry points (a route, a server
63
+ * action, a service function) whose behaviour the tests exercise.
64
+ */
65
+ testSeams?: string[];
66
+ /** Ids of the PRD's attachments this story uses, e.g. a mockup. */
67
+ attachmentIds?: string[];
68
+ /**
69
+ * Design notes for this story only: layout, states and copy that the PRD's
70
+ * design guidance does not cover. Binding, like the guidance.
71
+ */
72
+ designNotes?: string[];
73
+ /**
74
+ * Security notes for this story only: the specific abuse to defend against
75
+ * and how. Binding, like the PRD's security considerations.
76
+ */
77
+ securityNotes?: string[];
78
+ }
79
+
80
+ /**
81
+ * A file or link the plan refers to: a mockup, a screenshot, reference docs.
82
+ * Files live in the PRD's own folder, `.prds/<prd name>/`, next to its JSON
83
+ * file. Exactly one of `path` and `url` is set.
84
+ */
85
+ export interface Attachment {
86
+ id: string;
87
+ title: string;
88
+ /** Relative to the PRD's folder, e.g. `mockups/approve-view.png`. */
89
+ path?: string;
90
+ url?: string;
91
+ /** What to take from it, e.g. "Layout only; colours are placeholders". */
92
+ note?: string;
93
+ }
94
+
95
+ /**
96
+ * Something that can go wrong or is easy to get wrong (bad input, partial
97
+ * success, retries, permissions, concurrency, time zones, limits...) and what
98
+ * should happen. An open case is undecided: an agent must ask, not assume.
99
+ */
100
+ export interface EdgeCase {
101
+ id: string;
102
+ case: string;
103
+ /** What should happen. Required once the case is decided. */
104
+ expectedBehavior: string;
105
+ status: 'open' | 'decided';
106
+ /** Stories it applies to; absent means the whole PRD. */
107
+ storyIds?: string[];
108
+ }
109
+
110
+ /**
111
+ * A decision the plan still needs. Written so a person can answer it without
112
+ * the conversation it came from: why it matters, the options and the
113
+ * recommended one. Answering it records a decision and removes it.
114
+ */
115
+ export interface OpenQuestion {
116
+ id: string;
117
+ question: string;
118
+ /** What goes wrong if an agent guesses instead. */
119
+ why?: string;
120
+ options?: string[];
121
+ /** The suggested answer, usually one of the options. */
122
+ recommended?: string;
123
+ /** Stories that cannot be built until it is answered. */
124
+ storyIds?: string[];
125
+ }
126
+
127
+ /** Optional parts of a PRD that can be marked not applicable. */
128
+ export type NotApplicableTopic =
129
+ | 'dataModel'
130
+ | 'outsideServices'
131
+ | 'security'
132
+ | 'design'
133
+ | 'qualityBar'
134
+ | 'edgeCases'
135
+ | 'rollout'
136
+ | 'measurement'
137
+ | 'glossary'
138
+ | 'risks';
139
+
140
+ /** A term the team has agreed on, so people and agents use the same words. */
141
+ export interface GlossaryTerm {
142
+ term: string;
143
+ definition: string;
144
+ /** Synonyms that should not be used for this concept. */
145
+ avoid: string[];
146
+ }
147
+
148
+ export interface RiskItem {
149
+ id: string;
150
+ description: string;
151
+ mitigation: string;
152
+ owner: string;
153
+ severity: 'low' | 'medium' | 'high';
154
+ }
155
+
156
+ export interface CrossDependency {
157
+ id: string;
158
+ name: string;
159
+ description: string;
160
+ blocking: boolean;
161
+ owner?: string;
162
+ }
163
+
164
+ export interface DecisionLogEntry {
165
+ id: string;
166
+ date: string;
167
+ decision: string;
168
+ rationale: string;
169
+ owner?: string;
170
+ status: 'proposed' | 'accepted' | 'superseded';
171
+ /**
172
+ * What the decision is about, e.g. `story:US001:dependencies`. Optional so
173
+ * hand-written decision logs stay valid; deleting a story supersedes the
174
+ * accepted decisions whose topic names it.
175
+ */
176
+ topic?: string;
177
+ }
178
+
179
+ export interface AgentTaskPacket {
180
+ id: string;
181
+ title: string;
182
+ scope: string;
183
+ doneCriteria: string[];
184
+ testPlan: string[];
185
+ likelyFiles: string[];
186
+ linkedStoryIds: string[];
187
+ dependencies: string[];
188
+ }
189
+
190
+ export interface StoryTraceabilityMap {
191
+ storyId: string;
192
+ featureId: string;
193
+ acceptanceCriteriaIds: string[];
194
+ successMetricIds: string[];
195
+ }
196
+
197
+ /**
198
+ * Text fields may use Markdown. Longer text (the overview, problem, solution
199
+ * description, story notes, decision rationale) may use any block Markdown;
200
+ * items of a list (acceptance criteria, non-goals, story log entries...) are
201
+ * rendered as bullets, so they keep to inline Markdown: bold, italics, code
202
+ * and links. Raw HTML is not rendered.
203
+ */
204
+ export interface StructuredPRD {
205
+ introduction: {
206
+ title: string;
207
+ overview: string;
208
+ lastUpdated: string;
209
+ };
210
+
211
+ problemStatement: {
212
+ problem: string;
213
+ marketOpportunity: string;
214
+ targetUsers: string[];
215
+ };
216
+
217
+ solutionOverview: {
218
+ description: string;
219
+ keyFeatures: string[];
220
+ successMetrics: string[];
221
+ };
222
+
223
+ nonGoals: string[];
224
+ outOfScope: string[];
225
+ assumptions: string[];
226
+ openQuestions: OpenQuestion[];
227
+ risks: RiskItem[];
228
+ dependencies: CrossDependency[];
229
+
230
+ userStories: UserStory[];
231
+ customPhases: CustomPhase[];
232
+ storyTraceability: StoryTraceabilityMap[];
233
+
234
+ technicalRequirements: {
235
+ constraints: string[];
236
+ integrationNeeds: string[];
237
+ complianceRequirements: string[];
238
+ };
239
+
240
+ technicalContracts: {
241
+ apis: string[];
242
+ dataModels: string[];
243
+ permissions: string[];
244
+ integrationBoundaries: string[];
245
+ };
246
+
247
+ acceptanceCriteria: {
248
+ global: string[];
249
+ qualityStandards: string[];
250
+ };
251
+
252
+ constraints: {
253
+ timeline: string;
254
+ budget?: string;
255
+ resources: string[];
256
+ nonNegotiables: string[];
257
+ };
258
+
259
+ rolloutPlan: {
260
+ featureFlags: string[];
261
+ migrationPlan: string[];
262
+ rolloutPhases: string[];
263
+ rollbackConditions: string[];
264
+ };
265
+
266
+ measurementPlan: {
267
+ events: string[];
268
+ dashboards: string[];
269
+ baselineMetrics: string[];
270
+ targetMetrics: string[];
271
+ guardrailMetrics: string[];
272
+ };
273
+
274
+ /** Things that can go wrong and what should happen. */
275
+ edgeCases: EdgeCase[];
276
+ /**
277
+ * Standing design rules for every story (components to use, tone, layout,
278
+ * empty and error states...). Individual design choices are decisions with a
279
+ * `design:` topic in the decision log.
280
+ */
281
+ designGuidance: string[];
282
+ /**
283
+ * Standing security rules for every story: input validation, secrets,
284
+ * rate limits, tenant isolation... Who can do what is in
285
+ * technicalContracts.permissions; sensitive data and compliance in
286
+ * technicalRequirements.complianceRequirements.
287
+ */
288
+ securityConsiderations: string[];
289
+ /**
290
+ * Parts that do not apply to this PRD, with the reason. The plan check does
291
+ * not ask for them and agents should not invent them.
292
+ */
293
+ notApplicable: Partial<Record<NotApplicableTopic, string>>;
294
+
295
+ decisionLog: DecisionLogEntry[];
296
+ glossary: GlossaryTerm[];
297
+ attachments: Attachment[];
298
+ agentTaskPackets: AgentTaskPacket[];
299
+ changeLog: string[];
300
+
301
+ metadata: {
302
+ version: string;
303
+ created: string;
304
+ lastUpdated: string;
305
+ lastValidatedAt: string;
306
+ approver: string;
307
+ /**
308
+ * High-water mark for story numbering. Story ids are quoted in commits and
309
+ * conversations, so a deleted id must never be handed to a different
310
+ * story: `max(existing) + 1` would recycle US002 as soon as US002 (the
311
+ * highest) was deleted. Absent on PRDs written before this existed, which
312
+ * fall back to the highest id present.
313
+ */
314
+ lastStoryNumber?: number;
315
+ /** High-water mark for attachment ids, for the same reason. */
316
+ lastAttachmentNumber?: number;
317
+ /** High-water mark for open question ids, for the same reason. */
318
+ lastQuestionNumber?: number;
319
+ /**
320
+ * Incremented on every save. A write whose PRD was read at an older
321
+ * revision is rejected, so two writers (an agent and the Board) cannot
322
+ * silently overwrite each other. Absent on files written before it existed.
323
+ */
324
+ revision?: number;
325
+ };
326
+
327
+ progress: {
328
+ overall: number;
329
+ completed: number;
330
+ total: number;
331
+ blocked: number;
332
+ };
333
+ }
package/tsconfig.json ADDED
@@ -0,0 +1,23 @@
1
+ {
2
+ "extends": "../../tsconfig.base.json",
3
+ "compilerOptions": {
4
+ "strict": true,
5
+ "noImplicitOverride": true,
6
+ "noImplicitReturns": true,
7
+ "noFallthroughCasesInSwitch": true,
8
+ "forceConsistentCasingInFileNames": true,
9
+ "target": "es2022",
10
+ "lib": ["es2022"],
11
+ "types": ["node"]
12
+ },
13
+ "files": [],
14
+ "include": [],
15
+ "references": [
16
+ {
17
+ "path": "./tsconfig.lib.json"
18
+ },
19
+ {
20
+ "path": "./tsconfig.spec.json"
21
+ }
22
+ ]
23
+ }
@@ -0,0 +1,8 @@
1
+ {
2
+ "extends": "./tsconfig.json",
3
+ "compilerOptions": {
4
+ "declaration": true
5
+ },
6
+ "include": ["src/**/*.ts"],
7
+ "exclude": ["src/**/__tests__/**", "src/testing/**"]
8
+ }
@@ -0,0 +1,7 @@
1
+ {
2
+ "extends": "./tsconfig.json",
3
+ "compilerOptions": {
4
+ "types": ["node", "vitest/globals"]
5
+ },
6
+ "include": ["src/**/*.ts", "vitest.config.mts"]
7
+ }
@@ -0,0 +1,11 @@
1
+ import { defineConfig } from 'tsdown';
2
+
3
+ import { libraryConfig } from '../../tsdown.base.mts';
4
+
5
+ export default defineConfig(
6
+ libraryConfig({
7
+ index: 'src/index.ts',
8
+ node: 'src/node.ts',
9
+ mcp: 'src/mcp/index.ts',
10
+ }),
11
+ );
@@ -0,0 +1,8 @@
1
+ import { defineConfig } from 'vitest/config';
2
+
3
+ export default defineConfig({
4
+ test: {
5
+ globals: true,
6
+ include: ['src/**/*.test.ts'],
7
+ },
8
+ });