This commit is contained in:
Kai Wu 2025-09-15 13:18:37 -07:00
parent b6cb817897
commit aa9a572272
2 changed files with 37 additions and 3 deletions

View file

@ -920,7 +920,7 @@ async def get_raw_document_text(document: Document) -> str:
DeprecationWarning,
stacklevel=2,
)
elif not (document.mime_type.startswith("text/") or document.mime_type == "application/yaml"):
elif not (document.mime_type.startswith("text/") or document.mime_type in ("application/yaml", "application/json")):
raise ValueError(f"Unexpected document mime type: {document.mime_type}")
if isinstance(document.content, URL):