IntelliMod / src /test_docling.py
J-Barrert's picture
Upload folder using huggingface_hub
6e02dfb verified
Raw
History Blame Contribute Delete
382 Bytes
from docling.document_converter import DocumentConverter
def test_read():
# Kael can now read websites and PDFs!
source = "https://arxiv.org/pdf/2408.09869" # A random AI paper
converter = DocumentConverter()
result = converter.convert(source)
print(result.document.export_to_markdown()[:500]) # Print first 500 chars
if __name__ == "__main__":
test_read()