Miget is now Lyngbak. Same platform, same plans, same API.Why the name →

Startups get $300 or more in Lyngbak credits.Apply →

Moving production infrastructure? We migrate it for you, free.Talk to us →

PricingEnterpriseDashboard
Start for Free
← All templates

TEI Embeddings

A self-hosted embeddings API on CPU - bge-small in 512 MB, OpenAI-compatible, zero per-token bills.

1 GiB

1 service, 2 GB disk

$5/mo

flat resource

$0.013/h

Usage Billing

What is TEI Embeddings?

Embeddings are the quiet recurring cost of RAG: every document chunk and every query goes through the API meter, forever. Small open models ended that trade - bge-small at 384 dimensions handles real retrieval workloads, and Hugging Face’s TEI serves it from CPU in about half a gigabyte of RAM, no GPU anywhere.

TEI is a Rust server with an OpenAI-compatible /v1/embeddings endpoint, so existing clients just change the base URL. It is internal-only by design (no built-in auth): apps in your project call http://tei:5000 over the private network.

This completes the catalogue’s self-contained RAG loop: embed with tei, store in qdrant or chromadb, generate via the litellm gateway, trace in langfuse or phoenix - with the embedding leg now off the per-token meter.

What you get

  • OpenAI-compatible /v1/embeddings plus native /embed and /rerank
  • bge-small default: 384-dim, tens of ms per text on CPU
  • Rust + candle: ~512 MB RSS, no Python, no GPU
  • Model cached on a volume - fast restarts
  • Swap MODEL_ID for other embedders or rerankers
  • Apache-2.0, internal-only posture by default

How it runs on Lyngbak

ServiceRolePublic
teiembeddings API (:5000)no (by design - no built-in auth)

Sizing and billing

bge-small fits comfortably in 1 GiB; larger embedders (bge-base/large) want the next plans. One model per instance - run a second instance for a reranker.

Hobby resource$5/mo1 vCPU, 1 GiB, 10 GiB disk, shared CPU
Pro resource$25/mo1 vCPU, 2 GiB, 10 GiB disk, dedicated CPU
Usage Billing, shared CPU$0.013/h0.5 vCPU, 1 GiB reserved. $9/mo for a full month, billed by the second.
Usage Billing, dedicated CPU$0.047/h1 vCPU, 2 GiB reserved. $34/mo for a full month, billed by the second.

A resource is a flat monthly price, with RAM and disk add-ons when the stack needs a little more than a tier, and room for your own apps on a larger one. On Usage Billing each service takes the smallest size that fits it and is billed by the second it runs, so a stopped stack stops costing CPU and RAM. Its 1.95 GiB of volumes cost $0.15 per GiB a month ($0.29/mo) for as long as they exist. One workspace can use both. See pricing

Run it locally first

The same compose file runs with plain Docker Compose. Clone the template source, copy .env.example to .env, and run docker compose up -d.

Questions

How good is bge-small compared to API embeddings?

For typical RAG retrieval it is competitive with commercial small embeddings - strong MTEB scores at 384 dimensions, which also halves your vector storage versus 768+ dim models. Test with your corpus; swapping MODEL_ID is one variable.

What does this actually save?

API embeddings meter every chunk at index time and every query forever, and re-indexing a corpus repeats the whole bill. Self-hosted, the marginal cost of embedding is zero - re-index freely, embed logs, embed everything.

Why is it internal-only?

TEI ships no authentication, so it must not face the internet. In-project apps reach tei:5000 over the private network - the same posture as the qdrant and chromadb templates it pairs with.

Can it rerank too?

Yes - TEI serves reranker models on /rerank. Run a second instance with a reranker MODEL_ID (e.g. bge-reranker variants) and call it after retrieval for a meaningful quality lift.

More in LLM Infrastructure

Cognee

The memory engine for AI agents - knowledge graph + vector memory in one self-contained container.

Open the template →

Dify

The LLM app platform - visual builder, RAG, agents, observability - the catalogue’s heaviest stack, shipped honestly.

Open the template →

Flowise

Visual builder for LLM apps and agents - 100+ integrations, embeddable chat widgets, no prediction caps.

Open the template →
TEI Embeddings: an embeddings API: HuggingFace TEI on CPU | Lyngbak (formerly Miget)