Interface ThinkOption
- All Known Implementing Classes:
ThinkOption.ThinkBoolean,ThinkOption.ThinkLevel
Represents the thinking option for Ollama models. The think option controls whether
models emit their reasoning trace before the final answer.
Most models (Qwen 3, DeepSeek-v3.1, DeepSeek R1) accept boolean enable/disable. The GPT-OSS model requires string levels: "low", "medium", or "high".
- Since:
- 1.1.0
- Author:
- Mark Pollack
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final recordBoolean-style think option for models that support simple enable/disable.static final recordString-level think option for the GPT-OSS model which requires explicit levels.static classDeserializer that reads boolean or string values into ThinkOption instances.static classSerializer that writes ThinkOption as raw boolean or string values. -
Method Summary
Modifier and TypeMethodDescriptionConverts this think option to its JSON representation.
-
Method Details
-
toJsonValue
Object toJsonValue()Converts this think option to its JSON representation.- Returns:
- the JSON value (Boolean or String)
-