Skip to content

Conversation

@common-guid
Copy link

added gemini api support and a cli flag to select between oai and gemini

google-labs-jules bot and others added 4 commits September 17, 2025 03:58
This commit adds the ability to use Google's Gemini model as an alternative to OpenAI's model.

The changes include:
- A new `models/gemini.go` file to handle the interaction with the Gemini API.
- A new `--model` flag to allow the user to select between `openai` and `gemini`.
- A `Model` interface in `cli/cli.go` to abstract the model implementation.
- The necessary dependency updates in `go.mod` and `go.sum`.
Modified the Gemini model to exclusively load the GEMINI_API_KEY from a
.env file in the current working directory. This change prevents the
application from using any other API key found on the system.

The key loading logic is now centralized in `models/gemini.go`, which
uses `godotenv.Read()` to read the local `.env` file. If the file or
the key is not found, the application will return a descriptive error.

Redundant .env loading code was removed from `cli/cli.go` to avoid
conflicts and streamline the configuration.
feat: Use local .env for Gemini API key
changed from pro to flash
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant