Skip to content

Commit

Permalink
Add condition supports_system_message
Browse files Browse the repository at this point in the history
  • Loading branch information
papayalabs committed Nov 18, 2024
1 parent 16725b5 commit 5b5c606
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/services/ai_backend/gemini.rb
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ def set_client_config(config)

@client_config = {
contents: config[:messages],
system_instruction: system_message(config[:instructions])
}
system_instruction: ( system_message(config[:instructions]) if @assistant.language_model.supports_system_message?)
}.compact
end

def get_oneoff_message(instructions, messages, params = {})
Expand Down

0 comments on commit 5b5c606

Please sign in to comment.