|
5 | 5 |
|
6 | 6 | from google.genai import types |
7 | 7 |
|
| 8 | +# Gemini API deprecations: https://ai.google.dev/gemini-api/docs/deprecations |
| 9 | +# Gemini API release notes with preview deprecations: https://ai.google.dev/gemini-api/docs/changelog |
| 10 | +# live models: https://docs.cloud.google.com/vertex-ai/generative-ai/docs/live-api |
| 11 | +# VertexAI retirement: https://docs.cloud.google.com/vertex-ai/generative-ai/docs/learn/model-versions#retired-models |
| 12 | +# Additional references: |
| 13 | +# 1. https://github.com/kazunori279/adk-streaming-test/blob/main/test_report.md |
8 | 14 | LiveAPIModels = Literal[ |
9 | 15 | # VertexAI models |
10 | | - "gemini-live-2.5-flash-native-audio", |
11 | | - "gemini-live-2.5-flash-preview-native-audio", |
12 | | - # deprecated vertexai models |
13 | | - "gemini-2.0-flash-exp", |
14 | | - "gemini-live-2.5-flash-preview-native-audio-09-2025", |
| 16 | + "gemini-live-2.5-flash-native-audio", # GA https://docs.cloud.google.com/vertex-ai/generative-ai/docs/models/gemini/2-5-flash-live-api#live-2.5-flash |
| 17 | + "gemini-live-2.5-flash-preview-native-audio-09-2025", # Public preview https://docs.cloud.google.com/vertex-ai/generative-ai/docs/models/gemini/2-5-flash-live-api#live-2.5-flash-preview |
| 18 | + "gemini-live-2.5-flash-preview-native-audio", # still works, possibly an alias, but not mentioned in any docs or changelog |
15 | 19 | # Gemini API models |
16 | | - "gemini-2.5-flash-native-audio-preview-12-2025", |
17 | | - # deprecated Gemini API models |
18 | | - "gemini-2.5-flash-native-audio-preview-09-2025", |
| 20 | + "gemini-2.5-flash-native-audio-preview-12-2025", # https://ai.google.dev/gemini-api/docs/models#gemini-2.5-flash-live |
| 21 | + "gemini-2.5-flash-native-audio-preview-09-2025", # https://ai.google.dev/gemini-api/docs/models#gemini-2.5-flash-live |
| 22 | + "gemini-2.0-flash-exp", # still works in Gemini API but not VertexAI |
19 | 23 | ] |
20 | 24 |
|
21 | 25 | Voice = Literal[ |
|
0 commit comments