Add support for json based content types in Message (#480)

This commit is contained in:
Adil Hafeez 2025-05-23 00:51:53 -07:00 committed by GitHub
parent f5e77bbe65
commit 218e9c540d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
16 changed files with 314 additions and 121 deletions

View file

@ -1,5 +1,5 @@
use common::api::open_ai::{
ChatCompletionsResponse, Choice, FunctionCallDetail, Message, ToolCall, ToolType, Usage,
ChatCompletionsResponse, Choice, ContentType, FunctionCallDetail, Message, ToolCall, ToolType, Usage
};
use common::configuration::Configuration;
use http::StatusCode;
@ -431,7 +431,7 @@ fn prompt_gateway_request_to_llm_gateway() {
index: Some(0),
message: Message {
role: "assistant".to_string(),
content: Some("hello from fake llm gateway".to_string()),
content: Some(ContentType::Text("hello from fake llm gateway".to_string())),
model: None,
tool_calls: None,
tool_call_id: None,