**headers,
            },
            json=payload,
            stream=self.streaming,
        )
        return res
    def _create_chat_result(self, response: Mapping[str, Any]) -> ChatResult:
        generations = []
        for m in response["data"]["messages"]:
            message = _convert_dict_to_message(m)
            gen = ChatGeneration(message=message)
            generations.append(gen)
        token_usage = response["usage"]
        llm_output = {"token_usage": token_usage, "model": self.model}
        return ChatResult(generations=generations, llm_output=llm_output)
    @property
    def _llm_type(self) -> str:
        return "baichuan-chat"