0

google-aistudio-gemini (Gemini and Gemma)

Compare Gemini and Gemma on the same arithmetic question. The Gemini configuration loads a system instruction from a file. Both answers are graded locally against the expected number.

Example · مثالgemini

Content

google-aistudio-gemini (Gemini and Gemma)

Compare Gemini and Gemma on the same arithmetic question. The Gemini configuration loads a system instruction from a file. Both answers are graded locally against the expected number.

Run the eval

Set GOOGLE_API_KEY or GEMINI_API_KEY to a Gemini API key, then run:

npx promptfoo@latest init --example google-aistudio-gemini
cd google-aistudio-gemini
npx promptfoo@latest eval

To compare the two bundled photos, run npx promptfoo@latest eval -c promptfooconfig.image.yaml.

To try other models, change the provider IDs and check which APIs they support. Gemini models · Hosted Gemma models

Source and license

Source
Promptfoo
Original
promptfoo/promptfoo/examples/google-aistudio-gemini
License
MIT