Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BFCL] Bug Fix for Execution_Result_Message Construction for Prompt Caching Feature in Claude Handler #805

Merged
merged 1 commit into from
Nov 30, 2024

Conversation

HuanzhiMao
Copy link
Collaborator

This PR updates the _add_execution_results_prompting method in Claude handler to have the content field in the message be a list of one dictionary "content": [{"type": "text", "text": "abcd"}] instead of a string "content": "abcd". Prompt caching expects it in this format.

@HuanzhiMao HuanzhiMao added the BFCL-General General BFCL Issue label Nov 30, 2024
Copy link
Collaborator

@CharlieJCJ CharlieJCJ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@HuanzhiMao HuanzhiMao merged commit e34fee2 into ShishirPatil:main Nov 30, 2024
@HuanzhiMao HuanzhiMao deleted the claude branch November 30, 2024 22:24
@CharlieJCJ CharlieJCJ changed the title [BFCL] Minor Fix to Claude Handler for Better Prompt Caching [BFCL] Bug Fix to Prompt Caching in Claude Handler Nov 30, 2024
@CharlieJCJ CharlieJCJ changed the title [BFCL] Bug Fix to Prompt Caching in Claude Handler [BFCL] Bug Fix in "message" to Prompt Caching Feature in Claude Handler Nov 30, 2024
@CharlieJCJ CharlieJCJ changed the title [BFCL] Bug Fix in "message" to Prompt Caching Feature in Claude Handler [BFCL] Bug Fix for "message" construction for Prompt Caching Feature in Claude Handler Nov 30, 2024
@HuanzhiMao HuanzhiMao changed the title [BFCL] Bug Fix for "message" construction for Prompt Caching Feature in Claude Handler [BFCL] Bug Fix for Execution_Result_Message Construction for Prompt Caching Feature in Claude Handler Nov 30, 2024
VishnuSuresh27 pushed a commit to VishnuSuresh27/gorilla that referenced this pull request Dec 6, 2024
…Patil#805)

This PR updates the `_add_execution_results_prompting` method in Claude
handler to have the `content` field in the message be a list of one
dictionary `"content": [{"type": "text", "text": "abcd"}]` instead of a
string `"content": "abcd"`. Prompt caching expects it in this format.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
BFCL-General General BFCL Issue
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants