MCPcopy
hub / github.com/benoitc/gunicorn / embed

Function embed

examples/embedding_service/main.py:21–28  ·  view source on GitHub ↗
(request: EmbedRequest)

Source from the content-addressed store, hash-verified

19
20@app.post("/embed", response_model=EmbedResponse)
21async def embed(request: EmbedRequest):
22 client = get_dirty_client()
23 result = client.execute(
24 "embedding_service.embedding_app:EmbeddingApp",
25 "embed",
26 request.texts
27 )
28 return EmbedResponse(embeddings=result)
29
30
31@app.get("/health")

Callers

nothing calls this directly

Calls 3

get_dirty_clientFunction · 0.90
EmbedResponseClass · 0.85
executeMethod · 0.45

Tested by

no test coverage detected