MCPcopy Create free account
hub / github.com/deepnote/deepnote / getFixAndDocumentPrompt

Function getFixAndDocumentPrompt

packages/mcp/src/prompts.ts:266–302  ·  view source on GitHub ↗
(args: Record<string, string> | undefined)

Source from the content-addressed store, hash-verified

264}
265
266function getFixAndDocumentPrompt(args: Record<string, string> | undefined): GetPromptResult {
267 const notebookPath = args?.notebook_path || 'notebook.deepnote'
268
269 return {
270 description: 'Workflow for fixing and documenting a notebook',
271 messages: [
272 {
273 role: 'user',
274 content: {
275 type: 'text',
276 text: `Fix issues and add documentation to: ${notebookPath}
277
278Follow this workflow:
279
2801. **Check for issues**:
281 Use ${TOOL_NAMES.read} with include: ["lint", "dag"] to identify:
282 - Undefined variables
283 - Missing imports
284 - Circular dependencies
285
2862. **Inspect and fix affected blocks**:
287 Use ${TOOL_NAMES.cat} path: "${notebookPath}" blockId: "<failed-or-flagged-block-id>"
288 Then use ${TOOL_NAMES.editBlock} to apply fixes.
289
2903. **Add documentation and structure**:
291 Use ${TOOL_NAMES.addBlock} to add:
292 - Markdown explanations before code blocks
293 - Section headers to organize the notebook
294
2954. **Re-run and verify**:
296 Use ${TOOL_NAMES.run} and inspect results with ${TOOL_NAMES.snapshotLoad}.
297 Use ${TOOL_NAMES.snapshotList} to review output history between runs.`,
298 },
299 },
300 ],
301 }
302}
303
304function getBlockTypesReferencePrompt(): GetPromptResult {
305 return {

Callers 1

getPromptFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected