GET

/v1/schemas/ollama/chat/api/generate

kind inputactivity chathash 025a60d2…extracted Nov 10, 2026version currentsource upstream spec ↗
fieldrecorded source
schemaSource linked above.

upstream-spec

Source trace
d8e08be41dd858c933c32bef5ee8d0c5faf7d7462069a49b368731cfbceaab03
{
  "fetchedAt": 1794288644,
  "extractorVersion": "2",
  "verifiedAt": null
}

Request body

13 properties · 1 required · 2 $defs
propertytypedescriptionconstraints
model*stringModel name
promptstringText for the model to generate a response from
suffixstringUsed for fill-in-the-middle models, text that appears after the user prompt and before the model response
imagesstring[]
formatstring | objectStructured output format for the model to generate a response from. Supports either the string `"json"` or a JSON schema object.
systemstringSystem prompt for the model to generate a response from
streambooleanWhen true, returns a stream of partial responsesdefault: true
thinkboolean | stringControls a model's thinking output. Use `/api/show` to discover the supported values and default for the selected model. `true` requests thinking, `false` requests no thinking output, and `null` uses the model default. String values are model-defined; supporte…nullable
rawbooleanWhen true, returns the raw response from the model without any prompt templating
keep_alivestring | numberModel keep-alive duration (for example `5m` or `0` to unload immediately)
optionsModelOptionsRuntime options that control text generation
logprobsbooleanWhether to return log probabilities of the output tokens
top_logprobsintegerNumber of most likely tokens to return at each token position when logprobs are enabled

Types

2 $defs

ModelOptionsobject

Runtime options that control text generation

seedintegerRandom seed used for reproducible outputs
temperaturenumberControls randomness in generation (higher = more random)format: float
top_kintegerLimits next token selection to the K most likely
top_pnumberCumulative probability threshold for nucleus samplingformat: float
min_pnumberMinimum probability threshold for token selectionformat: float
stopstring | string[]Stop sequences that will halt generation
num_ctxintegerContext length size (number of tokens)
num_predictintegerMaximum number of tokens to generate

ThinkValueboolean | string

Controls a model's thinking output. Use `/api/show` to discover the supported values and default for the selected model. `true` requests thinking, `false` requests no thinking output, and `null` uses the model default. String values are model-defined; supporte…

nullable

Validate a payload

before you spend tokens
shell
$ curl -X POST https://modelschemas.com/v1/validate \
    -d '{"provider":"ollama","endpointId":"api/generate","payload":{…}}'
→ {"valid": false, "errors": [{"path": "#", "keyword": "required", …}]}