langroid 0.33.7__py3-none-any.whl → 0.33.8__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.
langroid/agent/task.py CHANGED
@@ -200,7 +200,11 @@ class Task:
200
200
  control of task termination.
201
201
  system_message (str): if not empty, overrides agent's system_message
202
202
  user_message (str): if not empty, overrides agent's user_message
203
- restart (bool): if true, resets the agent's message history *at every run*.
203
+ restart (bool): if true (default), resets the agent's message history
204
+ *at every run* when it is the top-level task. Ignored when
205
+ the task is a subtask of another task. Restart behavior of a subtask's
206
+ `run()` can be controlled via the `TaskConfig.restart_as_subtask`
207
+ setting.
204
208
  default_human_response (str|None): default response from user; useful for
205
209
  testing, to avoid interactive input from user.
206
210
  [Instead of this, setting `interactive` usually suffices]
@@ -52,10 +52,14 @@ class URLLoader:
52
52
  or url.lower().endswith(".docx")
53
53
  or url.lower().endswith(".doc")
54
54
  ):
55
- doc_parser = DocumentParser.create(
56
- url,
57
- self.parser.config,
58
- )
55
+ try:
56
+ doc_parser = DocumentParser.create(
57
+ url,
58
+ self.parser.config,
59
+ )
60
+ except Exception as e:
61
+ logging.error(f"Error parsing {url}: {e}")
62
+ continue
59
63
  new_chunks = doc_parser.get_doc_chunks()
60
64
  if len(new_chunks) == 0:
61
65
  # If the document is empty, try to extract images
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: langroid
3
- Version: 0.33.7
3
+ Version: 0.33.8
4
4
  Summary: Harness LLMs with Multi-Agent Programming
5
5
  Author-email: Prasad Chalasani <pchalasani@gmail.com>
6
6
  License: MIT
@@ -8,7 +8,7 @@ langroid/agent/batch.py,sha256=qK3ph6VNj_1sOhfXCZY4r6gh035DglDKU751p8BU0tY,14665
8
8
  langroid/agent/chat_agent.py,sha256=Idts_HDO1tW052POVOQ9FvuU37TTB7c1I96YVbnBumo,80030
9
9
  langroid/agent/chat_document.py,sha256=xPUMGzR83rn4iAEXIw2jy5LQ6YJ6Y0TiZ78XRQeDnJQ,17778
10
10
  langroid/agent/openai_assistant.py,sha256=JkAcs02bIrgPNVvUWVR06VCthc5-ulla2QMBzux_q6o,34340
11
- langroid/agent/task.py,sha256=jAPoifZqGwiunDBlz0c-pOHYXKXlhhpYXxZJGNz9kkk,89731
11
+ langroid/agent/task.py,sha256=c_Ih0Cc_iiyFKBmKMSdirHcW4RX_35JkCFp05jDAEiM,89994
12
12
  langroid/agent/tool_message.py,sha256=HDW_FVQXvZAHI61CtOYNuZet0qlK_WwOnjSYd1g81eo,14742
13
13
  langroid/agent/xml_tool_message.py,sha256=6SshYZJKIfi4mkE-gIoSwjkEYekQ8GwcSiCv7a5uO9E,15054
14
14
  langroid/agent/callbacks/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -87,7 +87,7 @@ langroid/parsing/routing.py,sha256=-FcnlqldzL4ZoxuDwXjQPNHgBe9F9-F4R6q7b_z9CvI,1
87
87
  langroid/parsing/search.py,sha256=0i_r0ESb5HEQfagA2g7_uMQyxYPADWVbdcN9ixZhS4E,8992
88
88
  langroid/parsing/spider.py,sha256=Y6y7b86Y2k770LdhxgjVlImBxuuy1V9n8-XQ3QPaG5s,3199
89
89
  langroid/parsing/table_loader.py,sha256=qNM4obT_0Y4tjrxNBCNUYjKQ9oETCZ7FbolKBTcz-GM,3410
90
- langroid/parsing/url_loader.py,sha256=Na2TBlKuQkloZzkE2d7xl6mh9olS3CbpgCsJbJ-xhIA,4472
90
+ langroid/parsing/url_loader.py,sha256=JK48KktLRDBfjrt4nsUfy92M6yGdEeicAqOum2MdULM,4656
91
91
  langroid/parsing/urls.py,sha256=XjpaV5onG7gKQ5iQeFTzHSw5P08Aqw0g-rMUu61lR6s,7988
92
92
  langroid/parsing/utils.py,sha256=kb9DlHaG1iQB-6JagH1C26SdCNNf8U-2XaXia4_dWCw,12726
93
93
  langroid/parsing/web_search.py,sha256=8rW8EI3tyHITaB2l9MT_6yLMeQfo8y-Ih-8N2v2uMpk,4931
@@ -121,7 +121,7 @@ langroid/vector_store/lancedb.py,sha256=b3_vWkTjG8mweZ7ZNlUD-NjmQP_rLBZfyKWcxt2v
121
121
  langroid/vector_store/meilisearch.py,sha256=6frB7GFWeWmeKzRfLZIvzRjllniZ1cYj3HmhHQICXLs,11663
122
122
  langroid/vector_store/momento.py,sha256=UNHGT6jXuQtqY9f6MdqGU14bVnS0zHgIJUa30ULpUJo,10474
123
123
  langroid/vector_store/qdrantdb.py,sha256=v7mCsijc2GdRJyil-yFaUVAX4SX5D75mD3vzlpjCMuo,17393
124
- langroid-0.33.7.dist-info/METADATA,sha256=-c5r_YsiD1zvBzp0s7puMldaITe1oyDLibo4xLe3dIo,59015
125
- langroid-0.33.7.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
126
- langroid-0.33.7.dist-info/licenses/LICENSE,sha256=EgVbvA6VSYgUlvC3RvPKehSg7MFaxWDsFuzLOsPPfJg,1065
127
- langroid-0.33.7.dist-info/RECORD,,
124
+ langroid-0.33.8.dist-info/METADATA,sha256=B8l5KwLOOVWwTQ7143cYVLffIQYRc3m0UtMbkyoE7N0,59015
125
+ langroid-0.33.8.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
126
+ langroid-0.33.8.dist-info/licenses/LICENSE,sha256=EgVbvA6VSYgUlvC3RvPKehSg7MFaxWDsFuzLOsPPfJg,1065
127
+ langroid-0.33.8.dist-info/RECORD,,