🌐
PyPI
pypi.org › project › google-genai
google-genai · PyPI
2 weeks ago - The following example shows how to declare a function and pass it as a tool. Then you will receive a function call part in the response. from google.genai import types function = types.FunctionDeclaration( name='get_current_weather', description='Get the current weather in a given location', parameters_json_schema={ 'type': 'object', 'properties': { 'location': { 'type': 'string', 'description': 'The city and state, e.g.
      » pip install google-genai
    
Published   Jun 24, 2026
Version   2.10.0
🌐
PyPI
pypi.org › project › google-generativeai
google-generativeai · PyPI
With Gemini 2.0, we took the chance to create a single unified SDK for all developers who want to use Google's GenAI models (Gemini, Veo, Imagen, etc).
      » pip install google-generativeai
    
Published   Dec 16, 2025
Version   0.8.6
🌐
GitHub
github.com › googleapis › python-genai
GitHub - googleapis/python-genai: Google Gen AI Python SDK provides an interface for developers to integrate Google's generative models into their Python applications. · GitHub
1 month ago - The following example shows how to declare a function and pass it as a tool. Then you will receive a function call part in the response. from google.genai import types function = types.FunctionDeclaration( name='get_current_weather', description='Get the current weather in a given location', parameters_json_schema={ 'type': 'object', 'properties': { 'location': { 'type': 'string', 'description': 'The city and state, e.g.
Starred by 3.8K users
Forked by 929 users
Languages   Python
🌐
Google
docs.cloud.google.com › gemini enterprise agent platform › google gen ai sdk
Google Gen AI SDK | Gemini Enterprise Agent Platform | Google Cloud Documentation
1 month ago - from google import genai # TODO(developer): Update below line API_KEY = "YOUR_API_KEY" client = genai.Client(vertexai=True, api_key=API_KEY) response = client.models.generate_content( model="gemini-3.5-flash", contents="Explain bubble sort to me.", ) print(response.text) # Example response: # Bubble Sort is a simple sorting algorithm that repeatedly steps through the list
🌐
GitHub
github.com › google-gemini › genai-processors
GitHub - google-gemini/genai-processors: GenAI Processors is a lightweight Python library that enables efficient, parallel content processing. · GitHub
Build Modular, Asynchronous, and Composable AI Pipelines for Generative AI. GenAI Processors is a lightweight Python library that enables efficient, parallel content processing.
Starred by 2.1K users
Forked by 215 users
Languages   Python 77.7% | Jupyter Notebook 14.0% | HTML 8.3%
🌐
GitHub
googleapis.github.io › python-genai
Google Gen AI SDK documentation
Google Gen AI Python SDK provides an interface for developers to integrate Google’s generative models into their Python applications. It supports the Gemini Developer API and Vertex AI APIs. ... Please run one of the following code blocks to create a client for different services (Gemini Developer API or Vertex AI). from google import genai # Only run this block for Gemini Developer API client = genai.Client(api_key='GEMINI_API_KEY')
🌐
Google AI
ai.google.dev › gemini api › gemini api libraries
Gemini API libraries | Google AI for Developers
April 28, 2026 - The Google GenAI SDK is available for the Python, JavaScript/TypeScript, Go and Java languages.
🌐
Google AI
ai.google.dev › gemini api › getting started with gemini api
Getting started with Gemini API | Google AI for Developers
2 weeks ago - from google import genai client = genai.Client() interaction = client.interactions.create( agent="antigravity-preview-05-2026", input="Write a Python script that generates the first 20 Fibonacci numbers and saves them to fibonacci.txt.
Find elsewhere
🌐
GitHub
github.com › googleapis › python-genai › blob › main › codegen_instructions.md
python-genai/codegen_instructions.md at main · googleapis/python-genai
Installation: Incorrect: pip install google-generativeai · Incorrect: pip install google-ai-generativelanguage · Correct: pip install google-genai · APIs and Usage: Incorrect: import google.generativeai as genai-> Correct: from google import ...
Author   googleapis
🌐
Analytics Vidhya
analyticsvidhya.com › home › google gen ai python sdk: a complete guide
Google Gen AI Python SDK: A Complete Guide
August 17, 2025 - If you want to use the SDK asynchronously, run pip install google-genai[aiohttp].
🌐
Chatting With Models
chattingwithmodels.wordpress.com › 2025 › 04 › 06 › a-beginners-guide-to-the-google-gen-ai-sdk-for-python
A Beginner’s Guide to the Google Gen AI SDK for Python
April 6, 2025 - Once the terminal is open, the following command should be executed: pip install google-genai.2 It is generally recommended to include the -U flag with this command, especially if the SDK might have been installed previously.
🌐
GitHub
github.com › google-gemini › generative-ai-python › blob › main › docs › api › google › generativeai.md
deprecated-generative-ai-python/docs/api/google/generativeai.md at main · google-gemini/deprecated-generative-ai-python
Google AI Python SDK · pip install google-generativeai · Use genai.GenerativeModel to access the API: import google.generativeai as genai import os genai.configure(api_key=os.environ['API_KEY']) model = genai.GenerativeModel(model_name='g...
Author   google-gemini
🌐
Google AI
ai.google.dev › gemini api › migrate to the google genai sdk
Migrate to the Google GenAI SDK | Gemini API | Google AI for Developers
April 28, 2026 - #pip install https://github.com/google-gemini/generative-ai-python@imagen import google.generativeai as genai imagen = genai.ImageGenerationModel( "imagen-3.0-generate-001") gen_images = imagen.generate_images( prompt="Robot holding a red skateboard", number_of_images=1, safety_filter_level="block_low_and_above", person_generation="allow_adult", aspect_ratio="3:4", ) After ·
🌐
Priyanshu
priyanshu.com.np › home › how to set up and use google generative ai in python
How to Set Up and Use Google Generative AI in Python - Priyanshu
July 11, 2024 - First, you need to install the necessary Python packages. Open your terminal or command prompt and run the following commands: pip install google-generativeai pip install python-dotenv
🌐
Google Cloud
cloud.google.com › python › client libraries › vertex generative ai sdk for python
Vertex Generative AI SDK for Python | Python client libraries | Google Cloud Documentation
import types from google.genai import types as genai_types prompt = types.Prompt( prompt_data=types.PromptData( contents=[genai_types.Content(parts=[genai_types.Part(text="Hello, {name}! How are you?")])], system_instruction=genai_types.Content(parts=[genai_types.Part(text="Please answer in a short sentence.")]), variables=[ {"name": genai_types.Part(text="Alice")}, ], model="gemini-2.5-flash", ), )
🌐
Llamaindex
developers.llamaindex.ai › python › examples › llm › google_genai
Google GenAI | Developer Documentation
If you’re opening this Notebook on colab, you will need to install LlamaIndex 🦙 and the google-genai Python SDK. %pip install llama-index-llms-google-genai llama-index
🌐
Medium
koshurai.medium.com › full-tutorial-how-to-use-google-generative-ai-for-text-and-image-content-creation-in-python-ad5c43c1c761
Full Tutorial: How to Use Google Generative AI for Text and Image Content Creation in Python | by KoshurAI | Medium
September 8, 2024 - Run the following command to install the required libraries. # Install Google Generative AI library !pip install -U google-generativeai # Import required libraries import google.generativeai as genai import os
🌐
Medium
medium.com › @kggopi666 › genai-processors-by-google-how-this-new-library-makes-real-time-ai-apps-super-easy-4682a699a16c
GenAI Processors by Google: How This New Library Makes Real-Time AI Apps Super Easy! | by Govindhasamy | Medium
July 11, 2025 - You can install it like any other Python library via pip: pip install genai-processors · Or, if you prefer the GitHub version: git clone https://github.com/google-gemini/genai-processors.git cd genai-processors pip install -e . This gives you ...
🌐
PyPI
pypi.org › project › genai
genai · PyPI
🌍 Supports all Jupyter environments, including IPython, JupyterLab, Jupyter Notebook, and Noteable. TL;DR Get started now · %pip install genai %load_ext genai · Blog Post · Example Notebook ·
      » pip install genai
    
Published   Jul 21, 2023
Version   2.1.0