module RubyLLM::Providers::Gemini::Capabilities

def supports_json_mode?(model_id)

Returns:
  • (Boolean) - true if the model supports JSON mode

Parameters:
  • model_id (String) -- the model identifier
def supports_json_mode?(model_id)
  if model_id.match?(/text-embedding|embedding-001|aqa|imagen|gemini-2\.0-flash-lite|gemini-2\.5-pro-exp-03-25/)
    return false
  end
  model_id.match?(/gemini|pro|flash/)
end