Skip to content

Chat API响应的role字段不要设为null #54

@jichulu

Description

@jichulu

Chat API响应的role字段不要设为null,需要明确。

data: {"choices":[{"delta":{"content":"","role":null},"finish_reason":"stop","index":0,"logprobs":null}],"created":1717557740,"id":"f893ea8481f6fe1487bb2000a9ed3cd9","model":"deepseek-chat","object":"chat.completion.chunk","system_fingerprint":"fp_f4b7ce5256","usage":{"completion_tokens":7,"prompt_tokens":15,"total_tokens":22}}

data: [DONE]

在Azure.AI.OpenAI库不支持为null的role。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions