add: Google-genai for Gemini models#58
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR adds support for Google-genai for Gemini models by updating model configurations and refactoring related functions across multiple modules. Key changes include renaming and parameter adjustments in the Ollama and Gemini model functions, updating dependency versions in the project configuration, and modifying the main experiment logic to integrate new model interfaces.
Reviewed Changes
Copilot reviewed 10 out of 11 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/experiment_ollama.py | Removed seed/temperature parameters and renamed get_model to get_ollama_model. |
| src/experiment.py | Updated model lists and function calls to incorporate new Gemini model variants. |
| src/common.py | Adjusted get_prompt function by removing the full_type flag and related logic. |
| main.py | Updated model assertions and client initializations to support Google-genai. |
| pyproject.toml | Bumped dependency versions for google-genai, openai, and ollama. |
| scripts/result_token_stat.py | Added script for token count statistics. |
| README.md | Updated script commands for consistency. |
| src/init.py | Configured logging levels for openai and httpx modules. |
Files not reviewed (1)
- .envrc: Language not supported
Comments suppressed due to low confidence (1)
main.py:91
- There is an inconsistency between the environment variable checked ('OPENAI_API_KEY') and the error message stating 'OPEN_API_KEY'. Consider aligning the error message with the actual variable name.
assert "OPENAI_API_KEY" in os.environ, "Please set OPEN_API_KEY in environment!"
|
|
||
|
|
||
| def get_model( | ||
| def get_ollama_model( |
There was a problem hiding this comment.
The function's docstring still mentions 'seed' and 'temperature' parameters which have been removed from the signature. Please update the documentation to reflect the current function parameters.
No description provided.