Skip to main content
Generate vector embeddings for text. Power RAG pipelines, semantic search, and document retrieval from Indian data centers.
POST https://api.forii.in/inference/v1/embeddings

Request

response = client.embeddings.create(
    model="forii/embed-v3",
    input=[
        "What is the GST rate for textiles?",
        "भारत में टेक्सटाइल का GST दर क्या है?"
    ]
)

print(len(response.data[0].embedding))  # 1024
print(response.usage)  # {"prompt_tokens": 20, "total_tokens": 20}

Response

{
  "object": "list",
  "data": [
    {
      "object": "embedding",
      "index": 0,
      "embedding": [0.0023, -0.0091, 0.0147, ...]
    },
    {
      "object": "embedding",
      "index": 1,
      "embedding": [0.0041, -0.0078, 0.0082, ...]
    }
  ],
  "model": "forii/embed-v3",
  "usage": {
    "prompt_tokens": 20,
    "total_tokens": 20
  }
}

Parameters

ParameterTypeRequiredDefaultDescription
modelstringYesforii/embed-v3
inputstring|arrayYesText or array of texts to embed
dimensionsintegerNo1024Output dimensions (variable-length embeddings)
encoding_formatstringNofloatfloat or base64

Pricing

Model₹/1K tokens
forii/embed-v3₹0.003
Embedding costs are extremely low. 1 million tokens costs ₹3. This makes bulk document indexing affordable for RAG pipelines.

Use cases

  • RAG (Retrieval-Augmented Generation) — Index documents in Hindi and English, retrieve relevant context for chat completions
  • Semantic search — Find similar documents across languages
  • Clustering — Group similar content by embedding distance
  • Deduplication — Detect near-duplicate documents