codecartographer-pi 0.14.0 → 0.15.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 (33) hide show
  1. package/.codecarto/BACKLOG.md +4 -12
  2. package/.codecarto/GUIDE.md +35 -36
  3. package/.codecarto/NEW_THREAD_BLURB.md +3 -3
  4. package/.codecarto/skills/spec-delta-application/SKILL.md +2 -2
  5. package/.codecarto/templates/amendment.yaml +17 -0
  6. package/.codecarto/templates/conventions-template.md +6 -5
  7. package/.codecarto/templates/decisions-template.md +13 -10
  8. package/.codecarto/templates/phase-handoff.yaml +7 -0
  9. package/.codecarto/templates/spike-report.md +51 -0
  10. package/.codecarto/workflow/scaffold-version.yaml +1 -1
  11. package/agent-skill/codecartographer/SKILL.md +4 -1
  12. package/agent-skill/codecartographer/references/handoff-contract.md +12 -1
  13. package/agent-skill/codecartographer/references/orchestration.md +45 -0
  14. package/dist/core/amendment.d.ts +41 -0
  15. package/dist/core/amendment.js +140 -0
  16. package/dist/core/completion.d.ts +16 -0
  17. package/dist/core/completion.js +175 -3
  18. package/dist/core/index.d.ts +1 -0
  19. package/dist/core/index.js +1 -0
  20. package/dist/core/pipeline.js +18 -0
  21. package/dist/core/prompts.js +53 -0
  22. package/dist/core/status.d.ts +8 -1
  23. package/dist/core/status.js +27 -1
  24. package/dist/core/types.d.ts +24 -0
  25. package/dist/core/usage.d.ts +7 -0
  26. package/dist/core/usage.js +2 -1
  27. package/dist/core/workspace.d.ts +39 -0
  28. package/dist/core/workspace.js +92 -4
  29. package/dist/extensions/codecarto/auto-runner.js +1 -0
  30. package/dist/extensions/codecarto/index.js +4 -1
  31. package/dist/mcp-server/server.d.ts +118 -57
  32. package/dist/mcp-server/server.js +124 -9
  33. package/package.json +1 -1
@@ -4,6 +4,45 @@ export declare const packageRoot: string;
4
4
  export declare const packagedWorkspaceDir: string;
5
5
  export declare const PACKAGE_VERSION: string;
6
6
  export declare function getWorkspaceState(cwd: string): Promise<WorkspaceState | null>;
7
+ /** The orchestrator-maintained files init seeds and completion appends to. */
8
+ export declare const ORCHESTRATOR_FILES: readonly [{
9
+ readonly file: "CONVENTIONS.md";
10
+ readonly template: "conventions-template.md";
11
+ }, {
12
+ readonly file: "DECISIONS.md";
13
+ readonly template: "decisions-template.md";
14
+ }];
15
+ /**
16
+ * Seed the orchestrator-maintained files from the workspace's templates
17
+ * (issue #98): orchestration is on by default, so a fresh workspace starts
18
+ * with both skeletons instead of gating them behind a role ritual. Idempotent
19
+ * — existing files are never touched, and a scaffold without the templates
20
+ * (pre-template era) is left for completion's minimal-header fallback.
21
+ * @returns the file names created, for the caller's report.
22
+ */
23
+ export declare function seedOrchestratorFiles(workspaceDir: string): Promise<string[]>;
24
+ /** One scaffold refresh's outcome. */
25
+ export type RefreshScaffoldResult = {
26
+ /** Workspace-relative paths written, sorted. */
27
+ written: string[];
28
+ /** The workspace's scaffold version before the refresh, if any. */
29
+ scaffoldVersionBefore?: string;
30
+ /** The running framework version the scaffold now matches. */
31
+ scaffoldVersionAfter: string;
32
+ };
33
+ /**
34
+ * Refresh a workspace's framework-owned files from the packaged template
35
+ * (issue #102): both staleness notices instruct exactly this, and the only
36
+ * tool that previously touched scaffold files was init's force mode, which
37
+ * backs up the entire workspace. Copies every file the packaged template
38
+ * ships except project state (`workflow/status.yaml`), user configuration
39
+ * (`workflow/config.yaml`, usage log), user-owned top-level files
40
+ * (BACKLOG, THREAD_LOG, CONVENTIONS, DECISIONS), and session-written
41
+ * directories (`scratch/`, `inputs/`, `closeouts/`). Files the template no
42
+ * longer ships are left in place. Appends one THREAD_LOG entry naming the
43
+ * version transition.
44
+ */
45
+ export declare function refreshScaffold(cwd: string): Promise<RefreshScaffoldResult>;
7
46
  /**
8
47
  * Human-readable staleness notice for the workspace's .codecarto/ scaffold,
9
48
  * or null when the scaffold matches the running framework. A missing marker
@@ -3,7 +3,7 @@
3
3
  // + normalizes the per-project workspace state from disk, and provides the
4
4
  // atomic status-update primitive used by /codecarto-complete.
5
5
  import { existsSync, readFileSync } from "node:fs";
6
- import { appendFile, readFile, rename, writeFile } from "node:fs/promises";
6
+ import { appendFile, copyFile, mkdir, readFile, readdir, rename, writeFile } from "node:fs/promises";
7
7
  import { basename, dirname, join, relative } from "node:path";
8
8
  import { fileURLToPath } from "node:url";
9
9
  import { acquireLock, applyHandoff, createEmptyStatus, normalizeStatus, parseHandoff } from "./status.js";
@@ -98,6 +98,94 @@ export async function getWorkspaceState(cwd) {
98
98
  ...(scaffoldVersion !== undefined && { scaffoldVersion }),
99
99
  };
100
100
  }
101
+ /** The orchestrator-maintained files init seeds and completion appends to. */
102
+ export const ORCHESTRATOR_FILES = [
103
+ { file: "CONVENTIONS.md", template: "conventions-template.md" },
104
+ { file: "DECISIONS.md", template: "decisions-template.md" },
105
+ ];
106
+ /**
107
+ * Seed the orchestrator-maintained files from the workspace's templates
108
+ * (issue #98): orchestration is on by default, so a fresh workspace starts
109
+ * with both skeletons instead of gating them behind a role ritual. Idempotent
110
+ * — existing files are never touched, and a scaffold without the templates
111
+ * (pre-template era) is left for completion's minimal-header fallback.
112
+ * @returns the file names created, for the caller's report.
113
+ */
114
+ export async function seedOrchestratorFiles(workspaceDir) {
115
+ const created = [];
116
+ for (const { file, template } of ORCHESTRATOR_FILES) {
117
+ const target = join(workspaceDir, file);
118
+ if (await pathExists(target))
119
+ continue;
120
+ const templatePath = join(workspaceDir, "templates", template);
121
+ if (!(await pathExists(templatePath)))
122
+ continue;
123
+ await copyFile(templatePath, target);
124
+ created.push(file);
125
+ }
126
+ return created;
127
+ }
128
+ /**
129
+ * Workspace paths refresh never touches: project state, user configuration,
130
+ * user-owned top-level files, and the directories sessions write into.
131
+ * Everything else present in the packaged template is framework-owned.
132
+ */
133
+ const REFRESH_EXCLUDED_TOP_LEVEL = new Set(["BACKLOG.md", "THREAD_LOG.md", "CONVENTIONS.md", "DECISIONS.md"]);
134
+ const REFRESH_EXCLUDED_DIRS = new Set(["scratch", "inputs", "closeouts"]);
135
+ const REFRESH_EXCLUDED_WORKFLOW_FILES = new Set(["status.yaml", "config.yaml", ".usage.local.yaml"]);
136
+ async function listTemplateFiles(dir, relativeDir = "") {
137
+ const entries = await readdir(dir, { withFileTypes: true });
138
+ const files = [];
139
+ for (const entry of entries) {
140
+ const relativePath = relativeDir ? `${relativeDir}/${entry.name}` : entry.name;
141
+ if (entry.isDirectory()) {
142
+ if (!relativeDir && REFRESH_EXCLUDED_DIRS.has(entry.name))
143
+ continue;
144
+ files.push(...await listTemplateFiles(join(dir, entry.name), relativePath));
145
+ continue;
146
+ }
147
+ if (!relativeDir && REFRESH_EXCLUDED_TOP_LEVEL.has(entry.name))
148
+ continue;
149
+ if (relativeDir === "workflow" && REFRESH_EXCLUDED_WORKFLOW_FILES.has(entry.name))
150
+ continue;
151
+ files.push(relativePath);
152
+ }
153
+ return files;
154
+ }
155
+ /**
156
+ * Refresh a workspace's framework-owned files from the packaged template
157
+ * (issue #102): both staleness notices instruct exactly this, and the only
158
+ * tool that previously touched scaffold files was init's force mode, which
159
+ * backs up the entire workspace. Copies every file the packaged template
160
+ * ships except project state (`workflow/status.yaml`), user configuration
161
+ * (`workflow/config.yaml`, usage log), user-owned top-level files
162
+ * (BACKLOG, THREAD_LOG, CONVENTIONS, DECISIONS), and session-written
163
+ * directories (`scratch/`, `inputs/`, `closeouts/`). Files the template no
164
+ * longer ships are left in place. Appends one THREAD_LOG entry naming the
165
+ * version transition.
166
+ */
167
+ export async function refreshScaffold(cwd) {
168
+ const state = await getWorkspaceState(cwd);
169
+ if (!state)
170
+ throw new Error("CodeCartographer workspace not found. Run /codecarto-init first.");
171
+ if (!existsSync(packagedWorkspaceDir)) {
172
+ throw new Error("Packaged .codecarto template is missing. Reinstall codecartographer-pi.");
173
+ }
174
+ const scaffoldVersionBefore = state.scaffoldVersion;
175
+ const files = (await listTemplateFiles(packagedWorkspaceDir)).sort();
176
+ for (const relativePath of files) {
177
+ const target = join(state.workspaceDir, relativePath);
178
+ await mkdir(dirname(target), { recursive: true });
179
+ await copyFile(join(packagedWorkspaceDir, relativePath), target);
180
+ }
181
+ const entry = `- ${new Date().toISOString().slice(0, 10)} — scaffold-refresh — Refreshed ${files.length} framework-owned file(s) from the packaged template (${scaffoldVersionBefore ?? "unversioned"} → ${PACKAGE_VERSION}); project state, user config, and session outputs untouched.`;
182
+ await appendFile(join(state.workspaceDir, "THREAD_LOG.md"), `${entry}\n`, "utf8");
183
+ return {
184
+ written: files,
185
+ ...(scaffoldVersionBefore !== undefined && { scaffoldVersionBefore }),
186
+ scaffoldVersionAfter: PACKAGE_VERSION,
187
+ };
188
+ }
101
189
  // Numeric x.y.z comparison; null when either side is not a plain dotted triple.
102
190
  function compareDottedVersions(a, b) {
103
191
  const parse = (version) => {
@@ -125,7 +213,7 @@ function compareDottedVersions(a, b) {
125
213
  export function describeScaffoldStaleness(state) {
126
214
  const scaffold = state.scaffoldVersion;
127
215
  if (!scaffold) {
128
- return "This workspace's .codecarto/ scaffold has no workflow/scaffold-version.yaml marker (introduced after v0.12.11), so its framework-owned files (GUIDE.md, templates/, workflow/ pipelines and VALIDATE.md) may predate the v0.12.0 handoff contract. Refresh them from the packaged CodeCartographer template.";
216
+ return "This workspace's .codecarto/ scaffold has no workflow/scaffold-version.yaml marker (introduced after v0.12.11), so its framework-owned files (GUIDE.md, templates/, workflow/ pipelines and VALIDATE.md) may predate the v0.12.0 handoff contract. Refresh them from the packaged CodeCartographer template (codecarto_refresh_scaffold does exactly this without touching project state).";
129
217
  }
130
218
  const comparison = compareDottedVersions(scaffold, PACKAGE_VERSION);
131
219
  if (comparison === 0)
@@ -133,10 +221,10 @@ export function describeScaffoldStaleness(state) {
133
221
  if (comparison === null) {
134
222
  return scaffold === PACKAGE_VERSION
135
223
  ? null
136
- : `This workspace's scaffold version (${scaffold}) does not match the running framework (${PACKAGE_VERSION}). Refresh the framework-owned files (GUIDE.md, templates/, workflow/) from the packaged template.`;
224
+ : `This workspace's scaffold version (${scaffold}) does not match the running framework (${PACKAGE_VERSION}). Refresh the framework-owned files (GUIDE.md, templates/, workflow/) from the packaged template — codecarto_refresh_scaffold does exactly this without touching project state.`;
137
225
  }
138
226
  if (comparison < 0) {
139
- return `This workspace's scaffold (v${scaffold}) is older than the running framework (v${PACKAGE_VERSION}). Refresh the framework-owned files (GUIDE.md, templates/, workflow/) from the packaged template to pick up pipeline and template fixes.`;
227
+ return `This workspace's scaffold (v${scaffold}) is older than the running framework (v${PACKAGE_VERSION}). Refresh the framework-owned files (GUIDE.md, templates/, workflow/) from the packaged template to pick up pipeline and template fixes — codecarto_refresh_scaffold does exactly this without touching project state.`;
140
228
  }
141
229
  return `This workspace's scaffold (v${scaffold}) is newer than the running framework (v${PACKAGE_VERSION}). Upgrade CodeCartographer to at least v${scaffold}.`;
142
230
  }
@@ -357,6 +357,7 @@ async function recordUsage(workspaceDir, phaseId, status, activity, sessionFile)
357
357
  output: activity.lifetimeUsage.output,
358
358
  cache_write: activity.lifetimeUsage.cacheWrite,
359
359
  },
360
+ recorded_by: "pi-runner",
360
361
  compactions: activity.compactions,
361
362
  ...(sessionFile ? { session_file: sessionFile } : {}),
362
363
  });
@@ -8,7 +8,7 @@ import { narrateDashboard } from "./dashboard-narrator.js";
8
8
  import { writeDashboard } from "./dashboard-writer.js";
9
9
  import { parseNextFlags } from "./next-flags.js";
10
10
  import { phaseCompactionExtension } from "./phase-compaction.js";
11
- import { buildPhasePrompt, buildSkillPrompt, buildValidationSummary, canonicalPath, computePerPhaseTotals, computeTotals, createEmptyStatus, DEFAULT_PIPELINE_PATH, describeScaffoldStaleness, deriveSlug, discoverLibrary, getNextEligiblePhase, getPipelineLabel, getWorkspaceState, isWithinPathResolved, listSkillNames, loadCodecartoConfig, loadUsage, loadYamlFile, normalizeForComparison, packagedWorkspaceDir, pathExists, PACKAGE_VERSION, PhasePreflightError, PIPELINE_ALIASES, publishEntry, resolvePhase, resolvePipelineChoice, runPhasePreflight, stringifySimpleYaml, switchPipeline, validatePhaseOutput, writeLibraryConfig, } from "../../core/index.js";
11
+ import { buildPhasePrompt, buildSkillPrompt, buildValidationSummary, canonicalPath, computePerPhaseTotals, computeTotals, createEmptyStatus, DEFAULT_PIPELINE_PATH, describeScaffoldStaleness, deriveSlug, discoverLibrary, getNextEligiblePhase, getPipelineLabel, getWorkspaceState, isWithinPathResolved, listSkillNames, loadCodecartoConfig, loadUsage, loadYamlFile, normalizeForComparison, packagedWorkspaceDir, pathExists, PACKAGE_VERSION, PhasePreflightError, PIPELINE_ALIASES, publishEntry, resolvePhase, resolvePipelineChoice, runPhasePreflight, seedOrchestratorFiles, stringifySimpleYaml, switchPipeline, validatePhaseOutput, writeLibraryConfig, } from "../../core/index.js";
12
12
  import { initLibrary } from "../../core/library.js";
13
13
  import { resolveUserConfigPath } from "../../core/orchestrator-config.js";
14
14
  const STATUS_WIDGET_ID = "codecarto-widget";
@@ -282,6 +282,9 @@ export default function codeCartographerExtension(pi) {
282
282
  const normalizedStatus = createEmptyStatus(basename(ctx.cwd), selectedPipelinePath, pipeline);
283
283
  normalizedStatus.last_updated = new Date().toISOString();
284
284
  await writeFile(rawStatusPath, `${stringifySimpleYaml(normalizedStatus)}\n`, "utf8");
285
+ // Orchestration is on by default (issue #97/#98): seed the files its
286
+ // duties maintain so they exist from the first phase.
287
+ await seedOrchestratorFiles(targetWorkspaceDir);
285
288
  codecartoModeActive = true;
286
289
  lastFeedbackLines = [`Initialized workspace with pipeline: ${getPipelineLabel(selectedPipelinePath)}`];
287
290
  ctx.ui.notify(`Initialized CodeCartographer (${getPipelineLabel(selectedPipelinePath)})`, "info");
@@ -4,79 +4,95 @@ export declare function handleInit(args: {
4
4
  pipeline?: string;
5
5
  force?: boolean;
6
6
  }): Promise<{
7
- content: Array<{
7
+ content: {
8
8
  type: "text";
9
9
  text: string;
10
- }>;
11
- structuredContent?: Record<string, unknown>;
10
+ }[];
11
+ structuredContent: {
12
+ text: string;
13
+ };
12
14
  }>;
13
15
  export declare function handleStatus(args: {
14
16
  cwd: string;
15
17
  }): Promise<{
16
- content: Array<{
18
+ content: {
17
19
  type: "text";
18
20
  text: string;
19
- }>;
20
- structuredContent?: Record<string, unknown>;
21
+ }[];
22
+ structuredContent: {
23
+ text: string;
24
+ };
21
25
  }>;
22
26
  export declare function handleSwitchPipeline(args: {
23
27
  cwd: string;
24
28
  pipeline: string;
25
29
  }): Promise<{
26
- content: Array<{
30
+ content: {
27
31
  type: "text";
28
32
  text: string;
29
- }>;
30
- structuredContent?: Record<string, unknown>;
33
+ }[];
34
+ structuredContent: {
35
+ text: string;
36
+ };
31
37
  }>;
32
38
  export declare function handleNext(args: {
33
39
  cwd: string;
34
40
  }): Promise<{
35
- content: Array<{
41
+ content: {
36
42
  type: "text";
37
43
  text: string;
38
- }>;
39
- structuredContent?: Record<string, unknown>;
44
+ }[];
45
+ structuredContent: {
46
+ text: string;
47
+ };
40
48
  }>;
41
49
  export declare function handlePhase(args: {
42
50
  cwd: string;
43
51
  phase: string;
44
52
  }): Promise<{
45
- content: Array<{
53
+ content: {
46
54
  type: "text";
47
55
  text: string;
48
- }>;
49
- structuredContent?: Record<string, unknown>;
56
+ }[];
57
+ structuredContent: {
58
+ text: string;
59
+ };
50
60
  }>;
51
61
  export declare function handleValidate(args: {
52
62
  cwd: string;
53
63
  phase?: string;
54
64
  }): Promise<{
55
- content: Array<{
65
+ content: {
56
66
  type: "text";
57
67
  text: string;
58
- }>;
59
- structuredContent?: Record<string, unknown>;
68
+ }[];
69
+ structuredContent: {
70
+ text: string;
71
+ };
60
72
  }>;
61
73
  export declare function handleComplete(args: {
62
74
  cwd: string;
63
75
  phase?: string;
64
76
  }): Promise<{
65
- content: Array<{
77
+ content: {
66
78
  type: "text";
67
79
  text: string;
68
- }>;
69
- structuredContent?: Record<string, unknown>;
80
+ }[];
81
+ structuredContent: {
82
+ text: string;
83
+ };
70
84
  }>;
71
85
  export declare function handleSkill(args: {
72
86
  cwd: string;
73
87
  name: string;
74
88
  }): Promise<{
75
- content: Array<{
89
+ content: {
76
90
  type: "text";
77
91
  text: string;
78
- }>;
79
- structuredContent?: Record<string, unknown>;
92
+ }[];
93
+ structuredContent: {
94
+ text: string;
95
+ };
80
96
  }>;
81
97
  export declare function readSpecArg(args: {
82
98
  spec?: unknown;
@@ -84,25 +100,31 @@ export declare function readSpecArg(args: {
84
100
  cwd?: unknown;
85
101
  }, allowedRoots: string[]): Promise<string>;
86
102
  export declare function handlePublish(args: Record<string, unknown>): Promise<{
87
- content: Array<{
103
+ content: {
88
104
  type: "text";
89
105
  text: string;
90
- }>;
91
- structuredContent?: Record<string, unknown>;
106
+ }[];
107
+ structuredContent: {
108
+ text: string;
109
+ };
92
110
  }>;
93
111
  export declare function handleLibraryList(args: Record<string, unknown>): Promise<{
94
- content: Array<{
112
+ content: {
95
113
  type: "text";
96
114
  text: string;
97
- }>;
98
- structuredContent?: Record<string, unknown>;
115
+ }[];
116
+ structuredContent: {
117
+ text: string;
118
+ };
99
119
  }>;
100
120
  export declare function handleLibraryReindex(args: Record<string, unknown>): Promise<{
101
- content: Array<{
121
+ content: {
102
122
  type: "text";
103
123
  text: string;
104
- }>;
105
- structuredContent?: Record<string, unknown>;
124
+ }[];
125
+ structuredContent: {
126
+ text: string;
127
+ };
106
128
  }>;
107
129
  export declare function handleLibraryInit(args: {
108
130
  library_path: string;
@@ -110,75 +132,114 @@ export declare function handleLibraryInit(args: {
110
132
  namespace?: string;
111
133
  cwd?: string;
112
134
  }): Promise<{
113
- content: Array<{
135
+ content: {
114
136
  type: "text";
115
137
  text: string;
116
- }>;
117
- structuredContent?: Record<string, unknown>;
138
+ }[];
139
+ structuredContent: {
140
+ text: string;
141
+ };
118
142
  }>;
119
143
  export declare function handleVision(args: {
120
144
  cwd: string;
121
145
  raw_text: string;
122
146
  }): Promise<{
123
- content: Array<{
147
+ content: {
124
148
  type: "text";
125
149
  text: string;
126
- }>;
127
- structuredContent?: Record<string, unknown>;
150
+ }[];
151
+ structuredContent: {
152
+ text: string;
153
+ };
128
154
  }>;
129
155
  export declare function handleConfig(args: {
130
156
  cwd?: string;
131
157
  }): Promise<{
132
- content: Array<{
158
+ content: {
133
159
  type: "text";
134
160
  text: string;
135
- }>;
136
- structuredContent?: Record<string, unknown>;
161
+ }[];
162
+ structuredContent: {
163
+ text: string;
164
+ };
137
165
  }>;
138
166
  export declare function handleOpen(args: {
139
167
  cwd: string;
140
168
  }): Promise<{
141
- content: Array<{
169
+ content: {
142
170
  type: "text";
143
171
  text: string;
144
- }>;
145
- structuredContent?: Record<string, unknown>;
172
+ }[];
173
+ structuredContent: {
174
+ text: string;
175
+ };
146
176
  }>;
147
177
  export declare function handleUsage(args: {
148
178
  cwd: string;
149
179
  }): Promise<{
150
- content: Array<{
180
+ content: {
151
181
  type: "text";
152
182
  text: string;
153
- }>;
154
- structuredContent?: Record<string, unknown>;
183
+ }[];
184
+ structuredContent: {
185
+ text: string;
186
+ };
155
187
  }>;
156
188
  export declare function handleDashboard(args: {
157
189
  cwd: string;
158
190
  }): Promise<{
159
- content: Array<{
191
+ content: {
160
192
  type: "text";
161
193
  text: string;
162
- }>;
163
- structuredContent?: Record<string, unknown>;
194
+ }[];
195
+ structuredContent: {
196
+ text: string;
197
+ };
164
198
  }>;
165
199
  export declare function handleListSkills(args: {
166
200
  cwd: string;
167
201
  }): Promise<{
168
- content: Array<{
202
+ content: {
203
+ type: "text";
204
+ text: string;
205
+ }[];
206
+ structuredContent: {
207
+ text: string;
208
+ };
209
+ }>;
210
+ export declare function handleRefreshScaffold(args: {
211
+ cwd: string;
212
+ }): Promise<{
213
+ content: {
169
214
  type: "text";
170
215
  text: string;
171
- }>;
172
- structuredContent?: Record<string, unknown>;
216
+ }[];
217
+ structuredContent: {
218
+ text: string;
219
+ };
220
+ }>;
221
+ export declare function handleAmend(args: {
222
+ cwd: string;
223
+ name: string;
224
+ }): Promise<{
225
+ content: {
226
+ type: "text";
227
+ text: string;
228
+ }[];
229
+ structuredContent: {
230
+ text: string;
231
+ };
173
232
  }>;
174
233
  export declare function handleGuide(args: {
175
234
  topic?: string;
176
235
  }): Promise<{
177
- content: Array<{
236
+ content: {
178
237
  type: "text";
179
238
  text: string;
180
- }>;
181
- structuredContent?: Record<string, unknown>;
239
+ }[];
240
+ structuredContent: {
241
+ text: string;
242
+ };
182
243
  }>;
183
244
  export declare function buildServer(): Server<{
184
245
  method: string;