beswarm 0.1.65__py3-none-any.whl → 0.1.67__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- beswarm/aient/setup.py +1 -1
- beswarm/aient/src/aient/core/models.py +2 -0
- beswarm/aient/src/aient/core/request.py +16 -4
- beswarm/aient/src/aient/core/utils.py +1 -0
- {beswarm-0.1.65.dist-info → beswarm-0.1.67.dist-info}/METADATA +1 -1
- {beswarm-0.1.65.dist-info → beswarm-0.1.67.dist-info}/RECORD +8 -8
- {beswarm-0.1.65.dist-info → beswarm-0.1.67.dist-info}/WHEEL +0 -0
- {beswarm-0.1.65.dist-info → beswarm-0.1.67.dist-info}/top_level.txt +0 -0
beswarm/aient/setup.py
CHANGED
@@ -4,7 +4,7 @@ from setuptools import setup, find_packages
|
|
4
4
|
|
5
5
|
setup(
|
6
6
|
name="aient",
|
7
|
-
version="1.1.
|
7
|
+
version="1.1.20",
|
8
8
|
description="Aient: The Awakening of Agent.",
|
9
9
|
long_description=Path.open(Path("README.md"), encoding="utf-8").read(),
|
10
10
|
long_description_content_type="text/markdown",
|
@@ -91,6 +91,8 @@ class RequestModel(BaseRequest):
|
|
91
91
|
include_usage: Optional[bool] = None
|
92
92
|
temperature: Optional[float] = 0.5
|
93
93
|
top_p: Optional[float] = 1.0
|
94
|
+
top_k: Optional[int] = None
|
95
|
+
min_p: Optional[float] = None
|
94
96
|
max_tokens: Optional[int] = None
|
95
97
|
max_completion_tokens: Optional[int] = None
|
96
98
|
presence_penalty: Optional[float] = 0.0
|
@@ -12,6 +12,7 @@ from .utils import (
|
|
12
12
|
c35s,
|
13
13
|
gemini1,
|
14
14
|
gemini2,
|
15
|
+
gemini2_5_pro_exp,
|
15
16
|
BaseAPI,
|
16
17
|
safe_get,
|
17
18
|
get_engine,
|
@@ -112,7 +113,7 @@ async def get_gemini_payload(request, engine, provider, api_key=None):
|
|
112
113
|
if system_prompt.strip():
|
113
114
|
systemInstruction = {"parts": [{"text": system_prompt}]}
|
114
115
|
|
115
|
-
if any(off_model in original_model for off_model in gemini_max_token_65k_models) or original_model
|
116
|
+
if any(off_model in original_model for off_model in gemini_max_token_65k_models) or original_model.endswith("-image-generation"):
|
116
117
|
safety_settings = "OFF"
|
117
118
|
else:
|
118
119
|
safety_settings = "BLOCK_NONE"
|
@@ -167,6 +168,7 @@ async def get_gemini_payload(request, engine, provider, api_key=None):
|
|
167
168
|
'response_format',
|
168
169
|
'stream_options',
|
169
170
|
'prompt',
|
171
|
+
'size',
|
170
172
|
]
|
171
173
|
generation_config = {}
|
172
174
|
|
@@ -221,7 +223,7 @@ async def get_gemini_payload(request, engine, provider, api_key=None):
|
|
221
223
|
else:
|
222
224
|
payload["generationConfig"]["maxOutputTokens"] = 8192
|
223
225
|
|
224
|
-
if original_model
|
226
|
+
if original_model.endswith("-image-generation"):
|
225
227
|
payload["generationConfig"]["response_modalities"] = [
|
226
228
|
"Text",
|
227
229
|
"Image",
|
@@ -336,10 +338,11 @@ async def get_vertex_gemini_payload(request, engine, provider, api_key=None):
|
|
336
338
|
pro_models = ["gemini-2.5", "gemini-2.0"]
|
337
339
|
if any(pro_model in original_model for pro_model in pro_models):
|
338
340
|
location = gemini2
|
339
|
-
# search_tool = {"googleSearch": {}}
|
340
341
|
else:
|
341
342
|
location = gemini1
|
342
|
-
|
343
|
+
|
344
|
+
if "gemini-2.5-pro-exp-03-25" == original_model:
|
345
|
+
location = gemini2_5_pro_exp
|
343
346
|
|
344
347
|
if "google-vertex-ai" in provider.get("base_url", ""):
|
345
348
|
url = provider.get("base_url").rstrip('/') + "/v1/projects/{PROJECT_ID}/locations/{LOCATION}/publishers/google/models/{MODEL_ID}:{stream}".format(
|
@@ -351,6 +354,13 @@ async def get_vertex_gemini_payload(request, engine, provider, api_key=None):
|
|
351
354
|
elif api_key is not None and api_key[2] == ".":
|
352
355
|
url = f"https://aiplatform.googleapis.com/v1/publishers/google/models/{original_model}:{gemini_stream}?key={api_key}"
|
353
356
|
headers.pop("Authorization", None)
|
357
|
+
elif "gemini-2.5-pro-exp-03-25" == original_model:
|
358
|
+
url = "https://aiplatform.googleapis.com/v1/projects/{PROJECT_ID}/locations/{LOCATION}/publishers/google/models/{MODEL_ID}:{stream}".format(
|
359
|
+
LOCATION=await location.next(),
|
360
|
+
PROJECT_ID=project_id,
|
361
|
+
MODEL_ID=original_model,
|
362
|
+
stream=gemini_stream
|
363
|
+
)
|
354
364
|
else:
|
355
365
|
url = "https://{LOCATION}-aiplatform.googleapis.com/v1/projects/{PROJECT_ID}/locations/{LOCATION}/publishers/google/models/{MODEL_ID}:{stream}".format(
|
356
366
|
LOCATION=await location.next(),
|
@@ -464,6 +474,8 @@ async def get_vertex_gemini_payload(request, engine, provider, api_key=None):
|
|
464
474
|
'logprobs',
|
465
475
|
'top_logprobs',
|
466
476
|
'stream_options',
|
477
|
+
'prompt',
|
478
|
+
'size',
|
467
479
|
]
|
468
480
|
generation_config = {}
|
469
481
|
|
@@ -437,6 +437,7 @@ c3o = ThreadSafeCircularList(["us-east5"])
|
|
437
437
|
c3h = ThreadSafeCircularList(["us-east5", "us-central1", "europe-west1", "europe-west4"])
|
438
438
|
gemini1 = ThreadSafeCircularList(["us-central1", "us-east4", "us-west1", "us-west4", "europe-west1", "europe-west2"])
|
439
439
|
gemini2 = ThreadSafeCircularList(["us-central1"])
|
440
|
+
gemini2_5_pro_exp = ThreadSafeCircularList(["global"])
|
440
441
|
|
441
442
|
|
442
443
|
|
@@ -1,14 +1,14 @@
|
|
1
1
|
beswarm/__init__.py,sha256=HZjUOJtZR5QhMuDbq-wukQQn1VrBusNWai_ysGo-VVI,20
|
2
2
|
beswarm/utils.py,sha256=Z2Kuus2BLp9EHUC2ZNL9iUsb6NWnPj-MTA7SYzGyg24,1755
|
3
3
|
beswarm/aient/main.py,sha256=SiYAIgQlLJqYusnTVEJOx1WNkSJKMImhgn5aWjfroxg,3814
|
4
|
-
beswarm/aient/setup.py,sha256=
|
4
|
+
beswarm/aient/setup.py,sha256=jQ5DUcJ18TvQ4Dn8B4Q-ATQKYCxTdIqgBDZAhUAL3ak,487
|
5
5
|
beswarm/aient/src/aient/__init__.py,sha256=SRfF7oDVlOOAi6nGKiJIUK6B_arqYLO9iSMp-2IZZps,21
|
6
6
|
beswarm/aient/src/aient/core/__init__.py,sha256=NxjebTlku35S4Dzr16rdSqSTWUvvwEeACe8KvHJnjPg,34
|
7
7
|
beswarm/aient/src/aient/core/log_config.py,sha256=kz2_yJv1p-o3lUQOwA3qh-LSc3wMHv13iCQclw44W9c,274
|
8
|
-
beswarm/aient/src/aient/core/models.py,sha256=
|
9
|
-
beswarm/aient/src/aient/core/request.py,sha256=
|
8
|
+
beswarm/aient/src/aient/core/models.py,sha256=g6rUcNwSTHwmBzt1epsu_2Re8YRFKVCSXRUIFJZpAb4,7432
|
9
|
+
beswarm/aient/src/aient/core/request.py,sha256=qKj_w9UpXZePCGhhMuE-rX7rCPUdCx8GJ-HUXiurBho,66589
|
10
10
|
beswarm/aient/src/aient/core/response.py,sha256=YphzhA9jtQKzWb3L4XGTp9xJZ2FOzHr1aAMTsi896FQ,33201
|
11
|
-
beswarm/aient/src/aient/core/utils.py,sha256=
|
11
|
+
beswarm/aient/src/aient/core/utils.py,sha256=zidsBUBd3KskzcxQcPB1y5x1RhtWcbZeWvmgb4LAadA,27318
|
12
12
|
beswarm/aient/src/aient/core/test/test_base_api.py,sha256=pWnycRJbuPSXKKU9AQjWrMAX1wiLC_014Qc9hh5C2Pw,524
|
13
13
|
beswarm/aient/src/aient/core/test/test_geminimask.py,sha256=HFX8jDbNg_FjjgPNxfYaR-0-roUrOO-ND-FVsuxSoiw,13254
|
14
14
|
beswarm/aient/src/aient/core/test/test_image.py,sha256=_T4peNGdXKBHHxyQNx12u-NTyFE8TlYI6NvvagsG2LE,319
|
@@ -129,7 +129,7 @@ beswarm/tools/search_arxiv.py,sha256=9slwBemXjEqrd7-YgVmyMijPXlkhZCybEDRVhWVQ9B0
|
|
129
129
|
beswarm/tools/search_web.py,sha256=B24amOnGHnmdV_6S8bw8O2PdhZRRIDtJjg-wXcfP7dQ,11859
|
130
130
|
beswarm/tools/think.py,sha256=WLw-7jNIsnS6n8MMSYUin_f-BGLENFmnKM2LISEp0co,1760
|
131
131
|
beswarm/tools/worker.py,sha256=bZwMGUS4wt4yOleb2kKu0rCLHIJgPcokbCmh9bGMzXA,12679
|
132
|
-
beswarm-0.1.
|
133
|
-
beswarm-0.1.
|
134
|
-
beswarm-0.1.
|
135
|
-
beswarm-0.1.
|
132
|
+
beswarm-0.1.67.dist-info/METADATA,sha256=lm26XFI_-H6ZZXdvtAcGBKA2J8cBZZJ_feKSvoscGGk,3553
|
133
|
+
beswarm-0.1.67.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
134
|
+
beswarm-0.1.67.dist-info/top_level.txt,sha256=pJw4O87wvt5882smuSO6DfByJz7FJ8SxxT8h9fHCmpo,8
|
135
|
+
beswarm-0.1.67.dist-info/RECORD,,
|
File without changes
|
File without changes
|