lollms-client 0.24.0__py3-none-any.whl → 0.24.2__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.

Potentially problematic release.


This version of lollms-client might be problematic. Click here for more details.

lollms_client/__init__.py CHANGED
@@ -8,7 +8,7 @@ from lollms_client.lollms_utilities import PromptReshaper # Keep general utiliti
8
8
  from lollms_client.lollms_mcp_binding import LollmsMCPBinding, LollmsMCPBindingManager
9
9
 
10
10
 
11
- __version__ = "0.24.0" # Updated version
11
+ __version__ = "0.24.2" # Updated version
12
12
 
13
13
  # Optionally, you could define __all__ if you want to be explicit about exports
14
14
  __all__ = [
@@ -1606,16 +1606,17 @@ Provide your response as a single JSON object inside a JSON markdown tag. Use th
1606
1606
  tool_params = action.get("tool_params", {})
1607
1607
  except (json.JSONDecodeError, TypeError) as e:
1608
1608
  current_scratchpad += f"\n\n### Step {i+1} Failure\n- **Error:** Failed to generate a valid JSON action: {e}"
1609
+ log_step(f"\n\n### Step {i+1} Failure\n- **Error:** Failed to generate a valid JSON action: {e}", "scratchpad", is_start=False)
1609
1610
  if reasoning_step_id:
1610
1611
  log_step(f"Reasoning Step {i+1}/{max_reasoning_steps}", "reasoning_step", metadata={"id": reasoning_step_id, "error": str(e)}, is_start=False)
1611
1612
  break
1612
1613
 
1613
1614
  current_scratchpad += f"\n\n### Step {i+1}: Thought\n{thought}"
1614
- if streaming_callback:
1615
- streaming_callback(thought, MSG_TYPE.MSG_TYPE_INFO, {"type": "thought"})
1615
+ log_step(f"\n\n### Step {i+1}: Thought\n{thought}", "scratchpad", is_start=False)
1616
1616
 
1617
1617
  if not tool_name:
1618
1618
  current_scratchpad += f"\n\n### Step {i+1} Failure\n- **Error:** Did not specify a tool name."
1619
+ log_step(f"\n\n### Step {i+1} Failure\n- **Error:** Did not specify a tool name.", "scratchpad", is_start=False)
1619
1620
  if reasoning_step_id:
1620
1621
  log_step(f"Reasoning Step {i+1}/{max_reasoning_steps}", "reasoning_step", metadata={"id": reasoning_step_id}, is_start=False)
1621
1622
  break
@@ -1623,12 +1624,14 @@ Provide your response as a single JSON object inside a JSON markdown tag. Use th
1623
1624
  if tool_name == "request_clarification":
1624
1625
  clarification_question = action.get("clarification_question", "Could you please provide more details?")
1625
1626
  current_scratchpad += f"\n\n### Step {i+1}: Action\n- **Action:** Decided to request clarification.\n- **Question:** {clarification_question}"
1627
+ log_step(f"\n\n### Step {i+1}: Action\n- **Action:** Decided to request clarification.\n- **Question:** {clarification_question}", "scratchpad", is_start=False)
1626
1628
  if reasoning_step_id:
1627
1629
  log_step(f"Reasoning Step {i+1}/{max_reasoning_steps}", "reasoning_step", metadata={"id": reasoning_step_id}, is_start=False)
1628
1630
  return {"final_answer": clarification_question, "final_scratchpad": current_scratchpad, "tool_calls": tool_calls_this_turn, "sources": sources_this_turn, "clarification_required": True, "error": None}
1629
1631
 
1630
1632
  if tool_name == "final_answer":
1631
1633
  current_scratchpad += f"\n\n### Step {i+1}: Action\n- **Action:** Decided to formulate the final answer."
1634
+ log_step(f"\n\n### Step {i+1}: Action\n- **Action:** Decided to formulate the final answer.", "scratchpad", is_start=False)
1632
1635
  if reasoning_step_id:
1633
1636
  log_step(f"Reasoning Step {i+1}/{max_reasoning_steps}", "reasoning_step", metadata={"id": reasoning_step_id}, is_start=False)
1634
1637
  break
@@ -1681,7 +1684,7 @@ Provide your response as a single JSON object inside a JSON markdown tag. Use th
1681
1684
 
1682
1685
  tool_calls_this_turn.append({"name": tool_name, "params": tool_params, "result": tool_result})
1683
1686
  current_scratchpad += f"\n\n### Step {i+1}: Observation\n- **Action:** Called `{tool_name}`\n- **Result:**\n{observation_text}"
1684
- log_step("{"+'"scratchpad":"'+current_scratchpad+'"}', "scratchpad", is_start=False)
1687
+ log_step(f"### Step {i+1}: Observation\n- **Action:** Called `{tool_name}`\n", "scratchpad", is_start=False)
1685
1688
 
1686
1689
  if reasoning_step_id:
1687
1690
  log_step(f"Reasoning Step {i+1}/{max_reasoning_steps}", "reasoning_step", metadata={"id": reasoning_step_id}, is_start=False)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: lollms_client
3
- Version: 0.24.0
3
+ Version: 0.24.2
4
4
  Summary: A client library for LoLLMs generate endpoint
5
5
  Author-email: ParisNeo <parisneoai@gmail.com>
6
6
  License: Apache Software License
@@ -26,9 +26,9 @@ examples/mcp_examples/openai_mcp.py,sha256=7IEnPGPXZgYZyiES_VaUbQ6viQjenpcUxGiHE
26
26
  examples/mcp_examples/run_remote_mcp_example_v2.py,sha256=bbNn93NO_lKcFzfIsdvJJijGx2ePFTYfknofqZxMuRM,14626
27
27
  examples/mcp_examples/run_standard_mcp_example.py,sha256=GSZpaACPf3mDPsjA8esBQVUsIi7owI39ca5avsmvCxA,9419
28
28
  examples/test_local_models/local_chat.py,sha256=slakja2zaHOEAUsn2tn_VmI4kLx6luLBrPqAeaNsix8,456
29
- lollms_client/__init__.py,sha256=Z2vFVxHCzijvnclQaaKGS7mowb6ZAjPjfSbPKIbyqPM,1047
29
+ lollms_client/__init__.py,sha256=ug-FkqdmbfZKMvmsAJhRZv9KepwPrqjRDT7ssn_o-gE,1047
30
30
  lollms_client/lollms_config.py,sha256=goEseDwDxYJf3WkYJ4IrLXwg3Tfw73CXV2Avg45M_hE,21876
31
- lollms_client/lollms_core.py,sha256=REZPwnCfTd9T-Zewrwv09DAVEYCzhykrRT-byqUhhuY,151933
31
+ lollms_client/lollms_core.py,sha256=oOZz-k-dFh2-XC31oS7TD1W2M0J74tyqMWF_10BXzu4,152519
32
32
  lollms_client/lollms_discussion.py,sha256=e0lfbkj3Bh-1YbC1JncjO0Dvkx9maFXprAwLLiXxSFc,44578
33
33
  lollms_client/lollms_js_analyzer.py,sha256=01zUvuO2F_lnUe_0NLxe1MF5aHE1hO8RZi48mNPv-aw,8361
34
34
  lollms_client/lollms_llm_binding.py,sha256=Kpzhs5Jx8eAlaaUacYnKV7qIq2wbME5lOEtKSfJKbpg,12161
@@ -79,8 +79,8 @@ lollms_client/tts_bindings/piper_tts/__init__.py,sha256=0IEWG4zH3_sOkSb9WbZzkeV5
79
79
  lollms_client/tts_bindings/xtts/__init__.py,sha256=FgcdUH06X6ZR806WQe5ixaYx0QoxtAcOgYo87a2qxYc,18266
80
80
  lollms_client/ttv_bindings/__init__.py,sha256=UZ8o2izQOJLQgtZ1D1cXoNST7rzqW22rL2Vufc7ddRc,3141
81
81
  lollms_client/ttv_bindings/lollms/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
82
- lollms_client-0.24.0.dist-info/licenses/LICENSE,sha256=HrhfyXIkWY2tGFK11kg7vPCqhgh5DcxleloqdhrpyMY,11558
83
- lollms_client-0.24.0.dist-info/METADATA,sha256=4XlTyg3ECAVsmBsRjkySsdcN9DuXk6zXdgXBUi5lmDE,13401
84
- lollms_client-0.24.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
85
- lollms_client-0.24.0.dist-info/top_level.txt,sha256=NI_W8S4OYZvJjb0QWMZMSIpOrYzpqwPGYaklhyWKH2w,23
86
- lollms_client-0.24.0.dist-info/RECORD,,
82
+ lollms_client-0.24.2.dist-info/licenses/LICENSE,sha256=HrhfyXIkWY2tGFK11kg7vPCqhgh5DcxleloqdhrpyMY,11558
83
+ lollms_client-0.24.2.dist-info/METADATA,sha256=J8Cz-Gg5uQWVkVK7tnc3wtG5Aed78FLRj-NMN6mg9e8,13401
84
+ lollms_client-0.24.2.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
85
+ lollms_client-0.24.2.dist-info/top_level.txt,sha256=NI_W8S4OYZvJjb0QWMZMSIpOrYzpqwPGYaklhyWKH2w,23
86
+ lollms_client-0.24.2.dist-info/RECORD,,