Skip to content

Conversation

AyushKarupakula
Copy link

@AyushKarupakula AyushKarupakula commented Oct 9, 2025

Add PDF document support


Note

Adds handling for JSON tool outputs containing base64 PDFs by emitting Claude document blocks, with updated types and helper.

  • Agent (hud/agents/claude.py):
    • Tool result formatting: Parse JSON TextContent for pdf_base64; attach as Claude document block (with optional title text) before continuing normal processing; retains error/image/text handling.
    • New helper: document_to_content_block(filename, mime_type, base64_data) to build document blocks.
    • Types: Import and use BetaDocumentBlock; update tool_use_content_block to accept document blocks.
    • Docs: Expand format_tool_results docstring to mention file attachments (PDFs), images, and text.

Written by Cursor Bugbot for commit 21a67c2. This will update automatically on new commits. Configure here.

cursor[bot]

This comment was marked as outdated.

Copy link
Contributor

promptless bot commented Oct 9, 2025

📝 Documentation updates detected!

New suggestion: Add comprehensive Claude agent documentation with PDF support for PR #165

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant