Skip to content

Commit 8f82cd1

Browse files
committed
Fixed tests in comments
1 parent 611f716 commit 8f82cd1

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

sdk/openai/inference/src/clients/azure_openai_client.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,12 +49,11 @@ impl AzureOpenAIClient {
4949
/// ```no_run
5050
/// use azure_openai_inference::clients::{AzureOpenAIClient, AzureOpenAIClientMethods};
5151
/// use azure_identity::DefaultAzureCredentialBuilder;
52-
/// use std::sync::Arc;
5352
///
5453
/// let endpoint = std::env::var("AZURE_OPENAI_ENDPOINT").expect("Set AZURE_OPENAI_ENDPOINT environment variable");
5554
/// let client = AzureOpenAIClient::new(
5655
/// endpoint,
57-
/// Arc::new(DefaultAzureCredentialBuilder::new().build().unwrap()),
56+
/// DefaultAzureCredentialBuilder::new().build().unwrap(),
5857
/// None,
5958
/// ).unwrap();
6059
/// ```

sdk/openai/inference/src/models/chat_completions.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ pub mod request {
6464
/// # Example
6565
///
6666
/// ```rust
67-
/// let request = azure_openai_inference::request::CreateChatCompletionsRequest::with_user_message(
67+
/// let request = azure_openai_inference::CreateChatCompletionsRequest::with_user_message(
6868
/// "gpt-3.5-turbo-1106",
6969
/// "Why couldn't the eagles take Frodo directly to mount doom?");
7070
/// ```
@@ -81,7 +81,7 @@ pub mod request {
8181
/// # Example
8282
///
8383
/// ```rust
84-
/// let request = azure_openai_inference::request::CreateChatCompletionsRequest::with_user_message_and_stream(
84+
/// let request = azure_openai_inference::CreateChatCompletionsRequest::with_user_message_and_stream(
8585
/// "gpt-3.5-turbo-1106",
8686
/// "Why couldn't the eagles take Frodo directly to Mount Doom?");
8787
/// ```
@@ -101,11 +101,11 @@ pub mod request {
101101
///
102102
/// # Example
103103
/// ```rust
104-
/// let request = azure_openai_inference::request::CreateChatCompletionsRequest::with_messages(
104+
/// let request = azure_openai_inference::CreateChatCompletionsRequest::with_messages(
105105
/// "gpt-3.5-turbo-1106",
106106
/// vec![
107-
/// azure_openai_inference::request::ChatCompletionRequestMessage::with_system_role("You are a good math tutor who explains things briefly."),
108-
/// azure_openai_inference::request::ChatCompletionRequestMessage::with_user_role("What is the value of 'x' in the equation: '2x + 3 = 11'?"),
107+
/// azure_openai_inference::ChatCompletionRequestMessage::with_system_role("You are a good math tutor who explains things briefly."),
108+
/// azure_openai_inference::ChatCompletionRequestMessage::with_user_role("What is the value of 'x' in the equation: '2x + 3 = 11'?"),
109109
/// ]);
110110
pub fn with_messages(
111111
model: impl Into<String>,

0 commit comments

Comments
 (0)