MCPcopy Index your code
hub / github.com/TaskingAI/TaskingAI / generator

Function generator

backend/app/routes/inference/chat_completion.py:60–63  ·  view source on GitHub ↗
(sse_chunk_dicts)

Source from the content-addressed store, hash-verified

58 raise_request_validation_error(f"Model {model.model_id} does not support streaming.")
59
60 async def generator(sse_chunk_dicts):
61 async for chunk_dict in sse_chunk_dicts:
62 yield f"data: {json.dumps(chunk_dict)}\n\n"
63 yield SSE_DONE_MSG
64
65 sse_chunk_dicts = await stream_chat_completion(
66 model=model,

Callers 1

api_chat_completionFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected