Skip to content

Commit

Permalink
Merge pull request #1 from anthony-robin/fix-safe-mode
Browse files Browse the repository at this point in the history
Replace `safe_mode` by `safe_prompt`
  • Loading branch information
fsndzomga authored Jan 12, 2024
2 parents f2cb67f + d528c6c commit 188bb60
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/mistral_rb.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@ def initialize(api_key: ENV["MISTRAL_API_KEY"], base_uri: "https://api.mistral.a
self.class.base_uri base_uri
end

def create_chat_completion(model:, messages:, temperature: 0.7, top_p: 1, max_tokens: nil, stream: false, safe_mode: false, random_seed: nil)
def create_chat_completion(model:, messages:, temperature: 0.7, top_p: 1, max_tokens: nil, stream: false, safe_prompt: false, random_seed: nil)
body = {
model: model,
messages: messages,
temperature: temperature,
top_p: top_p,
max_tokens: max_tokens,
stream: stream,
safe_mode: safe_mode,
safe_prompt: safe_prompt,
random_seed: random_seed
}.compact.to_json

Expand Down

0 comments on commit 188bb60

Please sign in to comment.