Skip to content

Generatore di risposte LLM simulate

Genera risposte API LLM simulate e deterministiche — JSON di chat completion, flussi di eventi SSE con temporizzazione dei chunk e un curl di replay — per testare i client senza chiave API.

AI & Agents
cosmodev ~/tools/mock-llm-responder-
200 OK
{
  "id": "chatcmpl-mock-821bae6b",
  "object": "chat.completion",
  "created": 1735689600,
  "model": "mock-gpt-4o-mini",
  "choices": [
    {
      "index": 0,
      "message": {
        "role": "assistant",
        "content": "Hello, mock model!"
      },
      "finish_reason": "stop"
    }
  ],
  "usage": {
    "prompt_tokens": 5,
    "completion_tokens": 5,
    "total_tokens": 10
  }
}
chunk: 1primo byte: 20 mstra i chunk: 25 ms