A command-line interface to interact with Google's AI Mode
Project description
GTalk - Google AI Mode Terminal Query Tool
A powerful command-line interface to interact with Google's AI Mode directly from your terminal. Get AI-powered context aware answers, code examples, and explanations without leaving your command line!
Features
- Interactive Mode - Keep querying without restarting
- Context Aware - Context aware subsequent query in interactive mode
- Code Block Support - Properly formatted code examples
- Fast - Browser session reused across queries
- Clean Output - Well-formatted, readable responses
- Both Modes - Interactive or single-query mode
Installation
From PyPI (Recommended)
pip install gtalk
From Source (Latest Features + Bugfixes)
git clone https://github.com/hissain/gtalk.git
cd gtalk
pip install -e .
Quick Start
Interactive Mode
Simply run:
gtalk
Then start asking questions:
Query> Who is Elon Musk?
Query> How many children he has?
Query> Write a python code for printing first 10 Fibonacci numbers?
Query> quit
Demo Terminal
Single Query Mode
gtalk "What is machine learning?"
Usage Examples
Getting Code Examples
Query> Write a Python function for bubble sort
Output includes both explanation and code:
def bubble_sort(arr):
n = len(arr)
for i in range(n):
for j in range(0, n-i-1):
if arr[j] > arr[j+1]:
arr[j], arr[j+1] = arr[j+1], arr[j]
return arr
Learning Concepts
Query> Explain binary trees
Query> What is the difference between TCP and UDP?
Query> How does async/await work in JavaScript?
Quick References
Query> Git command to undo last commit
Query> Python list comprehension syntax
Query> Docker commands cheat sheet
Interactive Commands
Once in interactive mode:
| Command | Description |
|---|---|
[any text] |
Query Google AI Mode |
help |
Show available commands |
clear |
Clear the screen |
quit, exit, q |
Exit the program |
Ctrl+C |
Force exit |
Ctrl+D |
Alternative exit |
Configuration
GTalk uses headless Chrome by default. The browser session is reused across queries for better performance.
Troubleshooting
CAPTCHA Detected
If you see "Google has detected automated access":
- Wait a few minutes between queries
- Use a VPN or different network
- Reduce query frequency
No Summary Found
If no AI summary is returned:
- Try rephrasing your query
- Use question format: "What is...", "How to...", "Explain..."
- Some queries may not trigger AI Mode
Privacy & Rate Limiting
- GTalk makes direct requests to Google
- No data is stored or logged by this tool
- Respect Google's rate limits - avoid excessive automated queries
- Consider delays between queries if using programmatically
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
License
This project is licensed under the MIT License - see the LICENSE file for details.
Disclaimer
This tool is for educational and personal use only. It interacts with Google Search's public interface. Please use responsibly and in accordance with Google's Terms of Service.
Acknowledgments
- Built with Selenium
- Parsing powered by Beautiful Soup
- Inspired by the need for quick terminal-based AI assistance
Contact & Support
- Author: Md. Sazzad Hissain Khan
- Email: hissain.khan@gmail.com
- GitHub: @hissain
- Issues: GitHub Issues
Made with love by Md. Sazzad Hissain Khan
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 gtalk-1.0.2.tar.gz.
File metadata
- Download URL: gtalk-1.0.2.tar.gz
- Upload date:
- Size: 8.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d691b43240a73c5a4b2610593c67402bf077b7bb2664b3d0a270f720282798b5
|
|
| MD5 |
b4e921180f839e8d66a92e76e980dc53
|
|
| BLAKE2b-256 |
c54ce7535f50d7d771b83d0d4f754120627cb0b436c5071c5b37bdc17f8645f5
|
File details
Details for the file gtalk-1.0.2-py3-none-any.whl.
File metadata
- Download URL: gtalk-1.0.2-py3-none-any.whl
- Upload date:
- Size: 8.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
21652f9cf546fcf3ed7c8cb42637d612e34dd70d0d97f9aba67d415b0e990ab4
|
|
| MD5 |
2567653ed69ed35a363c536005cfcdad
|
|
| BLAKE2b-256 |
3571da3c64fe2cfe59a8ab871e55dfe224c04c1fb81aa09efc5693125a82a67e
|