Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
Jintao-Huang committed Nov 6, 2024
1 parent 1ce44c5 commit 8d3d4b0
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions swift/llm/deploy.py
Original file line number Diff line number Diff line change
Expand Up @@ -516,9 +516,7 @@ async def _generate_full():
prompt_tokens=num_prompt_tokens,
completion_tokens=num_generated_tokens,
total_tokens=num_prompt_tokens + num_generated_tokens)
finish_reason = None
if output.status.name == 'FINISH':
finish_reason = 'stop'
finish_reason = 'stop' if output.status.name == 'FINISH' else None

if isinstance(request, ChatCompletionRequest):
action, action_input = split_action_action_input(response)
Expand Down

0 comments on commit 8d3d4b0

Please sign in to comment.