Samples for DeepMind Gemini models
Top 36.9% on sourcepulse
This repository provides a collection of practical code samples, snippets, and guides for utilizing Google DeepMind's Gemini models. It targets developers and researchers looking to explore and implement advanced AI functionalities like function calling, structured outputs, and multimodal interactions with Gemini. The primary benefit is a readily accessible set of examples to accelerate development and experimentation with these powerful models.
How It Works
The repository showcases Gemini's capabilities through various implementations, including direct API calls, integration with popular frameworks like LangChain and LangGraph, and leveraging SDKs like the OpenAI SDK. It demonstrates techniques for structured data generation using Pydantic, dynamic schema creation via meta-prompts, and multimodal features such as audio transcription and native image generation. The examples highlight efficient use cases, including context caching for cost savings and integrating Google Search for real-time information.
Quick Start & Requirements
git clone https://github.com/philschmid/gemini-samples.git
) and explore the Jupyter notebooks or Python scripts..env
file as GEMINI_API_KEY=your_api_key_here
. Specific examples may have additional dependencies managed by their respective notebooks or scripts.Highlighted Details
Maintenance & Community
The repository is maintained by philschmid. Contributions are welcome via pull requests or issues.
Licensing & Compatibility
Limitations & Caveats
Some examples, such as Gemini 2.0 Flash, are experimental. The repository contains personal snippets and may not represent official Google documentation or support.
2 days ago
Inactive