upgrade: gemini-3.1-flash-lite-preview + jina X-Engine=direct timeout=30s
Browse files
acra.py
CHANGED
|
@@ -7,7 +7,7 @@ from typing import List
|
|
| 7 |
|
| 8 |
client = genai.Client(api_key=os.environ["GEMINI_API_KEY"])
|
| 9 |
EMBED_MODEL = "gemini-embedding-001"
|
| 10 |
-
GEN_MODEL = "gemini-
|
| 11 |
DEPTH = {0: 3, 1: 3, 2: 6, 3: 10}
|
| 12 |
|
| 13 |
def embed_texts(texts):
|
|
@@ -44,8 +44,9 @@ def web_search(query: str, max_results: int = 5) -> List[dict]:
|
|
| 44 |
"Authorization": f"Bearer {jina_key}",
|
| 45 |
"Accept": "application/json",
|
| 46 |
"X-Retain-Images": "none",
|
|
|
|
| 47 |
},
|
| 48 |
-
timeout=
|
| 49 |
follow_redirects=True
|
| 50 |
)
|
| 51 |
if r.status_code != 200:
|
|
|
|
| 7 |
|
| 8 |
client = genai.Client(api_key=os.environ["GEMINI_API_KEY"])
|
| 9 |
EMBED_MODEL = "gemini-embedding-001"
|
| 10 |
+
GEN_MODEL = "gemini-3.1-flash-lite-preview"
|
| 11 |
DEPTH = {0: 3, 1: 3, 2: 6, 3: 10}
|
| 12 |
|
| 13 |
def embed_texts(texts):
|
|
|
|
| 44 |
"Authorization": f"Bearer {jina_key}",
|
| 45 |
"Accept": "application/json",
|
| 46 |
"X-Retain-Images": "none",
|
| 47 |
+
"X-Engine": "direct",
|
| 48 |
},
|
| 49 |
+
timeout=30.0,
|
| 50 |
follow_redirects=True
|
| 51 |
)
|
| 52 |
if r.status_code != 200:
|