GemCLI: Use consumer Gemini for unlimited code completions, system automation, and image generation via command-line interface
Project description
GemCLI - Consumer Gemini AI for Code Completions, System Automation, and Image Generation
A professional Python command-line interface that leverages Google's consumer Gemini AI for unlimited code completions, autonomous file operations, system automation, and AI image generation - all directly from your terminal.
GemCLI provides a high-fidelity terminal experience with real-time markdown rendering, customizable themes, and browser-based authentication.
NEW FEATURE: AutoBot Mode GemCLI now includes AutoBot, a fully autonomous agent system capable of planning and executing multi-step tasks. AutoBot can navigate your filesystem, create complex project structures, and manage dependencies without constant manual intervention.
PRIVACY & SECURITY This is a CLIENT-SIDE application with NO SERVER component. Your data remains on YOUR machine. All processing is local. Session tokens never leave your system.
Key Features
- AutoBot Autonomous System: Advanced multi-step task execution and project bootstrapping.
- Modern Terminal Interface: Built with Rich library for beautiful, responsive command-line experience
- Four Operating Modes: Chat, System Agent (AI Coding Assistant), AutoBot (Autonomous), and Image Generation
- Browser Cookie Authentication: Automatic session extraction from Chrome, Edge, or Firefox - no API key needed
- File Operations: Read, edit, search, and create files through AI commands in Agent modes
- System Command Execution: Control system operations - open applications, adjust brightness/volume, launch file explorer, manage media playback
- Git Integration: Automatic commit, push, and AI-generated commit messages for version control
- Diff Viewer: Preview code changes before applying with VS Code or terminal-based diff view
- Six Theme Profiles: Customize with Cyan, Pink, Gold, Green, Purple, or White color schemes
- Asynchronous Architecture: Non-blocking API communication built on asyncio
- Complete Privacy: Client-side only - your session tokens never leave your local machine
Modes & Capabilities
GemCLI offers four distinct operating modes, each tailored for specific use cases:
| Mode | Ask/Response | Read Files | Edit Files | Workspace Search | Autonomous | System Cmds |
|---|---|---|---|---|---|---|
| Chat | Yes | No | No | No | No | No |
| System Agent | Yes | Yes | Yes | No | No | Yes |
| AutoBot | Yes | Yes | Yes | Yes | Yes | Yes |
| Image Gen | Yes | No | No | No | No | No |
Mode Descriptions
AutoBot Mode (Autonomous Agent)
Our flagship autonomous coding assistant. AutoBot can:
- Search your entire workspace for relevant files
- Read any files it determines necessary
- Make coordinated changes across multiple files
- Work independently to solve complex, multi-step prompts
- Execute system commands and manage project lifecycles
Chat Mode
Basic conversational AI interface. Ask questions, receive answers, and engage in natural conversations with Gemini.
System Agent Mode (AI Coding Assistant)
Enhanced mode where you specify files to work with. Gemini can suggest code modifications and apply changes with your approval.
Image Generation Mode
Create AI-generated images from text descriptions with customizable save locations.
Installation
Option 1: Install from PyPI (Recommended)
pip install gemcli
Option 2: Install from GitHub
pip install git+https://github.com/Aniketh78/Gemini-Terminal-Tool-GEM-CLI.git
Option 3: Install from Source
git clone https://github.com/Aniketh78/Gemini-Terminal-Tool-GEM-CLI.git
cd Gemini-Terminal-Tool-GEM-CLI
pip install .
Option 4: Development Mode
git clone https://github.com/Aniketh78/Gemini-Terminal-Tool-GEM-CLI.git
cd Gemini-Terminal-Tool-GEM-CLI
pip install -e .
Requirements
- Python 3.8 or higher
- Git (optional, for git integration features)
- VS Code (optional, for diff previews)
Quick Start
After installation, run GemCLI using:
gemcli
Authentication Setup (Cookie-Based)
GemCLI uses browser cookie authentication to connect to Google Gemini. No API key required!
Step-by-Step Cookie Setup
- Open Google Gemini - Visit gemini.google.com in your browser
- Log in to your Google account
- Open Developer Tools - Press
F12(or right-click > "Inspect") - Navigate to Cookies:
- Go to the Application tab (Chrome/Edge) or Storage tab (Firefox)
- Expand Cookies in the sidebar
- Click on
https://gemini.google.com
- Find and copy these cookies:
__Secure-1PSID(required)__Secure-1PSIDTS(optional, but recommended)
- Paste into GemCLI when prompted on first run
Is This Safe?
Yes, absolutely! Here's why:
| Concern | Answer |
|---|---|
| Where are cookies stored? | Locally in .gemini_cookies.json in your working directory |
| Do cookies leave my machine? | NO - They are only sent directly to Google's Gemini servers |
| Is there a server component? | NO - This is 100% client-side |
| Can anyone see my cookies? | Only you - the file stays on your local machine |
| Should I share my cookies? | NEVER share your cookies with anyone |
Important: Treat your cookies like passwords. Never commit
.gemini_cookies.jsonto version control (it's already in.gitignore).
Running GemCLI
First Run
- Run
gemcliin your terminal - When prompted, paste your cookie values (see Authentication Setup above)
- Select your desired mode from the menu
- Start chatting!
Subsequent Runs
GemCLI remembers your cookies, so just run:
gemcli
And you'll be asked if you want to use saved cookies or enter new ones.
Usage & Commands
All Modes
| Command | Description |
|---|---|
/exit |
Exit the application |
/clear |
Clear the terminal screen |
/mode |
Switch between operating modes |
System Agent Mode
Git Integration:
| Command | Description |
|---|---|
/status |
Show git status and current branch |
/commit |
AI-generated commit with confirmation |
/push |
Push commits to remote repository |
File Operations:
| Command | Description |
|---|---|
/path/to/file.py |
Read and include file in AI context |
Example Workflows
Ask AI to modify code:
You: /gemini_cli.py add a new feature to handle user authentication
AI reads the file, suggests changes, opens diff preview, you accept/reject
Git with AI commit messages:
You: /commit
AI analyzes your changes and generates a smart commit message
Generate images:
You: Create a beautiful sunset over mountains with vibrant colors
AI generates and saves the image to your configured directory
Configuration
Access settings from the main menu:
| Setting | Description |
|---|---|
| Git Settings | Configure commit timing, auto-push, branch selection |
| Customize Theme | Choose from Cyan, Pink, Gold, Green, Purple, or White |
| Image Settings | Set save directory for generated images |
Uninstall
To remove GemCLI:
pip uninstall gemcli
License
This project is licensed under the MIT License - see the LICENSE file for details.
Support
- Report bugs: GitHub Issues
- Discussions: GitHub Discussions
Made by 89P13
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gemcli-1.0.9.tar.gz.
File metadata
- Download URL: gemcli-1.0.9.tar.gz
- Upload date:
- Size: 43.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
aea5d3020753d4b2724bb36fcb61f1495889ec8d8cae9b3ea6fb0ad292106ab8
|
|
| MD5 |
7fc3a4210159bdffd37d610246a0349e
|
|
| BLAKE2b-256 |
284b12d5725512956a3fb5a6df6524d703189c4108e1b22cb3af20b74810b73a
|
File details
Details for the file gemcli-1.0.9-py3-none-any.whl.
File metadata
- Download URL: gemcli-1.0.9-py3-none-any.whl
- Upload date:
- Size: 34.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6d1f93d8bf5b8af2b92e43acfd54766a25762f27258deadf8717aa02a5dc2a58
|
|
| MD5 |
02eded2e4e5caa78cd45bd991b1e6f6e
|
|
| BLAKE2b-256 |
78968828cb3a0f3b963385e63b63f0f58c37dc161c2f33026f7c1531cfa9fdec
|