Improved schema description to allow Claude to pre-think harder before invoking thinkdeep

This commit is contained in:
Fahad
2025-06-15 19:05:23 +04:00
parent ad6cff4498
commit 6dcf095c3d
2 changed files with 10 additions and 5 deletions

View File

@@ -14,7 +14,7 @@ import os
# These values are used in server responses and for tracking releases
# IMPORTANT: This is the single source of truth for version and author info
# Semantic versioning: MAJOR.MINOR.PATCH
__version__ = "4.7.0"
__version__ = "4.7.1"
# Last update date in ISO format
__updated__ = "2025-06-15"
# Primary maintainer

View File

@@ -18,8 +18,13 @@ from .base import BaseTool, ToolRequest
class ThinkDeepRequest(ToolRequest):
"""Request model for thinkdeep tool"""
prompt: str = Field(..., description="Your current thinking/analysis to extend and validate")
problem_context: Optional[str] = Field(None, description="Additional context about the problem or goal")
prompt: str = Field(
...,
description="Your current thinking/analysis to extend and validate. IMPORTANT: Before using this tool, Claude MUST first think hard and establish a deep understanding of the topic and question by thinking through all relevant details, context, constraints, and implications. Share these extended thoughts and ideas in the prompt so the model has comprehensive information to work with for the best analysis.",
)
problem_context: Optional[str] = Field(
None, description="Additional context about the problem or goal. Be as expressive as possible."
)
focus_areas: Optional[list[str]] = Field(
None,
description="Specific aspects to focus on (architecture, performance, security, etc.)",
@@ -55,12 +60,12 @@ class ThinkDeepTool(BaseTool):
"properties": {
"prompt": {
"type": "string",
"description": "Your current thinking/analysis to extend and validate",
"description": "Your current thinking/analysis to extend and validate. IMPORTANT: Before using this tool, Claude MUST first think deeply and establish a deep understanding of the topic and question by thinking through all relevant details, context, constraints, and implications. Share these extended thoughts and ideas in the prompt so the model has comprehensive information to work with for the best analysis.",
},
"model": self.get_model_field_schema(),
"problem_context": {
"type": "string",
"description": "Additional context about the problem or goal",
"description": "Additional context about the problem or goal. Be as expressive as possible.",
},
"focus_areas": {
"type": "array",