cookbook README

The project's README from github.com/google-gemini/cookbook. As one markdown file: README.md.

Welcome to the Gemini API Cookbook

This cookbook provides a structured learning path for using the Gemini API, focusing on hands-on tutorials and practical examples.

For comprehensive API documentation, visit ai.google.dev.

For Gemma quickstarts and examples, check out the Gemma cookbook.


Gemini 3.8 Flash: Our most intelligent Flash model, engineered for long-horizon software engineering, autonomous agents, and complex enterprise workflows. Get started with the Get Started Colab and the thinking Colab guides.

Omni Flash: The Nano Banana of video editing is here! Learn how to call the model using the interactions API, edit videos with natural language and more here Colab!

🍌 Nano-Banana 2: Go bananas with our latest image generation model: Nano-Banana 2. Get started here Colab with 512px, thinking, search and image grounding, and a ton of examples!

🎶 Lyria 3.5: Channel your inner composer with Lyria 3.5. Get started here Colab with full song generation, image-to-music, and a ton of examples!

Agents API: Create and run your custom agents using the new Antigravity agent Colab!


Navigating the Cookbook

This cookbook is organized into two main categories:

  1. Quick Starts: Step-by-step guides covering both introductory topics ("Get Started Colab") and specific API features.
  2. Examples: Practical use cases demonstrating how to combine multiple features.

We also showcase Demos in separate repositories, illustrating end-to-end applications of the Gemini API.

What's New?

Here are the recent additions and updates to the Gemini API and the Cookbook:



1. Quick Starts

The quickstarts section contains step-by-step tutorials to get you started with Gemini and learn about its specific features.

To begin, you'll need:

  1. A Google account.
  2. An API key (create one in Google AI Studio).



We recommend starting with the following:



Then, explore the other quickstarts tutorials to learn about individual features:



2. Examples (Practical Use Cases)

These examples demonstrate how to combine multiple Gemini API features or 3rd-party tools to build more complex applications.



3. Demos (End-to-End Applications)

These fully functional, end-to-end applications showcase the power of Gemini in real-world scenarios.



Official SDKs

The Gemini API is a REST API. You can call it directly using tools like curl (see REST examples or the great Postman workspace), or use one of our official SDKs:



Get Help

Ask a question on the Google AI Developer Forum.

The Gemini API on Google Cloud Vertex AI

For enterprise developers, the Gemini API is also available on Google Cloud Vertex AI. See this repo for examples.

Contributing

Contributions are welcome! See CONTRIBUTING.md for details.

Thank you for developing with the Gemini API! We're excited to see what you create.

cookbook (google-gemini/cookbook)

Searching Database…

17.8K ·GitHub
Что это такое?Официальное руководство от Google по работе с Gemini API: структурированный учебный маршрут из практических уроков, рабочих примеров и ссылок на полноценные демо-приложения, опубликованный в виде открытой коллекции ноутбуков.
Это библиотека, которую нужно установить, или что-то другое?Ни то, ни другое — это коллекция Jupyter-ноутбуков, разделённая на Quick Starts (пошаговые руководства по возможностям API) и Examples (сценарии использования, где сочетаются сразу несколько возможностей), а демо вынесены в отдельные репозитории.
Что нужно подготовить, прежде чем что-то запускать?Нужны только учётная запись Google и API-ключ, созданный в Google AI Studio. Рекомендуемый путь: сначала вводное руководство Authentication quickstart, чтобы подключить ключ, а затем ноутбук Get Started про базовые запросы и мультимодальный ввод.
Обязательно писать на Python или есть SDK для других языков?API работает по REST, так что подойдёт даже обычный curl, а ещё есть официальные SDK для Python, Go, Node.js, Java и C#. Сами ноутбуки этого руководства написаны на Python.
Это для энтузиастов-экспериментаторов или для корпоративных команд?Для тех и других: частные разработчики могут взять ключ в Google AI Studio и пройти вводные руководства, а корпоративные разработчики могут использовать тот же Gemini API через Google Cloud Vertex AI — примеры для этого есть в отдельном репозитории.
Какие модели и возможности охватывает руководство на данный момент?Оно следит за свежими релизами Gemini: 3.8 Flash для долгих задач по кодингу и агентов, 3.5 Flash-Lite для высокой пропускной способности, Omni Flash для диалоговой генерации и редактирования видео, Nano Banana 2 и Pro для генерации изображений вплоть до 4K, Lyria 3.5 для создания песен и Gemini Transcribe для расшифровки аудио.
Какие примеры проектов там есть?Раздел Examples показывает сочетания разных возможностей: браузер как инструмент для работы с вебом в реальном времени, иллюстрации для открытой книги, анимированные истории на основе генерации сюжета, Imagen и синтеза звука, живые графики и карты, понимание 3D-сцен, а также оценка расходов и мониторинг состояния при использовании API.
Есть ли готовые приложения, на которых можно учиться, а не только ноутбуки?Да — в разделе Demos собраны полноценные приложения: открытый CLI-агент Gemini CLI для терминала, быстрый старт на Python Flask, веб-консоль Multimodal Live API на React, фуллстек-шаблон на LangGraph и небольшие приложения в Google AI Studio.
Может ли модель опираться на результаты поиска или на мои данные?Да — руководство Grounding описывает подключение Google Поиска, YouTube, ссылок и более нового инструмента Google Maps, а вводное руководство File Search показывает хостинговую RAG-систему, которая позволяет опираться на ваши собственные данные.
Size
1006.5 MB
Stars
17.8K
Updated
CommitOct 15
Age
2y
Commits · 90 Days