Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[BFCL] Fix Irrelevance Category Performance for DeepSeek Coder Handler (
ShishirPatil#796) This PR updates the decoding logic for DeepSeek-Coder handler to fix its performance issue in the irrelevance category. The irrelevance category metric we use is that, either the `decode_ast` should fail (error) or the decoded output is empty (eg, empty list or empty string). For the DeepSeek-Coder model, When it outputs a valid function call, the model response will be a list of dictionaries `[{func1:{param1:val1,...}},{func2:{param2:val2,...}}]`, so it's fine for `decode_ast` to just return it without any processing. However, when the output is a message (not valid function call), under the `_parse_query_response_prompting` logic, the model response will be that message string, and in the current `decode_ast` implementation, that string will just be treated as the decoded output, and it would fail both the metric for the irrelevance category, which is not ideal.
- Loading branch information