alita-sdk 0.3.210__py3-none-any.whl → 0.3.211__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.
- alita_sdk/runtime/clients/client.py +3 -2
- alita_sdk/tools/chunkers/code/codeparser.py +1 -1
- alita_sdk/tools/postman/api_wrapper.py +27 -3
- {alita_sdk-0.3.210.dist-info → alita_sdk-0.3.211.dist-info}/METADATA +1 -1
- {alita_sdk-0.3.210.dist-info → alita_sdk-0.3.211.dist-info}/RECORD +8 -8
- {alita_sdk-0.3.210.dist-info → alita_sdk-0.3.211.dist-info}/WHEEL +0 -0
- {alita_sdk-0.3.210.dist-info → alita_sdk-0.3.211.dist-info}/licenses/LICENSE +0 -0
- {alita_sdk-0.3.210.dist-info → alita_sdk-0.3.211.dist-info}/top_level.txt +0 -0
@@ -235,10 +235,11 @@ class AlitaClient:
|
|
235
235
|
if llm is None:
|
236
236
|
llm = self.get_llm(
|
237
237
|
model_name=data['llm_settings']['model_name'],
|
238
|
-
model_config
|
238
|
+
model_config={
|
239
239
|
"max_tokens": data['llm_settings']['max_tokens'],
|
240
240
|
"top_p": data['llm_settings']['top_p'],
|
241
|
-
"temperature": data['llm_settings']['temperature']
|
241
|
+
"temperature": data['llm_settings']['temperature'],
|
242
|
+
"model_project_id": data['llm_settings'].get('model_project_id'),
|
242
243
|
}
|
243
244
|
)
|
244
245
|
if not app_type:
|
@@ -41,7 +41,7 @@ def parse_code_files_for_db(file_content_generator: Generator[str, None, None],
|
|
41
41
|
for document in documents:
|
42
42
|
metadata = {
|
43
43
|
"filename": file_name,
|
44
|
-
"method_name":
|
44
|
+
"method_name": 'text',
|
45
45
|
"language": programming_language.value,
|
46
46
|
}
|
47
47
|
commit_hash = data.get("commit_hash")
|
@@ -814,11 +814,30 @@ class PostmanApiWrapper(BaseToolApiWrapper):
|
|
814
814
|
raw_body = request_body.get('raw', '')
|
815
815
|
body = resolve_variables(raw_body)
|
816
816
|
|
817
|
+
# Auto-detect JSON content and set Content-Type if not already set
|
818
|
+
if not content_type and body.strip():
|
819
|
+
# Try to parse as JSON to detect if it's JSON content
|
820
|
+
try:
|
821
|
+
# Remove JavaScript-style comments before JSON parsing
|
822
|
+
import re
|
823
|
+
clean_body = re.sub(r'//.*?(?=\n|$)', '', body, flags=re.MULTILINE)
|
824
|
+
json.loads(clean_body)
|
825
|
+
headers['Content-Type'] = 'application/json'
|
826
|
+
content_type = 'application/json'
|
827
|
+
# Update body to cleaned version without comments
|
828
|
+
body = clean_body
|
829
|
+
except json.JSONDecodeError:
|
830
|
+
# Not JSON, leave as is
|
831
|
+
pass
|
832
|
+
|
817
833
|
# Try to parse as JSON if content type suggests it
|
818
834
|
if 'application/json' in content_type:
|
819
835
|
try:
|
820
|
-
#
|
821
|
-
|
836
|
+
# Remove comments and validate JSON
|
837
|
+
import re
|
838
|
+
clean_body = re.sub(r'//.*?(?=\n|$)', '', body, flags=re.MULTILINE)
|
839
|
+
json.loads(clean_body)
|
840
|
+
body = clean_body # Use cleaned version
|
822
841
|
except json.JSONDecodeError:
|
823
842
|
logger.warning("Body is not valid JSON despite Content-Type")
|
824
843
|
|
@@ -870,7 +889,12 @@ class PostmanApiWrapper(BaseToolApiWrapper):
|
|
870
889
|
request_kwargs['data'] = body
|
871
890
|
elif isinstance(body, str):
|
872
891
|
if 'application/json' in content_type:
|
873
|
-
|
892
|
+
# For JSON content, parse and use json parameter for proper handling
|
893
|
+
try:
|
894
|
+
request_kwargs['json'] = json.loads(body) if body.strip() else {}
|
895
|
+
except json.JSONDecodeError:
|
896
|
+
# Fallback to raw data if JSON parsing fails
|
897
|
+
request_kwargs['data'] = body
|
874
898
|
else:
|
875
899
|
request_kwargs['data'] = body
|
876
900
|
else:
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: alita_sdk
|
3
|
-
Version: 0.3.
|
3
|
+
Version: 0.3.211
|
4
4
|
Summary: SDK for building langchain agents using resources from Alita
|
5
5
|
Author-email: Artem Rozumenko <artyom.rozumenko@gmail.com>, Mikalai Biazruchka <mikalai_biazruchka@epam.com>, Roman Mitusov <roman_mitusov@epam.com>, Ivan Krakhmaliuk <lifedjik@gmail.com>, Artem Dubrovskiy <ad13box@gmail.com>
|
6
6
|
License-Expression: Apache-2.0
|
@@ -4,7 +4,7 @@ alita_sdk/community/utils.py,sha256=lvuCJaNqVPHOORJV6kIPcXJcdprVW_TJvERtYAEgpjM,
|
|
4
4
|
alita_sdk/runtime/__init__.py,sha256=4W0UF-nl3QF2bvET5lnah4o24CoTwSoKXhuN0YnwvEE,828
|
5
5
|
alita_sdk/runtime/clients/__init__.py,sha256=BdehU5GBztN1Qi1Wul0cqlU46FxUfMnI6Vq2Zd_oq1M,296
|
6
6
|
alita_sdk/runtime/clients/artifact.py,sha256=H3pJAh5G-zWVyJ6YbqHGk4jA8U6HfacQduiTivpJZ3Y,3210
|
7
|
-
alita_sdk/runtime/clients/client.py,sha256=
|
7
|
+
alita_sdk/runtime/clients/client.py,sha256=hpidp3v5cIQxja5FLogFprOicFM6INmni1oSRltDBoQ,41953
|
8
8
|
alita_sdk/runtime/clients/datasource.py,sha256=HAZovoQN9jBg0_-lIlGBQzb4FJdczPhkHehAiVG3Wx0,1020
|
9
9
|
alita_sdk/runtime/clients/prompt.py,sha256=li1RG9eBwgNK_Qf0qUaZ8QNTmsncFrAL2pv3kbxZRZg,1447
|
10
10
|
alita_sdk/runtime/langchain/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -145,7 +145,7 @@ alita_sdk/tools/chunkers/__init__.py,sha256=myaBVvPbUsz6PXtBDpA4EiPQgLvIv3q_WPh8
|
|
145
145
|
alita_sdk/tools/chunkers/models.py,sha256=NNkLSljZboYDj6vbqeHmcjj9JrTHbkVWmoHGsL98q3k,3032
|
146
146
|
alita_sdk/tools/chunkers/utils.py,sha256=gOyDHhXSH6Wlmxj_OsMOa2vydZuHD6HZql4PH-SYcTw,192
|
147
147
|
alita_sdk/tools/chunkers/code/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
148
|
-
alita_sdk/tools/chunkers/code/codeparser.py,sha256=
|
148
|
+
alita_sdk/tools/chunkers/code/codeparser.py,sha256=tfLP_NlASOuHchXnGN5jYzMjl2-05NsGxzKScLLRxRg,4257
|
149
149
|
alita_sdk/tools/chunkers/code/constants.py,sha256=7U74oc2ce7d0KfaqmBdcFGOdfOGEdidhm1B9QsdyX8w,3457
|
150
150
|
alita_sdk/tools/chunkers/code/treesitter/__init__.py,sha256=8EfwDHOG8l0DQCIU7XW5YnxwrhI7TTyE0ef_9m4CWEI,580
|
151
151
|
alita_sdk/tools/chunkers/code/treesitter/treesitter.py,sha256=70mBH4Gg8Gl-iTEfT7eT28EBvnVaXmF_go5-d0YZ6zE,3519
|
@@ -250,7 +250,7 @@ alita_sdk/tools/pandas/statsmodels/descriptive.py,sha256=APdofBnEiRhMrn6tLKwH076
|
|
250
250
|
alita_sdk/tools/pandas/statsmodels/hypothesis_testing.py,sha256=fdNAayMB3W7avMfKJCcbf2_P54vUXbq8KVebOB48348,10508
|
251
251
|
alita_sdk/tools/pandas/statsmodels/regression.py,sha256=Y1pWK4u_qzrfA740K-FX0nZ5FREGGPk8mfvykPIYoiI,9164
|
252
252
|
alita_sdk/tools/postman/__init__.py,sha256=FzVZvqbTrA08mdoHVs0GZH1HcXDTtiMMWmSK07Bdvlc,4766
|
253
|
-
alita_sdk/tools/postman/api_wrapper.py,sha256=
|
253
|
+
alita_sdk/tools/postman/api_wrapper.py,sha256=bKgnEQVGv3QhqTevzBOwiXxAd0-Y5vUI1-5U6YubJ5Q,96389
|
254
254
|
alita_sdk/tools/postman/postman_analysis.py,sha256=2d-Oi2UORosIePIUyncSONw9hY7dw8Zc7BQvCd4aqpg,45115
|
255
255
|
alita_sdk/tools/pptx/__init__.py,sha256=vVUrWnj7KWJgEk9oxGSsCAQ2SMSXrp_SFOdUHYQKcAo,3444
|
256
256
|
alita_sdk/tools/pptx/pptx_wrapper.py,sha256=yyCYcTlIY976kJ4VfPo4dyxj4yeii9j9TWP6W8ZIpN8,29195
|
@@ -299,8 +299,8 @@ alita_sdk/tools/zephyr_scale/api_wrapper.py,sha256=kYYOJX15VLRcuEFpobpW2JHw_WND2
|
|
299
299
|
alita_sdk/tools/zephyr_squad/__init__.py,sha256=0AI_j27xVO5Gk5HQMFrqPTd4uvuVTpiZUicBrdfEpKg,2796
|
300
300
|
alita_sdk/tools/zephyr_squad/api_wrapper.py,sha256=kmw_xol8YIYFplBLWTqP_VKPRhL_1ItDD0_vXTe_UuI,14906
|
301
301
|
alita_sdk/tools/zephyr_squad/zephyr_squad_cloud_client.py,sha256=R371waHsms4sllHCbijKYs90C-9Yu0sSR3N4SUfQOgU,5066
|
302
|
-
alita_sdk-0.3.
|
303
|
-
alita_sdk-0.3.
|
304
|
-
alita_sdk-0.3.
|
305
|
-
alita_sdk-0.3.
|
306
|
-
alita_sdk-0.3.
|
302
|
+
alita_sdk-0.3.211.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
303
|
+
alita_sdk-0.3.211.dist-info/METADATA,sha256=sFgoUqE_psWvOmgtgeCdBGa0yn3MdOFzDG43ZDvU4kU,18917
|
304
|
+
alita_sdk-0.3.211.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
305
|
+
alita_sdk-0.3.211.dist-info/top_level.txt,sha256=0vJYy5p_jK6AwVb1aqXr7Kgqgk3WDtQ6t5C-XI9zkmg,10
|
306
|
+
alita_sdk-0.3.211.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|