grasp_agents 0.4.2__py3-none-any.whl → 0.4.3__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.
- grasp_agents/llm.py +3 -1
- grasp_agents/llm_agent.py +1 -1
- grasp_agents/llm_policy_executor.py +6 -3
- {grasp_agents-0.4.2.dist-info → grasp_agents-0.4.3.dist-info}/METADATA +1 -1
- {grasp_agents-0.4.2.dist-info → grasp_agents-0.4.3.dist-info}/RECORD +7 -7
- {grasp_agents-0.4.2.dist-info → grasp_agents-0.4.3.dist-info}/WHEEL +0 -0
- {grasp_agents-0.4.2.dist-info → grasp_agents-0.4.3.dist-info}/licenses/LICENSE.md +0 -0
grasp_agents/llm.py
CHANGED
@@ -106,7 +106,9 @@ class LLM(ABC, Generic[SettingsT_co, ConvertT_co]):
|
|
106
106
|
for message in completion.messages:
|
107
107
|
if not message.tool_calls:
|
108
108
|
validate_obj_from_json_or_py_string(
|
109
|
-
message.content or "",
|
109
|
+
message.content or "",
|
110
|
+
adapter=self._response_format_adapter,
|
111
|
+
from_substring=True,
|
110
112
|
)
|
111
113
|
|
112
114
|
def _validate_tool_calls(self, completion: Completion) -> None:
|
grasp_agents/llm_agent.py
CHANGED
@@ -434,9 +434,12 @@ class LLMPolicyExecutor(AutoInstanceAttributesMixin, Generic[_FinalAnswerT, CtxT
|
|
434
434
|
|
435
435
|
self._manage_memory(memory, ctx=ctx, num_turns=turns)
|
436
436
|
|
437
|
-
|
438
|
-
|
439
|
-
|
437
|
+
if self._react_mode and gen_message.tool_calls:
|
438
|
+
tool_choice = "none"
|
439
|
+
elif gen_message.tool_calls:
|
440
|
+
tool_choice = "auto"
|
441
|
+
else:
|
442
|
+
tool_choice = "required"
|
440
443
|
async for event in self.generate_messages_stream(
|
441
444
|
memory, tool_choice=tool_choice, run_id=run_id, ctx=ctx
|
442
445
|
):
|
@@ -6,10 +6,10 @@ grasp_agents/errors.py,sha256=u-P8NZ3S7THQP5Bjv9SFC_JbHd3CKhX3dTWUObEBzmo,461
|
|
6
6
|
grasp_agents/generics_utils.py,sha256=5Pw3I9dlnKC2VGqYKC4ZZUO3Z_vTNT-NPFovNfPkl6I,6542
|
7
7
|
grasp_agents/grasp_logging.py,sha256=H1GYhXdQvVkmauFDZ-KDwvVmPQHZUUm9sRqX_ObK2xI,1111
|
8
8
|
grasp_agents/http_client.py,sha256=Es8NXGDkp4Nem7g24-jW0KFGA9Hp_o2Cv3cOvjup-iU,859
|
9
|
-
grasp_agents/llm.py,sha256=
|
10
|
-
grasp_agents/llm_agent.py,sha256=
|
9
|
+
grasp_agents/llm.py,sha256=4eNB89WNJwby7Umt1Khfr8eVm_yFzXqGdN7i_xHtP_c,5255
|
10
|
+
grasp_agents/llm_agent.py,sha256=w5KM9EPhs4nsEET8AdSI69API-R3pWgb80uSp7zGr1o,13834
|
11
11
|
grasp_agents/llm_agent_memory.py,sha256=KPVnwF68acVNdSObSaRcO905YYx8vLHJ-kAEfZYs0sA,1860
|
12
|
-
grasp_agents/llm_policy_executor.py,sha256=
|
12
|
+
grasp_agents/llm_policy_executor.py,sha256=WtmDo_WwptfZeu_fOz6jPVgmg3v_hmwo9fxD4BWejvY,17697
|
13
13
|
grasp_agents/memory.py,sha256=QSWjpGTn_t3XFKDxycWUCNFFueQcajzduQGU1vkJFWQ,720
|
14
14
|
grasp_agents/packet.py,sha256=PZ1EpclniAoLk7z4ieZbWzgYH3JSRgnlTe_WfbJYG_4,707
|
15
15
|
grasp_agents/packet_pool.py,sha256=F29EWkKM-305Qqf3hK9jriYXj4vgAx9iAWTg-hfZONs,3035
|
@@ -44,7 +44,7 @@ grasp_agents/workflow/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3h
|
|
44
44
|
grasp_agents/workflow/looped_workflow.py,sha256=eQkjCo6j3W5Xc7mw3AGmXpUhTkK2BmhrvCuht2UkZuI,4537
|
45
45
|
grasp_agents/workflow/sequential_workflow.py,sha256=UCHZXvTy47S0UG0WwuKp2G7Az6dAcE5tIFPaOXhxcWM,2347
|
46
46
|
grasp_agents/workflow/workflow_processor.py,sha256=lGW-Cy1QraU1AaCPVRs9-EtU5Z_3O3EAnuyIPzD6KQ8,3134
|
47
|
-
grasp_agents-0.4.
|
48
|
-
grasp_agents-0.4.
|
49
|
-
grasp_agents-0.4.
|
50
|
-
grasp_agents-0.4.
|
47
|
+
grasp_agents-0.4.3.dist-info/METADATA,sha256=cKnmhyENkWagGfbGGAkSDeAh6rNWKMEGirBcmUnBprg,6868
|
48
|
+
grasp_agents-0.4.3.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
49
|
+
grasp_agents-0.4.3.dist-info/licenses/LICENSE.md,sha256=-nNNdWqGB8gJ2O-peFQ2Irshv5tW5pHKyTcYkwvH7CE,1201
|
50
|
+
grasp_agents-0.4.3.dist-info/RECORD,,
|
File without changes
|
File without changes
|