openai-compat
Create Embeddings
Create embeddings using OpenAI-compatible API.
This endpoint is compatible with OpenAI's /v1/embeddings API, allowing drop-in replacement for any OpenAI SDK or client. Route-generated errors are emitted as top-level OpenAI {"error": {...}} envelopes, matching /v1/completions. The one exception is 422 request-body validation, which still returns FastAPI's HTTPValidationError {"detail": [...]} shape (out of scope for this route's error handling; known residual).
Args: request: OpenAI-format embedding request. http_request: FastAPI request (for app state). x_machine_profile: Machine profile header for routing validation.
Returns: OpenAI-format embedding response with embeddings and usage info.
post/v1/embeddings
Headers
X-SIE-MACHINE-PROFILEstring nullable
Request body
Response
Embeddings generated successfully