Conversation
- Restructured confusing sections: 'Object-like Results' → 'Dictionaries and Objects', 'Non-object Results' → 'Primitives and Collections', 'Complex Type Example' → 'Typed Models' - Simplified CodeGroup examples to show Tool Definition + MCP Result instead of 3-4 confusing tabs - Split Primitives/Collections into separate CodeGroups for clarity - Renamed 'Full Control with ToolResult' → 'ToolResult and Metadata' for better TOC visibility - Flattened ToolResult documentation with inline field descriptions instead of nested headings - Added version badge for ToolResult meta field (2.13.1) - Added clarification that ToolResult meta is separate from @mcp.tool meta - Improved example server with realistic metadata (execution time, character/word counts) - Fixed code formatting (multi-line objects, trailing commas)
Contributor
|
Caution Review failedThe pull request is closed. WalkthroughThe pull request updates documentation for tool outputs, reorganizing sections describing ToolResult with expanded examples for content, structured_content, and metadata fields. An example tool is enhanced to demonstrate metadata handling including execution timing and character counts. Changes
Poem
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: ASSERTIVE Plan: Pro 📒 Files selected for processing (2)
Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Comprehensive documentation improvements following #2283 (ToolResult meta support). The existing docs were confusing about structured output behavior and ToolResult usage.
Changes
Restructured Structured Output Examples
Improved ToolResult Documentation
Enhanced Example Server
Example
Before: Confusing tabs labeled "Traditional Text Content" and "Structured JSON Content"
After: Clear two-tab layout showing "Tool Definition" and "MCP Result" with both content and structuredContent fields visible inline
Fixes documentation confusion reported in #2283 review.
🤖 Generated with Claude Code