Ollama max_tokens settings (#17025)
- Support `available_models` for Ollama - Clamp default max tokens (context length) to 16384. - Add documentation for ollama context configuration.
This commit is contained in:
parent
d401ab1efc
commit
b62e63349b
5 changed files with 92 additions and 35 deletions
|
@ -135,6 +135,7 @@ impl AssistantSettingsContent {
|
|||
Some(language_model::settings::OllamaSettingsContent {
|
||||
api_url,
|
||||
low_speed_timeout_in_seconds,
|
||||
available_models: None,
|
||||
});
|
||||
}
|
||||
},
|
||||
|
@ -295,7 +296,7 @@ impl AssistantSettingsContent {
|
|||
_ => (None, None),
|
||||
};
|
||||
settings.provider = Some(AssistantProviderContentV1::Ollama {
|
||||
default_model: Some(ollama::Model::new(&model)),
|
||||
default_model: Some(ollama::Model::new(&model, None, None)),
|
||||
api_url,
|
||||
low_speed_timeout_in_seconds,
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue