aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/client/views/nodes/chatbot/tools/CanvasDocsTool.ts5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/client/views/nodes/chatbot/tools/CanvasDocsTool.ts b/src/client/views/nodes/chatbot/tools/CanvasDocsTool.ts
index cd4d223ec..25b17e5c9 100644
--- a/src/client/views/nodes/chatbot/tools/CanvasDocsTool.ts
+++ b/src/client/views/nodes/chatbot/tools/CanvasDocsTool.ts
@@ -6,7 +6,6 @@ import { DocumentView } from '../../DocumentView';
import { Doc } from '../../../../../fields/Doc';
import { v4 as uuidv4 } from 'uuid';
import { Id } from '../../../../../fields/FieldSymbols';
-import { DocumentType } from '../../../../documents/DocumentTypes';
const parameterRules = [
{
@@ -37,7 +36,7 @@ const parameterRules = [
const toolInfo: ToolInfo<typeof parameterRules> = {
name: 'canvasDocs',
- description: 'Access and analyze all documents currently visible on the canvas/workspace. This tool provides broader document recognition beyond just linked documents, allowing the agent to work with any document in the current view. Useful for comprehensive document analysis, finding related content, and understanding the full context of the workspace.',
+ description: 'Access and analyze all documents currently visible on the canvas/workspace. This tool provides broader document recognition beyond just linked documents, allowing the agent to work with any document in the current view. IMPORTANT: Always call this tool when the user asks about documents, even if you have previous results, as documents may have been added, removed, or modified since your last check. Useful for comprehensive document analysis, finding related content, and understanding the full context of the workspace.',
parameterRules,
citationRules: 'Cite documents by their title and type when referencing canvas documents.',
};
@@ -325,7 +324,7 @@ export class CanvasDocsTool extends BaseTool<typeof parameterRules> {
{
type: 'text',
text: `<chunk chunk_id="${chunkId}" chunk_type="canvas_documents">
-Found ${canvasDocs.length} documents on the canvas:
+Found ${canvasDocs.length} documents on the canvas (checked at ${new Date().toLocaleTimeString()}):
${documentSummaries.map(doc =>
`• ${doc.title} (${doc.type}) - ID: ${doc.id} - Position: (${doc.x}, ${doc.y}) - Size: ${doc.width}x${doc.height}`