ChatRequest
Defined in: src/lib/providers/types.ts:101
Properties
Section titled “Properties”keep_alive?
Section titled “keep_alive?”
optionalkeep_alive?:string|number
Defined in: src/lib/providers/types.ts:117
max_tokens?
Section titled “max_tokens?”
optionalmax_tokens?:number
Defined in: src/lib/providers/types.ts:118
messages
Section titled “messages”messages:
ChatMessage[]
Defined in: src/lib/providers/types.ts:103
min_p?
Section titled “min_p?”
optionalmin_p?:number
Defined in: src/lib/providers/types.ts:112
model:
string
Defined in: src/lib/providers/types.ts:102
num_batch?
Section titled “num_batch?”
optionalnum_batch?:number
Defined in: src/lib/providers/types.ts:116
num_ctx?
Section titled “num_ctx?”
optionalnum_ctx?:number
Defined in: src/lib/providers/types.ts:110
num_gpu?
Section titled “num_gpu?”
optionalnum_gpu?:number
Defined in: src/lib/providers/types.ts:115
num_predict?
Section titled “num_predict?”
optionalnum_predict?:number
Defined in: src/lib/providers/types.ts:111
num_thread?
Section titled “num_thread?”
optionalnum_thread?:number
Defined in: src/lib/providers/types.ts:114
reasoningEffort?
Section titled “reasoningEffort?”
optionalreasoningEffort?:ReasoningEffort
Defined in: src/lib/providers/types.ts:126
Provider-neutral user-selected reasoning control. auto is omitted.
repeat_last_n?
Section titled “repeat_last_n?”
optionalrepeat_last_n?:number
Defined in: src/lib/providers/types.ts:108
repeat_penalty?
Section titled “repeat_penalty?”
optionalrepeat_penalty?:number
Defined in: src/lib/providers/types.ts:107
optionalseed?:number
Defined in: src/lib/providers/types.ts:109
optionalstop?:string[]
Defined in: src/lib/providers/types.ts:113
stream?
Section titled “stream?”
optionalstream?:boolean
Defined in: src/lib/providers/types.ts:119
temperature?
Section titled “temperature?”
optionaltemperature?:number
Defined in: src/lib/providers/types.ts:104
think?
Section titled “think?”
optionalthink?:boolean|"medium"|"high"|"max"|"low"
Defined in: src/lib/providers/types.ts:124
Ollama thinking toggle. Used for short internal utility calls where hidden reasoning would waste time and never be shown to the user.
tool_choice?
Section titled “tool_choice?”
optionaltool_choice?:"required"|"none"|"auto"
Defined in: src/lib/providers/types.ts:141
Tool-call policy. “none” forbids new tool calls while keeping the tools
array in the payload, so strict OpenAI-compatible endpoints that reject a
message history with tool turns but no tools field do not 400. Used by the
synthesis pass after the tool loop hits its iteration cap. Ollama has no such
param, so its adapter expresses “none” by omitting tools (it accepts tool
history without them).
tools?
Section titled “tools?”
optionaltools?:ToolDefinition[]
Defined in: src/lib/providers/types.ts:132
Tool definitions offered to the model. Only set for tool-capable models
(gated on resolved toolCalling); when absent the request is identical to
the pre-tool-calling wire shape, so non-tool models are unaffected.
top_k?
Section titled “top_k?”
optionaltop_k?:number
Defined in: src/lib/providers/types.ts:106
top_p?
Section titled “top_p?”
optionaltop_p?:number
Defined in: src/lib/providers/types.ts:105