GET
/v1/schemas/ollama/chat/api/generate?kind=output
Accept:
| field | recorded source |
|---|---|
| schema | Source linked above. upstream-spec Source traced8e08be41dd858c933c32bef5ee8d0c5faf7d7462069a49b368731cfbceaab03{
"fetchedAt": 1794288644,
"extractorVersion": "2",
"verifiedAt": null
} |
Response body
14 properties · 0 required · 2 $defs| property | type | description | constraints |
|---|---|---|---|
| model | string | Model name | |
| created_at | string | ISO 8601 timestamp of response creation | |
| response | string | The model's generated text response | |
| thinking | string | The model's generated thinking output | |
| done | boolean | Indicates whether generation has finished | |
| done_reason | string | Reason the generation stopped | |
| total_duration | integer | Time spent generating the response in nanoseconds | |
| load_duration | integer | Time spent loading the model in nanoseconds | |
| prompt_eval_count | integer | Number of input tokens in the prompt | |
| prompt_eval_cached_count | integer | Number of prompt tokens read from the cache | |
| prompt_eval_duration | integer | Time spent evaluating uncached prompt tokens in nanoseconds | |
| eval_count | integer | Number of output tokens generated in the response | |
| eval_duration | integer | Time spent generating tokens in nanoseconds | |
| logprobs | Logprob[] | Log probability information for the generated tokens when logprobs are enabled |
Types
2 $defsLogprobobject
Log probability information for a generated token
| token | string | The text representation of the token | |
| logprob | number | The log probability of this token | |
| bytes | integer[] | The raw byte representation of the token | |
| top_logprobs | TokenLogprob[] | Most likely tokens and their log probabilities at this position |
TokenLogprobobject
Log probability information for a single token alternative
| token | string | The text representation of the token | |
| logprob | number | The log probability of this token | |
| bytes | integer[] | The raw byte representation of the token |
Validate a payload
before you spend tokensshell
$ curl -X POST https://modelschemas.com/v1/validate \
-d '{"provider":"ollama","endpointId":"api/generate","payload":{…}}'
→ {"valid": false, "errors": [{"path": "#", "keyword": "required", …}]}