{"id":31702341,"url":"https://github.com/whosramoss/google-gemini-colab","last_synced_at":"2025-10-08T21:51:04.489Z","repository":{"id":293997552,"uuid":"985726138","full_name":"whosramoss/google-gemini-colab","owner":"whosramoss","description":"Gemini API Python Integration Project","archived":false,"fork":false,"pushed_at":"2025-09-12T03:10:28.000Z","size":22,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-12T04:01:41.532Z","etag":null,"topics":["agent","chat","colab","gemini","google","python"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/whosramoss.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-05-18T11:57:55.000Z","updated_at":"2025-09-12T03:10:31.000Z","dependencies_parsed_at":"2025-09-12T03:29:31.195Z","dependency_job_id":"b0fed899-1a36-4b11-9e42-7a9f75b5aaca","html_url":"https://github.com/whosramoss/google-gemini-colab","commit_stats":null,"previous_names":["whosramoss/google-gemini-colab"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/whosramoss/google-gemini-colab","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whosramoss%2Fgoogle-gemini-colab","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whosramoss%2Fgoogle-gemini-colab/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whosramoss%2Fgoogle-gemini-colab/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whosramoss%2Fgoogle-gemini-colab/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/whosramoss","download_url":"https://codeload.github.com/whosramoss/google-gemini-colab/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whosramoss%2Fgoogle-gemini-colab/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279000701,"owners_count":26082837,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-08T02:00:06.501Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["agent","chat","colab","gemini","google","python"],"created_at":"2025-10-08T21:51:01.710Z","updated_at":"2025-10-08T21:51:04.477Z","avatar_url":"https://github.com/whosramoss.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cimg width=\"1536\" height=\"469\" alt=\"gemini-wallpaper\" src=\"https://github.com/user-attachments/assets/6fa4b798-81a8-4521-a7b4-e2cb1e9dae9c\" /\u003e\n\n# Google Gemini Colab \n\nThis project demonstrates how to interact with the Google Gemini API using Python. It provides a modular, extensible framework to work with Gemini **Agents**, **Models**, and **Chat** capabilities, allowing developers to build AI-powered applications such as automated content creation pipelines, conversational assistants, and more.\n\n\n\n## Overview\n\nGoogle Gemini is a next-generation large language model (LLM) platform offering diverse AI capabilities. This project provides Python classes and example scripts that connect to Gemini API endpoints, enabling interaction via:\n\n- Specialized **Agents** for task-focused workflows  \n- Raw **Model** completions for flexible generation  \n- Conversational **Chat** sessions supporting multi-turn dialogues  \n\nThe goal is to streamline experimentation, testing, and integration of Gemini AI in your projects.\n\n\n## Features\n\n- **Generalized Agent interface:** Create custom agents with tailored instructions and tools, run multi-step workflows, and manage session lifecycles transparently.  \n- **Model interface:** Direct access to different Gemini models, useful for custom completion tasks and parameter tuning.  \n- **Chat interface:** Build chatbots or assistants that maintain conversational context across interactions.  \n- **Example pipeline:** Automates Instagram post creation via four agents — news search, content planning, writing, and revision.  \n- **Google Search tool integration:** Demonstrates how agents can augment Gemini’s capabilities using external tools.\n\n\n## Project Structure\n\n- **GeminiAgentAssistance**  \n  General-purpose class to interact with Gemini Agents — specialized AI modules performing focused tasks (e.g., research, writing). Manages sessions, runs agents with custom instructions and tools, and returns parsed responses.\n\n- **GeminiModelAssistance**  \n  Class for working directly with Gemini Models, offering a simple interface for generating completions, testing models, and customizing parameters without multi-agent complexity.\n\n- **GeminiChatAssistance**  \n  Encapsulates chat interactions with Gemini, maintaining conversation context for multi-turn dialogues. Ideal for chatbots or interactive assistants.\n\n  - Specialized Agent Classes\n    Concrete classes built upon `GeminiAgentAssistance` for specific use cases, such as:  \n    - `NewsResearcher` (searches latest news using Google Search)  \n    - `PostPlanner` (creates content plans for social media)  \n    - `PostWriter` (writes engaging posts)  \n    - `PostReviewer` (edits and reviews content)\n\n\n## Installation\n\nBefore running the code, install the required Google ADK and Gemini packages:\n\n```bash\n!pip install -q google-adk # to use agents\n!pip install -q google-genai # to use chat or models\n```\n\nEnsure you have your **Google API key** set up securely, for example using Colab secrets:\n\n```python\nimport os\nos.environ[\"GOOGLE_API_KEY\"] = \"\u003cyour_api_key_here\u003e\"\n```\n\n## Usage\n\n1. Clone or download the project files.  \n2. Set your Google API key as an environment variable or in Colab secrets.  \n3. Run the main script to start the content creation workflow.  \n\n\n## Documentation and References\n\n- **Google Gemini API Developer Documentation**  \n  Official Gemini platform documentation, including API reference and guides:  [Link](https://ai.google.dev/gemini-api/docs)\n\n- **Google ADK Python SDK**  \n  Details on the Agent Development Kit (ADK) Python library used in this project:  [Link](https://github.com/google/adk-python)\n\n---\n\n## Contributing\n\nContributions are welcome! Feel free to open issues or submit pull requests to improve features, fix bugs, or enhance documentation.\n\n---\n\n## License \n\nMIT License. [LICENSE](./LICENSE)\n\n## Author \n\nGabriel Ramos ([@whosramoss](https://github.com/whosramoss))\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwhosramoss%2Fgoogle-gemini-colab","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwhosramoss%2Fgoogle-gemini-colab","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwhosramoss%2Fgoogle-gemini-colab/lists"}