Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
fix: use OPEN_AI_API_URL (#7484)
Todsaporn Banjerdkit2aa8ccd6b16a
diff --git a/crates/ai/src/providers/open_ai/embedding.rs b/crates/ai/src/providers/open_ai/embedding.rsindex 4a8b051df3f..29ee8fac9ba 100644--- a/crates/ai/src/providers/open_ai/embedding.rs+++ b/crates/ai/src/providers/open_ai/embedding.rs@@ -134,7 +134,7 @@ impl OpenAiEmbeddingProvider {spans: Vec<&str>,request_timeout: u64,) -> Result<Response<AsyncBody>> {- let request = Request::post("https://api.openai.com/v1/embeddings")+ let request = Request::post(format!("{OPEN_AI_API_URL}/embeddings")).redirect_policy(isahc::config::RedirectPolicy::Follow).timeout(Duration::from_secs(request_timeout)).header("Content-Type", "application/json")