google-genai-sdk-python

Expert guidance for writing Python code using the official Google GenAI SDK (google-genai) for Gemini API and Vertex AI. Use for text generation, multimodal inputs, reasoning, tools, and media generation.

Safety Notice

This listing is imported from skills.sh public index metadata. Review upstream SKILL.md and repository scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "google-genai-sdk-python" with this command: npx skills add cnemri/google-genai-skills/cnemri-google-genai-skills-google-genai-sdk-python

Google GenAI Python SDK Skill

Use this skill to write high-quality, idiomatic Python code for the Gemini API.

Reference Materials

Identify the user's task and refer to the relevant file:

  • Setup & Client: Installation, auth, client initialization.
  • Models: Recommended models (Flash, Pro, Lite, Imagen, Veo).
  • Text Generation: Basic inference, streaming, system instructions, safety.
  • Chat: Multi-turn conversations and history.
  • Reasoning: Thinking config (thinking_level / thinking_budget), thought signatures.
  • Structured Output: JSON schemas, Pydantic models, Enums.
  • Multimodal Inputs: Images, audio, video, PDFs, media resolution.
  • Tools: Function calling, code execution, Google Search grounding.
  • Media Generation: Image generation/editing (Imagen), video generation (Veo).
  • Source Code: Raw SDK source code for deep inspection.

Core Principles

  1. Unified SDK: Always use google-genai.
  2. Stateless Models: Use client.models for single requests.
  3. Stateful Chats: Use client.chats for conversations.
  4. Types: Import from google.genai.types.

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

Coding

google-adk-python

No summary provided by upstream source.

Repository SourceNeeds Review
208-cnemri
Coding

google-developer-knowledge

No summary provided by upstream source.

Repository SourceNeeds Review
General

veo-use

No summary provided by upstream source.

Repository SourceNeeds Review
General

nano-banana-use

No summary provided by upstream source.

Repository SourceNeeds Review