mirror of
https://github.com/agent0ai/agent-zero.git
synced 2026-04-28 19:51:11 +00:00
fix: deps for document_query, formatting of knowledge_tool results
This commit is contained in:
parent
99f38bb9e5
commit
807dc3735d
3 changed files with 10 additions and 10 deletions
|
|
@ -592,8 +592,8 @@ class DocumentQueryHelper:
|
|||
mimetype = response.headers["content-type"]
|
||||
if "content-length" in response.headers:
|
||||
content_length = float(response.headers["content-length"]) / 1024 / 1024 # MB
|
||||
if content_length > 25.0:
|
||||
raise ValueError(f"Document content length exceeds max. 25MB: {content_length} MB ({document_uri})")
|
||||
if content_length > 50.0:
|
||||
raise ValueError(f"Document content length exceeds max. 50MB: {content_length} MB ({document_uri})")
|
||||
if mimetype and '; charset=' in mimetype:
|
||||
mimetype = mimetype.split('; charset=')[0]
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue