Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add Max Tokens and Context Window Setting Options for Ollama Channel #1694

Merged
merged 9 commits into from
Aug 6, 2024
Prev Previous commit
Next Next commit
Added num_ctx param for ollama adapter
MotorBottle authored Jul 26, 2024
commit c834f8383563856609ca864f705800f687810484
3 changes: 2 additions & 1 deletion relay/adaptor/ollama/main.go
Original file line number Diff line number Diff line change
@@ -31,7 +31,8 @@ func ConvertRequest(request model.GeneralOpenAIRequest) *ChatRequest {
TopP: request.TopP,
FrequencyPenalty: request.FrequencyPenalty,
PresencePenalty: request.PresencePenalty,
NumPredict: request.MaxTokens,
NumPredict: request.MaxTokens,
NumCtx: request.NumCtx,
},
Stream: request.Stream,
}