Skip to content

Commit 059ae69

Browse files
committed
Fix trailing whitespace formatting issues
- Removed trailing whitespace from all LLM client files - Fixed formatting issues in gemini.rs, litellm.rs, openai.rs, openrouter.rs, vllm.rs - Fixed trailing whitespace in embed_text.rs - All files now comply with cargo fmt standards
1 parent f48b503 commit 059ae69

File tree

6 files changed

+10
-10
lines changed

6 files changed

+10
-10
lines changed

src/llm/gemini.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,14 +38,14 @@ impl AiStudioClient {
3838
if address.is_some() {
3939
api_bail!("Gemini doesn't support custom API address");
4040
}
41-
41+
4242
let api_key = if let Some(key) = api_key {
4343
key
4444
} else {
4545
std::env::var("GEMINI_API_KEY")
4646
.map_err(|_| anyhow::anyhow!("GEMINI_API_KEY environment variable must be set"))?
4747
};
48-
48+
4949
Ok(Self {
5050
api_key,
5151
client: reqwest::Client::new(),

src/llm/litellm.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ impl Client {
1010
_api_config: Option<super::LlmApiConfig>,
1111
) -> anyhow::Result<Self> {
1212
let address = address.unwrap_or_else(|| "http://127.0.0.1:4000".to_string());
13-
13+
1414
let api_key = api_key.or_else(|| std::env::var("LITELLM_API_KEY").ok());
15-
15+
1616
let mut config = OpenAIConfig::new().with_api_base(address);
1717
if let Some(api_key) = api_key {
1818
config = config.with_api_key(api_key);

src/llm/openai.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ impl Client {
6262
api_bail!("OPENAI_API_KEY environment variable must be set");
6363
}
6464
}
65-
65+
6666
Ok(Self {
6767
client: OpenAIClient::with_config(openai_config),
6868
})

src/llm/openrouter.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ impl Client {
1010
_api_config: Option<super::LlmApiConfig>,
1111
) -> anyhow::Result<Self> {
1212
let address = address.unwrap_or_else(|| "https://openrouter.ai/api/v1".to_string());
13-
13+
1414
let api_key = api_key.or_else(|| std::env::var("OPENROUTER_API_KEY").ok());
15-
15+
1616
let mut config = OpenAIConfig::new().with_api_base(address);
1717
if let Some(api_key) = api_key {
1818
config = config.with_api_key(api_key);

src/llm/vllm.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ impl Client {
1010
_api_config: Option<super::LlmApiConfig>,
1111
) -> anyhow::Result<Self> {
1212
let address = address.unwrap_or_else(|| "http://127.0.0.1:8000/v1".to_string());
13-
13+
1414
let api_key = api_key.or_else(|| std::env::var("VLLM_API_KEY").ok());
15-
15+
1616
let mut config = OpenAIConfig::new().with_api_base(address);
1717
if let Some(api_key) = api_key {
1818
config = config.with_api_key(api_key);

src/ops/functions/embed_text.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ impl SimpleFunctionFactoryBase for Factory {
127127
spec.api_type
128128
)
129129
}
130-
},
130+
}
131131
})
132132
} else {
133133
spec.api_config.clone()

0 commit comments

Comments
 (0)