Azure OpenAI Embedding Job

The Azure OpenAI Embedding job type calls an Azure OpenAI embedding deployment synchronously via POST /openai/deployments/{deployment}/embeddings. The deployment is identified by its name — Polysync stores that in the External Id.

This job type is supported on the Azure OpenAI platform.

Required job fields

  • External Id — the deployment name.
  • Job TypeAzure OpenAI Embedding (set automatically on import).

Job discovery

GET /deployments?api-version=2023-05-01 — deployments whose model name contains embedding are imported as Embedding Jobs.

Parameter handling

Parameter Direction Role
input Input Text to embed.
embedding Output JSON array from data[0].embedding.
prompt_tokens Output usage.prompt_tokens.
total_tokens Output usage.total_tokens.

Request body: { "input": "<input>" }.

Execution flow

Synchronous, identical mechanics to Azure OpenAI Chat Completion:

  1. POST /openai/deployments/{deployment}/embeddings?api-version=2024-10-21.
  2. Output parameters populated immediately.
  3. RunId encodes status; no remote polling.
  4. Cancel is not supported.

Monitor URL

Same as Azure OpenAI Chat Completion.

Best practices

  • Store the resulting embedding array in a downstream Vector Database Job (e.g., Cosmos DB / pgvector) via an Input&Output parameter bound across Tasks.
  • For large bulk-embedding workloads consider Azure OpenAI Batch Job, which submits a single file with many rows.

Troubleshooting

  • InvalidInputModel — the deployment is not an embedding model. Re-classify by deleting and re-importing, or pick a deployment with embedding in its model name.