async fn embed_openai(
config: &EmbeddingConfig,
texts: &[String],
) -> Result<Vec<Vec<f32>>>Expand description
Call the OpenAI embeddings API with retry/backoff.
Sends a batch of texts to POST https://api.openai.com/v1/embeddings
and returns the embedding vectors in input order.
Retry strategy:
- HTTP 429 or 5xx → retry with exponential backoff
- HTTP 4xx (not 429) → fail immediately
- Network error → retry