This is a simple command-line chat interface for the Google Gemini-Pro model. The script is designed to be straightforward and easy to extend upon. The app runs in the command line, but it can be easily adapted to work with a GUI or web interface. The intention for this is an easy copy / paste code template that can be added to any repo for a command line pair programmer or assistant. There are 2 alternate variations of the chat assistant - 1 has access to howdoi and 1 has access to wikipedia.
- Python 3.11+
- Internet connection
- Google Gemini API key
Before running the application, ensure you have a .env
file in the project directory with your Google Gemini API key:
GOOGLE_GEMINI_API_KEY=your_api_key_here
- Clone this repository or copy the source code.
- Install the required dependencies by running
pip install -r requirements.txt
in your terminal.
To start the chat interface, run the provided Python script from your terminal:
python chat_interface.py
Upon launching, the interface will prompt you for input. The prompt template can be customized and tools can be added.
To end the chat session, type any of the exit commands (exit
, quit
, stop
, end
, bye
, goodbye
, done
, break
).
This application is designed for educational purposes only. Please ensure you comply with Google's API usage policies and guidelines.
For issues and inquiries, please refer to the Google Gemini-Pro documentation or open an issue in this repository.