Allow Anthropic custom models to override temperature (#18160)
Release Notes: - Allow Anthropic custom models to override "temperature" This also centralized the defaulting of "temperature" to be inside of each model's `into_x` call instead of being sprinkled around the code.
This commit is contained in:
parent
7d62fda5a3
commit
5905fbb9ac
12 changed files with 54 additions and 17 deletions
|
@ -235,7 +235,7 @@ impl OllamaLanguageModel {
|
|||
options: Some(ChatOptions {
|
||||
num_ctx: Some(self.model.max_tokens),
|
||||
stop: Some(request.stop),
|
||||
temperature: Some(request.temperature),
|
||||
temperature: request.temperature.or(Some(1.0)),
|
||||
..Default::default()
|
||||
}),
|
||||
tools: vec![],
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue