aient 1.2.8__py3-none-any.whl → 1.2.10__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.
@@ -101,7 +101,12 @@ class Texts(ContextProvider):
101
101
  if text is None and name is None:
102
102
  raise ValueError("Either 'text' or 'name' must be provided.")
103
103
 
104
- self._text = text
104
+ # Ensure that non-callable inputs are treated as strings
105
+ if not callable(text):
106
+ self._text = str(text) if text is not None else None
107
+ else:
108
+ self._text = text
109
+
105
110
  self._is_dynamic = callable(self._text)
106
111
 
107
112
  if name is None:
aient/models/chatgpt.py CHANGED
@@ -265,7 +265,7 @@ class chatgpt(BaseLLM):
265
265
  # 构造请求数据
266
266
  request_data = {
267
267
  "model": model or self.engine,
268
- "messages": self.conversation[convo_id].render_latest() if pass_history else Messages(
268
+ "messages": await self.conversation[convo_id].render_latest() if pass_history else Messages(
269
269
  SystemMessage(self.system_prompt, self.conversation[convo_id].provider("files")),
270
270
  UserMessage(prompt)
271
271
  ),
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: aient
3
- Version: 1.2.8
3
+ Version: 1.2.10
4
4
  Summary: Aient: The Awakening of Agent.
5
5
  Requires-Python: >=3.11
6
6
  Description-Content-Type: text/markdown
@@ -1,6 +1,6 @@
1
1
  aient/__init__.py,sha256=SRfF7oDVlOOAi6nGKiJIUK6B_arqYLO9iSMp-2IZZps,21
2
2
  aient/architext/architext/__init__.py,sha256=79Ih1151rfcqZdr7F8HSZSTs_iT2SKd1xCkehMsXeXs,19
3
- aient/architext/architext/core.py,sha256=83eouPWfZt9G6TGCQguoOxOZM_-HRfXIUwjGzbxPoxw,27164
3
+ aient/architext/architext/core.py,sha256=fZzP8_Kk8-o5Bji8Prfh8d0SXN9eQnA24OMCAVgcXKM,27344
4
4
  aient/architext/test/openai_client.py,sha256=Dqtbmubv6vwF8uBqcayG0kbsiO65of7sgU2-DRBi-UM,4590
5
5
  aient/architext/test/test.py,sha256=26cQXXwCcCAVruM-ouM7ng8BQcE-glgmfkGa_EhPDU4,59388
6
6
  aient/architext/test/test_save_load.py,sha256=o8DqH6gDYZkFkQy-a7blqLtJTRj5e4a-Lil48pJ0V3g,3260
@@ -17,7 +17,7 @@ aient/core/test/test_payload.py,sha256=8jBiJY1uidm1jzL-EiK0s6UGmW9XkdsuuKFGrwFhF
17
17
  aient/models/__init__.py,sha256=ZTiZgbfBPTjIPSKURE7t6hlFBVLRS9lluGbmqc1WjxQ,43
18
18
  aient/models/audio.py,sha256=kRd-8-WXzv4vwvsTGwnstK-WR8--vr9CdfCZzu8y9LA,1934
19
19
  aient/models/base.py,sha256=-nnihYnx-vHZMqeVO9ljjt3k4FcD3n-iMk4tT-10nRQ,7232
20
- aient/models/chatgpt.py,sha256=XM63-dJql-Ti6mWK2nEFUACjdoz8uN-mqh4B3NH8kLw,42189
20
+ aient/models/chatgpt.py,sha256=alnRJWhdIQ_LREO0x-pNoK4ZZt1j5PiozBRBsOPs50k,42195
21
21
  aient/plugins/__init__.py,sha256=p3KO6Aa3Lupos4i2SjzLQw1hzQTigOAfEHngsldrsyk,986
22
22
  aient/plugins/arXiv.py,sha256=yHjb6PS3GUWazpOYRMKMzghKJlxnZ5TX8z9F6UtUVow,1461
23
23
  aient/plugins/config.py,sha256=TGgZ5SnNKZ8MmdznrZ-TEq7s2ulhAAwTSKH89bci3dA,7079
@@ -35,8 +35,8 @@ aient/plugins/write_file.py,sha256=Jt8fOEwqhYiSWpCbwfAr1xoi_BmFnx3076GMhuL06uI,3
35
35
  aient/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
36
36
  aient/utils/prompt.py,sha256=UcSzKkFE4-h_1b6NofI6xgk3GoleqALRKY8VBaXLjmI,11311
37
37
  aient/utils/scripts.py,sha256=VqtK4RFEx7KxkmcqG3lFDS1DxoNlFFGErEjopVcc8IE,40974
38
- aient-1.2.8.dist-info/licenses/LICENSE,sha256=XNdbcWldt0yaNXXWB_Bakoqnxb3OVhUft4MgMA_71ds,1051
39
- aient-1.2.8.dist-info/METADATA,sha256=d-gqNwZ00IPMuuqj3sKECwiC1BS1H-M9hUaKi6I74aA,4841
40
- aient-1.2.8.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
41
- aient-1.2.8.dist-info/top_level.txt,sha256=3oXzrP5sAVvyyqabpeq8A2_vfMtY554r4bVE-OHBrZk,6
42
- aient-1.2.8.dist-info/RECORD,,
38
+ aient-1.2.10.dist-info/licenses/LICENSE,sha256=XNdbcWldt0yaNXXWB_Bakoqnxb3OVhUft4MgMA_71ds,1051
39
+ aient-1.2.10.dist-info/METADATA,sha256=Nj2WmNP0-AcFkqecfg-w6hcbBm_Mchtgz3VY_M97qnE,4842
40
+ aient-1.2.10.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
41
+ aient-1.2.10.dist-info/top_level.txt,sha256=3oXzrP5sAVvyyqabpeq8A2_vfMtY554r4bVE-OHBrZk,6
42
+ aient-1.2.10.dist-info/RECORD,,
File without changes