feat: add response request tool render in chat_template and restructure output#1
Conversation
Summary of ChangesHello @LuYanFCP, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request significantly enhances the system's capability to handle tool interactions by introducing robust mechanisms for both tool definition rendering and tool call parsing. It ensures that tool specifications are correctly formatted and passed to models via chat templates, and that model-generated tool calls are accurately identified and structured in the output. These improvements are crucial for enabling advanced function calling features and improving the overall integration of external tools with the language model. Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request adds tool rendering in chat_template and tool call parsing in the response output, which is a great enhancement for function calling capabilities. The changes in serving_responses.py correctly implement the logic for converting tool formats and parsing tool calls from the model output. My review includes suggestions to refactor duplicated code and remove an unused variable to improve code quality and maintainability. The bug fix for the copy call is also correct. Overall, the implementation looks solid.
|
@LuYanFCP Plz fix the issues so I can merge it into the branch. |
83582b4 to
6e776d6
Compare
|
Fixed |
7617a89
into
Leoyzen:fix/response-api-tool-type-constraint
Add Feature in you patch
Test in Qwen3-Coder-Next
before patch

after patch
