MCPcopy Create free account
hub / github.com/Roy3838/Observer / __init__

Method __init__

api/gemini_handler.py:22–101  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

20 Asynchronous handler for Google Gemini API requests using httpx.
21 """
22 def __init__(self):
23 super().__init__("gemini")
24
25 # --- Model Mapping (like OpenRouter) ---
26 # Maps display names to actual Gemini model IDs
27 self.model_map = {
28 "gemma-4-26b-a4b-it": {
29 "model_id": "gemma-4-26b-a4b-it",
30 "parameters": "26BA4",
31 "multimodal": True,
32 "pro": False
33 },
34 "gemma-4-31b-it": {
35 "model_id": "gemma-4-31b-it",
36 "parameters": "31B",
37 "multimodal": True,
38 "pro": True
39 },
40 "gemma-3-4b-it": {
41 "model_id": "gemma-4-26b-a4b-it",
42 "parameters": "4B",
43 "multimodal": True,
44 "pro": False
45 },
46 "gemma-3-12b-it": {
47 "model_id": "gemma-4-26b-a4b-it",
48 "parameters": "12B",
49 "multimodal": True,
50 "pro": False
51 },
52 # Hidden model for agent creator (free users)
53 "gemini-2.0-flash-lite-free": {
54 "model_id": "gemini-2.5-flash-lite",
55 "parameters": "N/A",
56 "multimodal": True,
57 "pro": False
58 },
59 # Hidden model for agent creator (pro users)
60 "gemini-2.5-flash-lite-free": {
61 "model_id": "gemini-2.5-flash-lite",
62 "parameters": "N/A",
63 "multimodal": True,
64 "pro": True
65 },
66 "gemini-2.5-flash-lite": {
67 "model_id": "gemini-2.5-flash-lite",
68 "parameters": "N/A",
69 "multimodal": True,
70 "pro": True
71 },
72 "gemma-3-27b-it": {
73 "model_id": "gemma-4-26b-a4b-it",
74 "parameters": "27B",
75 "multimodal": True,
76 "pro": True
77 },
78 "gemma-4-26B-a4b-it": {
79 "model_id": "gemma-4-26b-a4b-it",

Callers

nothing calls this directly

Calls 2

errorMethod · 0.80
infoMethod · 0.80

Tested by

no test coverage detected