{"id":13456462,"url":"https://github.com/opendatalab/MinerU","last_synced_at":"2025-03-24T10:32:49.730Z","repository":{"id":225778583,"uuid":"765083837","full_name":"opendatalab/MinerU","owner":"opendatalab","description":"A high-quality tool for convert PDF to Markdown and JSON.一站式开源高质量数据提取工具，将PDF转换成Markdown和JSON格式。","archived":false,"fork":false,"pushed_at":"2025-02-27T10:08:49.000Z","size":120890,"stargazers_count":26937,"open_issues_count":76,"forks_count":2075,"subscribers_count":135,"default_branch":"master","last_synced_at":"2025-03-02T08:39:55.012Z","etag":null,"topics":["ai4science","document-analysis","extract-data","layout-analysis","ocr","parser","pdf","pdf-converter","pdf-extractor-llm","pdf-extractor-pretrain","pdf-extractor-rag","pdf-parser","python"],"latest_commit_sha":null,"homepage":"https://mineru.net","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/opendatalab.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-02-29T08:52:34.000Z","updated_at":"2025-03-02T08:30:16.000Z","dependencies_parsed_at":"2024-03-24T12:30:07.707Z","dependency_job_id":"2cd34f0b-3eec-4ec6-a5e1-772ac515b26e","html_url":"https://github.com/opendatalab/MinerU","commit_stats":{"total_commits":1390,"total_committers":37,"mean_commits":"37.567567567567565","dds":0.4035971223021583,"last_synced_commit":"a962824b3557a4ceac87e8c11977dfff660498fb"},"previous_names":["myhloli/magic-pdf","magic-pdf-development-team/magic-pdf","opendatalab/mineru"],"tags_count":113,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opendatalab%2FMinerU","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opendatalab%2FMinerU/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opendatalab%2FMinerU/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opendatalab%2FMinerU/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/opendatalab","download_url":"https://codeload.github.com/opendatalab/MinerU/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245252515,"owners_count":20585084,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai4science","document-analysis","extract-data","layout-analysis","ocr","parser","pdf","pdf-converter","pdf-extractor-llm","pdf-extractor-pretrain","pdf-extractor-rag","pdf-parser","python"],"created_at":"2024-07-31T08:01:22.459Z","updated_at":"2025-03-24T10:32:49.715Z","avatar_url":"https://github.com/opendatalab.png","language":"Python","funding_links":[],"categories":["Document Processing and OCR","Python","数据 Data","🔥LLM Extraction / Parsing","其他_NLP自然语言处理","RAG (Retrieval Augmented Generation）","Repos","Everything to Markdown to LLMs","III. Open-source Datasets","📋 Scientific Documentation \u0026 Parsing","5. Retrieval-Augmented Generation (RAG) \u0026 Knowledge","Librerías para usar NLP en español","PDF and Document Processing Tools","开发工具\u0026框架","🤖 AI \u0026 Machine Learning","🤖 AI \u0026 LLM (人工智能与大模型)","Document AI, OCR, and Chart Understanding"],"sub_categories":["Economic Data Sources","其他_文本生成、文本对话","Document Parser","Contribute to our Repository","3.4 General-purpose (Books, Encyclopedias, Instructions, Long Contexts, etc.)","High-Performance Document Processing","Preprocesamiento (de pdf u otro a markdown/json)","Vector Store Tutorials","Models and tools"],"readme":"\u003cdiv align=\"center\" xmlns=\"http://www.w3.org/1999/html\"\u003e\n\u003c!-- logo --\u003e\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"docs/images/MinerU-logo.png\" width=\"300px\" style=\"vertical-align:middle;\"\u003e\n\u003c/p\u003e\n\n\u003c!-- icon --\u003e\n\n[![stars](https://img.shields.io/github/stars/opendatalab/MinerU.svg)](https://github.com/opendatalab/MinerU)\n[![forks](https://img.shields.io/github/forks/opendatalab/MinerU.svg)](https://github.com/opendatalab/MinerU)\n[![open issues](https://img.shields.io/github/issues-raw/opendatalab/MinerU)](https://github.com/opendatalab/MinerU/issues)\n[![issue resolution](https://img.shields.io/github/issues-closed-raw/opendatalab/MinerU)](https://github.com/opendatalab/MinerU/issues)\n[![PyPI version](https://badge.fury.io/py/magic-pdf.svg)](https://badge.fury.io/py/magic-pdf)\n[![Downloads](https://static.pepy.tech/badge/magic-pdf)](https://pepy.tech/project/magic-pdf)\n[![Downloads](https://static.pepy.tech/badge/magic-pdf/month)](https://pepy.tech/project/magic-pdf)\n\n[![OpenDataLab](https://img.shields.io/badge/Demo_on_OpenDataLab-blue?logo=data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTM0IiBoZWlnaHQ9IjEzNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cGF0aCBkPSJtMTIyLDljMCw1LTQsOS05LDlzLTktNC05LTksNC05LDktOSw5LDQsOSw5eiIgZmlsbD0idXJsKCNhKSIvPjxwYXRoIGQ9Im0xMjIsOWMwLDUtNCw5LTksOXMtOS00LTktOSw0LTksOS05LDksNCw5LDl6IiBmaWxsPSIjMDEwMTAxIi8+PHBhdGggZD0ibTkxLDE4YzAsNS00LDktOSw5cy05LTQtOS05LDQtOSw5LTksOSw0LDksOXoiIGZpbGw9InVybCgjYikiLz48cGF0aCBkPSJtOTEsMThjMCw1LTQsOS05LDlzLTktNC05LTksNC05LDktOSw5LDQsOSw5e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pZD0iYiIgeDE9Ijg0IiB5MT0iNDEiIHgyPSI3NSIgeTI9IjEyMCIgZ3JhZGllbnRVbml0cz0idXNlclNwYWNlT25Vc2UiPjxzdG9wIHN0b3AtY29sb3I9IiNmZmYiLz48c3RvcCBvZmZzZXQ9IjEiIHN0b3AtY29sb3I9IiMyZTJlMmUiLz48L2xpbmVhckdyYWRpZW50PjxsaW5lYXJHcmFkaWVudCBpZD0iYyIgeDE9Ijg0IiB5MT0iNDEiIHgyPSI3NSIgeTI9IjEyMCIgZ3JhZGllbnRVbml0cz0idXNlclNwYWNlT25Vc2UiPjxzdG9wIHN0b3AtY29sb3I9IiNmZmYiLz48c3RvcCBvZmZzZXQ9IjEiIHN0b3AtY29sb3I9IiMyZTJlMmUiLz48L2xpbmVhckdyYWRpZW50PjwvZGVmcz48L3N2Zz4=\u0026labelColor=white)](https://mineru.net/OpenSourceTools/Extractor?source=github)\n[![HuggingFace](https://img.shields.io/badge/Demo_on_HuggingFace-yellow.svg?logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAF8AAABYCAMAAACkl9t/AAAAk1BMVEVHcEz/nQv/nQv/nQr/nQv/nQr/nQv/nQv/nQr/wRf/txT/pg7/yRr/rBD/zRz/ngv/oAz/zhz/nwv/txT/ngv/0B3+zBz/nQv/0h7/wxn/vRb/thXkuiT/rxH/pxD/ogzcqyf/nQvTlSz/czCxky7/SjifdjT/Mj3+Mj3wMj15aTnDNz+DSD9RTUBsP0FRO0Q6O0WyIxEIAAAAGHRSTlMADB8zSWF3krDDw8TJ1NbX5efv8ff9/fxKDJ9uAAAGKklEQVR42u2Z63qjOAyGC4RwCOfB2JAGqrSb2WnTw/1f3UaWcSGYNKTdf/P+mOkTrE+yJBulvfvLT2A5ruenaVHyIks33npl/6C4s/ZLAM45SOi/1FtZPyFur1OYofBX3w7d54Bxm+E8db+nDr12ttmESZ4zludJEG5S7TO72YPlKZFyE+YCYUJTBZsMiNS5Sd7NlDmKM2Eg2JQg8awbglfq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AjwVSt72DSoXNyOWUrU5mQ9nRYyjp89Xo7oRI6Bga9QNT1mQ/ptaJq5T/7WcgAZywR/XlPGAUDdet3LE+qS0TI+g+aJU8MIqjo0Kx8Ly+maxLjJmjQ18rA0YCkxLQbUZP1WqdmyQGJLUm7VnQFqodmXSqmRrdVpqdzk5LvmvgtEcW8PMGdaS23EOWyDVbACZzUJPaqMbjDxpA3Qrgl0AikimGDbqmyT8P8NOYiqrldF8rX+YN7TopX4UoHuSCYY7cgX4gHwclQKl1zhx0THf+tCAUValzjI7Wg9EhptrkIcfIJjA94evOn8B2eHaVzvBrnl2ig0So6hvPaz0IGcOvTHvUIlE2+prqAxLSQxZlU2stql1NqCCLdIiIN/i1DBEHUoElM9dBravbiAnKqgpi4IBkw+utSPIoBijDXJipSVV7MpOEJUAc5Qmm3BnUN+w3hteEieYKfRZSIUcXKMVf0u5wD4EwsUNVvZOtUT7A2GkffHjByWpHqvRBYrTV72a6j8zZ6W0DTE86Hn04bmyWX3Ri9WH7ZU6Q7h+ZHo0nHUAcsQvVhXRDZHChwiyi/hnPuOsSEF6Exk3o6Y9DT1eZ+6cASXk2Y9k+6EOQMDGm6WBK10wOQJCBwren86cPPWUcRAnTVjGcU1LBgs9FURiX/e6479yZcLwCBmTxiawEwrOcleuu12t3tbLv/N4RLYIBhYexm7Fcn4OJcn0+zc+s8/VfPeddZHAGN6TT8eGczHdR/Gts1/MzDkThr23zqrVfAMFT33Nx1RJsx1k5zuWILLnG/vsH+Fv5D4NTVcp1Gzo8AAAAAElFTkSuQmCC\u0026labelColor=white)](https://huggingface.co/spaces/opendatalab/MinerU)\n[![ModelScope](https://img.shields.io/badge/Demo_on_ModelScope-purple?logo=data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjIzIiBoZWlnaHQ9IjIwMCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KCiA8Zz4KICA8dGl0bGU+TGF5ZXIgMTwvdGl0bGU+CiAgPHBhdGgg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2Z18yMiIgZmlsbD0iIzM2Y2ZkMSIgZD0ibTczLjQ5LDg5Ljg0bDI1LjY1LDBsMCwyNS42NDk5OWwtMjUuNjUsMGwwLC0yNS42NDk5OXoiLz4KICA8cGF0aCBpZD0ic3ZnXzIzIiBmaWxsPSIjNjI0YWZmIiBkPSJtNDcuODQsNjQuMTlsMjUuNjUsMGwwLC0yMi4xOWwtNDcuODQsMGwwLDQ3Ljg0bDIyLjE5LDBsMCwtMjUuNjV6Ii8+CiAgPHBhdGggaWQ9InN2Z18yNCIgZmlsbD0iIzYyNGFmZiIgZD0ibTQ3Ljg0LDExNS40OWwtMjIuMTksMGwwLDQ3Ljg0bDQ3Ljg0LDBsMCwtMjIuMTlsLTI1LjY1LDBsMCwtMjUuNjV6Ii8+CiA8L2c+Cjwvc3ZnPg==\u0026labelColor=white)](https://www.modelscope.cn/studios/OpenDataLab/MinerU)\n[![Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/gist/myhloli/3b3a00a4a0a61577b6c30f989092d20d/mineru_demo.ipynb)\n[![Paper](https://img.shields.io/badge/Paper-arXiv-green)](https://arxiv.org/abs/2409.18839)\n\n\n\u003ca href=\"https://trendshift.io/repositories/11174\" target=\"_blank\"\u003e\u003cimg src=\"https://trendshift.io/api/badge/repositories/11174\" alt=\"opendatalab%2FMinerU | Trendshift\" style=\"width: 250px; height: 55px;\" width=\"250\" height=\"55\"/\u003e\u003c/a\u003e\n\n\u003c!-- language --\u003e\n\n[English](README.md) | [简体中文](README_zh-CN.md)\n\n\u003c!-- hot link --\u003e\n\n\u003cp align=\"center\"\u003e\n\u003ca href=\"https://github.com/opendatalab/PDF-Extract-Kit\"\u003ePDF-Extract-Kit: High-Quality PDF Extraction Toolkit\u003c/a\u003e🔥🔥🔥\n\u003cbr\u003e\n\u003cbr\u003e\n\u003ca href=\"https://mineru.net/client?source=github\"\u003e\nEasier to use: Just grab MinerU Desktop. No coding, no login, just a simple interface and smooth interactions. Enjoy it without any fuss!\u003c/a\u003e🚀🚀🚀\n\n\u003c/p\u003e\n\n\u003c!-- join us --\u003e\n\n\u003cp align=\"center\"\u003e\n    👋 join us on \u003ca href=\"https://discord.gg/Tdedn9GTXq\" target=\"_blank\"\u003eDiscord\u003c/a\u003e and \u003ca href=\"http://mineru.space/s/V85Yl\" target=\"_blank\"\u003eWeChat\u003c/a\u003e\n\u003c/p\u003e\n\n\u003c/div\u003e\n\n# Changelog\n- 2025/03/03 1.2.1 released, fixed several bugs:\n  - Fixed the impact on punctuation marks during full-width to half-width conversion of letters and numbers\n  - Fixed caption matching inaccuracies in certain scenarios\n  - Fixed formula span loss issues in certain scenarios\n- 2025/02/24 1.2.0 released. This version includes several fixes and improvements to enhance parsing efficiency and accuracy:\n  - Performance Optimization\n    - Increased classification speed for PDF documents in auto mode.\n  - Parsing Optimization\n    - Improved parsing logic for documents containing watermarks, significantly enhancing the parsing results for such documents.\n    - Enhanced the matching logic for multiple images/tables and captions within a single page, improving the accuracy of image-text matching in complex layouts.\n  - Bug Fixes\n    - Fixed an issue where image/table spans were incorrectly filled into text blocks under certain conditions.\n    - Resolved an issue where title blocks were empty in some cases.\n- 2025/01/22 1.1.0 released. In this version we have focused on improving parsing accuracy and efficiency:\n  - Model capability upgrade (requires re-executing the [model download process](docs/how_to_download_models_en.md) to obtain incremental updates of model files)\n    - The layout recognition model has been upgraded to the latest `doclayout_yolo(2501)` model, improving layout recognition accuracy.\n    - The formula parsing model has been upgraded to the latest `unimernet(2501)` model, improving formula recognition accuracy.\n  - Performance optimization\n    - On devices that meet certain configuration requirements (16GB+ VRAM), by optimizing resource usage and restructuring the processing pipeline, overall parsing speed has been increased by more than 50%.\n  - Parsing effect optimization\n    - Added a new heading classification feature (testing version, enabled by default) to the online demo([mineru.net](https://mineru.net/OpenSourceTools/Extractor)/[huggingface](https://huggingface.co/spaces/opendatalab/MinerU)/[modelscope](https://www.modelscope.cn/studios/OpenDataLab/MinerU)), which supports hierarchical classification of headings, thereby enhancing document structuring.\n- 2025/01/10 1.0.1 released. This is our first official release, where we have introduced a completely new API interface and enhanced compatibility through extensive refactoring, as well as a brand new automatic language identification feature:\n  - New API Interface\n    - For the data-side API, we have introduced the Dataset class, designed to provide a robust and flexible data processing framework. This framework currently supports a variety of document formats, including images (.jpg and .png), PDFs, Word documents (.doc and .docx), and PowerPoint presentations (.ppt and .pptx). It ensures effective support for data processing tasks ranging from simple to complex.\n    - For the user-side API, we have meticulously designed the MinerU processing workflow as a series of composable Stages. Each Stage represents a specific processing step, allowing users to define new Stages according to their needs and creatively combine these stages to customize their data processing workflows.\n  - Enhanced Compatibility\n    - By optimizing the dependency environment and configuration items, we ensure stable and efficient operation on ARM architecture Linux systems.\n    - We have deeply integrated with Huawei Ascend NPU acceleration, providing autonomous and controllable high-performance computing capabilities. This supports the localization and development of AI application platforms in China. [Ascend NPU Acceleration](docs/README_Ascend_NPU_Acceleration_zh_CN.md)\n  - Automatic Language Identification\n    - By introducing a new language recognition model, setting the `lang` configuration to `auto` during document parsing will automatically select the appropriate OCR language model, improving the accuracy of scanned document parsing.\n- 2024/11/22 0.10.0 released. Introducing hybrid OCR text extraction capabilities,\n  - Significantly improved parsing performance in complex text distribution scenarios such as dense formulas, irregular span regions, and text represented by images.\n  - Combines the dual advantages of accurate content extraction and faster speed in text mode, and more precise span/line region recognition in OCR mode.\n- 2024/11/15 0.9.3 released. Integrated [RapidTable](https://github.com/RapidAI/RapidTable) for table recognition, improving single-table parsing speed by more than 10 times, with higher accuracy and lower GPU memory usage.\n- 2024/11/06 0.9.2 released. Integrated the [StructTable-InternVL2-1B](https://huggingface.co/U4R/StructTable-InternVL2-1B) model for table recognition functionality.\n- 2024/10/31 0.9.0 released. This is a major new version with extensive code refactoring, addressing numerous issues, improving performance, reducing hardware requirements, and enhancing usability:\n  - Refactored the sorting module code to use [layoutreader](https://github.com/ppaanngggg/layoutreader) for reading order sorting, ensuring high accuracy in various layouts.\n  - Refactored the paragraph concatenation module to achieve good results in cross-column, cross-page, cross-figure, and cross-table scenarios.\n  - Refactored the list and table of contents recognition functions, significantly improving the accuracy of list blocks and table of contents blocks, as well as the parsing of corresponding text paragraphs.\n  - Refactored the matching logic for figures, tables, and descriptive text, greatly enhancing the accuracy of matching captions and footnotes to figures and tables, and reducing the loss rate of descriptive text to near zero.\n  - Added multi-language support for OCR, supporting detection and recognition of 84 languages.For the list of supported languages, see [OCR Language Support List](https://paddlepaddle.github.io/PaddleOCR/latest/en/ppocr/blog/multi_languages.html#5-support-languages-and-abbreviations).\n  - Added memory recycling logic and other memory optimization measures, significantly reducing memory usage. The memory requirement for enabling all acceleration features except table acceleration (layout/formula/OCR) has been reduced from 16GB to 8GB, and the memory requirement for enabling all acceleration features has been reduced from 24GB to 10GB.\n  - Optimized configuration file feature switches, adding an independent formula detection switch to significantly improve speed and parsing results when formula detection is not needed.\n  - Integrated [PDF-Extract-Kit 1.0](https://github.com/opendatalab/PDF-Extract-Kit):\n    - Added the self-developed `doclayout_yolo` model, which speeds up processing by more than 10 times compared to the original solution while maintaining similar parsing effects, and can be freely switched with `layoutlmv3` via the configuration file.\n    - Upgraded formula parsing to `unimernet 0.2.1`, improving formula parsing accuracy while significantly reducing memory usage.\n    - Due to the repository change for `PDF-Extract-Kit 1.0`, you need to re-download the model. Please refer to [How to Download Models](docs/how_to_download_models_en.md) for detailed steps.\n- 2024/09/27 Version 0.8.1 released, Fixed some bugs, and providing a [localized deployment version](projects/web_demo/README.md) of the [online demo](https://opendatalab.com/OpenSourceTools/Extractor/PDF/) and the [front-end interface](projects/web/README.md).\n- 2024/09/09: Version 0.8.0 released, supporting fast deployment with Dockerfile, and launching demos on Huggingface and Modelscope.\n- 2024/08/30: Version 0.7.1 released, add paddle tablemaster table recognition option\n- 2024/08/09: Version 0.7.0b1 released, simplified installation process, added table recognition functionality\n- 2024/08/01: Version 0.6.2b1 released, optimized dependency conflict issues and installation documentation\n- 2024/07/05: Initial open-source release\n\n\u003c!-- TABLE OF CONTENT --\u003e\n\n\u003cdetails open=\"open\"\u003e\n  \u003csummary\u003e\u003ch2 style=\"display: inline-block\"\u003eTable of Contents\u003c/h2\u003e\u003c/summary\u003e\n  \u003col\u003e\n    \u003cli\u003e\n      \u003ca href=\"#mineru\"\u003eMinerU\u003c/a\u003e\n      \u003cul\u003e\n        \u003cli\u003e\u003ca href=\"#project-introduction\"\u003eProject Introduction\u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#key-features\"\u003eKey Features\u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#quick-start\"\u003eQuick Start\u003c/a\u003e\n            \u003cul\u003e\n            \u003cli\u003e\u003ca href=\"#online-demo\"\u003eOnline Demo\u003c/a\u003e\u003c/li\u003e\n            \u003cli\u003e\u003ca href=\"#quick-cpu-demo\"\u003eQuick CPU Demo\u003c/a\u003e\u003c/li\u003e\n            \u003cli\u003e\u003ca href=\"#using-gpu\"\u003eUsing GPU\u003c/a\u003e\u003c/li\u003e\n            \u003cli\u003e\u003ca href=\"#using-npu\"\u003eUsing NPU\u003c/a\u003e\u003c/li\u003e\n            \u003c/ul\u003e\n        \u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#usage\"\u003eUsage\u003c/a\u003e\n            \u003cul\u003e\n            \u003cli\u003e\u003ca href=\"#command-line\"\u003eCommand Line\u003c/a\u003e\u003c/li\u003e\n            \u003cli\u003e\u003ca href=\"#api\"\u003eAPI\u003c/a\u003e\u003c/li\u003e\n            \u003cli\u003e\u003ca href=\"#deploy-derived-projects\"\u003eDeploy Derived Projects\u003c/a\u003e\u003c/li\u003e\n            \u003cli\u003e\u003ca href=\"#development-guide\"\u003eDevelopment Guide\u003c/a\u003e\u003c/li\u003e\n            \u003c/ul\u003e\n        \u003c/li\u003e\n      \u003c/ul\u003e\n    \u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#todo\"\u003eTODO\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#known-issues\"\u003eKnown Issues\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#faq\"\u003eFAQ\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#all-thanks-to-our-contributors\"\u003eAll Thanks To Our Contributors\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#license-information\"\u003eLicense Information\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#acknowledgments\"\u003eAcknowledgments\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#citation\"\u003eCitation\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#star-history\"\u003eStar History\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#magic-doc\"\u003eMagic-doc\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#magic-html\"\u003eMagic-html\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#links\"\u003eLinks\u003c/a\u003e\u003c/li\u003e\n  \u003c/ol\u003e\n\u003c/details\u003e\n\n# MinerU\n\n## Project Introduction\n\nMinerU is a tool that converts PDFs into machine-readable formats (e.g., markdown, JSON), allowing for easy extraction into any format.\nMinerU was born during the pre-training process of [InternLM](https://github.com/InternLM/InternLM). We focus on solving symbol conversion issues in scientific literature and hope to contribute to technological development in the era of large models.\nCompared to well-known commercial products, MinerU is still young. If you encounter any issues or if the results are not as expected, please submit an issue on [issue](https://github.com/opendatalab/MinerU/issues) and **attach the relevant PDF**.\n\nhttps://github.com/user-attachments/assets/4bea02c9-6d54-4cd6-97ed-dff14340982c\n\n## Key Features\n\n- Remove headers, footers, footnotes, page numbers, etc., to ensure semantic coherence.\n- Output text in human-readable order, suitable for single-column, multi-column, and complex layouts.\n- Preserve the structure of the original document, including headings, paragraphs, lists, etc.\n- Extract images, image descriptions, tables, table titles, and footnotes.\n- Automatically recognize and convert formulas in the document to LaTeX format.\n- Automatically recognize and convert tables in the document to HTML format.\n- Automatically detect scanned PDFs and garbled PDFs and enable OCR functionality.\n- OCR supports detection and recognition of 84 languages.\n- Supports multiple output formats, such as multimodal and NLP Markdown, JSON sorted by reading order, and rich intermediate formats.\n- Supports various visualization results, including layout visualization and span visualization, for efficient confirmation of output quality.\n- Supports running in a pure CPU environment, and also supports GPU(CUDA)/NPU(CANN)/MPS acceleration\n- Compatible with Windows, Linux, and Mac platforms.\n\n## Quick Start\n\nIf you encounter any installation issues, please first consult the \u003ca href=\"#faq\"\u003eFAQ\u003c/a\u003e. \u003c/br\u003e\nIf the parsing results are not as expected, refer to the \u003ca href=\"#known-issues\"\u003eKnown Issues\u003c/a\u003e. \u003c/br\u003e\nThere are three different ways to experience MinerU:\n\n- [Online Demo (No Installation Required)](#online-demo)\n- [Quick CPU Demo (Windows, Linux, Mac)](#quick-cpu-demo)\n- Accelerate inference by using CUDA/CANN/MPS\n  - [Linux/Windows + CUDA](#Using-GPU)\n  - [Linux + CANN](#using-npu)\n  - [MacOS + MPS](#using-mps)\n\n\u003e [!WARNING]\n\u003e **Pre-installation Notice—Hardware and Software Environment Support**\n\u003e\n\u003e To ensure the stability and reliability of the project, we only optimize and test for specific hardware and software environments during development. This ensures that users deploying and running the project on recommended system configurations will get the best performance with the fewest compatibility issues.\n\u003e\n\u003e By focusing resources on the mainline environment, our team can more efficiently resolve potential bugs and develop new features.\n\u003e\n\u003e In non-mainline environments, due to the diversity of hardware and software configurations, as well as third-party dependency compatibility issues, we cannot guarantee 100% project availability. Therefore, for users who wish to use this project in non-recommended environments, we suggest carefully reading the documentation and FAQ first. Most issues already have corresponding solutions in the FAQ. We also encourage community feedback to help us gradually expand support.\n\n\u003ctable\u003e\n    \u003ctr\u003e\n        \u003ctd colspan=\"3\" rowspan=\"2\"\u003eOperating System\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd\u003eLinux after 2019\u003c/td\u003e\n        \u003ctd\u003eWindows 10 / 11\u003c/td\u003e\n        \u003ctd\u003emacOS 11+\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd colspan=\"3\"\u003eCPU\u003c/td\u003e\n        \u003ctd\u003ex86_64 / arm64\u003c/td\u003e\n        \u003ctd\u003ex86_64(unsupported ARM Windows)\u003c/td\u003e\n        \u003ctd\u003ex86_64 / arm64\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd colspan=\"3\"\u003eMemory Requirements\u003c/td\u003e\n        \u003ctd colspan=\"3\"\u003e16GB or more, recommended 32GB+\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd colspan=\"3\"\u003eStorage Requirements\u003c/td\u003e\n        \u003ctd colspan=\"3\"\u003e20GB or more, with a preference for SSD\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd colspan=\"3\"\u003ePython Version\u003c/td\u003e\n        \u003ctd colspan=\"3\"\u003e3.10(Please make sure to create a Python 3.10 virtual environment using conda)\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd colspan=\"3\"\u003eNvidia Driver Version\u003c/td\u003e\n        \u003ctd\u003elatest (Proprietary Driver)\u003c/td\u003e\n        \u003ctd\u003elatest\u003c/td\u003e\n        \u003ctd\u003eNone\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd colspan=\"3\"\u003eCUDA Environment\u003c/td\u003e\n        \u003ctd\u003eAutomatic installation [12.1 (pytorch) + 11.8 (paddle)]\u003c/td\u003e\n        \u003ctd\u003e11.8 (manual installation) + cuDNN v8.7.0 (manual installation)\u003c/td\u003e\n        \u003ctd\u003eNone\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd colspan=\"3\"\u003eCANN Environment(NPU support)\u003c/td\u003e\n        \u003ctd\u003e8.0+(Ascend 910b)\u003c/td\u003e\n        \u003ctd\u003eNone\u003c/td\u003e\n        \u003ctd\u003eNone\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd rowspan=\"2\"\u003eGPU Hardware Support List\u003c/td\u003e\n        \u003ctd colspan=\"2\"\u003eGPU VRAM 8GB or more\u003c/td\u003e\n        \u003ctd colspan=\"2\"\u003e2080~2080Ti / 3060Ti~3090Ti / 4060~4090\u003cbr\u003e\n        8G VRAM can enable all acceleration features\u003c/td\u003e\n        \u003ctd rowspan=\"2\"\u003eNone\u003c/td\u003e\n    \u003c/tr\u003e\n\u003c/table\u003e\n\n### Online Demo\n\nSynced with dev branch updates:\n\n[![OpenDataLab](https://img.shields.io/badge/Demo_on_OpenDataLab-blue?logo=data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTM0IiBoZWlnaHQ9IjEzNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cGF0aCBkPSJtMTIyLDljMCw1LTQsOS05LDlzLTktNC05LTksNC05LDktOSw5LDQsOSw5eiIgZmlsbD0idXJsKCNhKSIvPjxwYXRoIGQ9Im0xMjIsOWMwLDUtNCw5LTksOXMtOS00LTktOSw0LTksOS05LDksNCw5LDl6IiBmaWxsPSIjMDEwMTAxIi8+PHBhdGggZD0ibTkxLDE4YzAsNS00LDktOSw5cy05LTQtOS05LDQtOSw5LTksOSw0LDksOXoiIGZpbGw9InVybCgjYikiLz48cGF0aCBkPSJtOTEsMThjMCw1LTQsOS05LDlzLTktNC05LTksNC05LDktOSw5LDQsOSw5eiIgZmlsbD0iIzAxMDEwMSIvPjxwYXRoIGZpbGwtcnVsZT0iZXZlbm9kZCIgY2xpcC1ydWxlPSJldmVub2RkIiBkPSJtMzksNjJjMCwxNiw4LDMwLDIwLDM4LDctNiwxMi0xNiwxMi0yNlY0OWMwLTQsMy03LDYtOGw0Ni0xMmM1LTEsMTEsMywxMSw4djMxYzAsMzctMzAsNjYtNjYsNjYtMzcsMC02Ni0zMC02Ni02NlY0NmMwLTQsMy03LDYtOG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gyPSI3NSIgeTI9IjEyMCIgZ3JhZGllbnRVbml0cz0idXNlclNwYWNlT25Vc2UiPjxzdG9wIHN0b3AtY29sb3I9IiNmZmYiLz48c3RvcCBvZmZzZXQ9IjEiIHN0b3AtY29sb3I9IiMyZTJlMmUiLz48L2xpbmVhckdyYWRpZW50PjwvZGVmcz48L3N2Zz4=\u0026labelColor=white)](https://mineru.net/OpenSourceTools/Extractor?source=github)\n[![HuggingFace](https://img.shields.io/badge/Demo_on_HuggingFace-yellow.svg?logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAF8AAABYCAMAAACkl9t/AAAAk1BMVEVHcEz/nQv/nQv/nQr/nQv/nQr/nQv/nQv/nQr/wRf/txT/pg7/yRr/rBD/zRz/ngv/oAz/zhz/nwv/txT/ngv/0B3+zBz/nQv/0h7/wxn/vRb/thXkuiT/rxH/pxD/ogzcqyf/nQvTlSz/czCxky7/SjifdjT/Mj3+Mj3wMj15aTnDNz+DSD9RTUBsP0FRO0Q6O0WyIxEIAAAAGHRSTlMADB8zSWF3krDDw8TJ1NbX5efv8ff9/fxKDJ9uAAAGKklEQVR42u2Z63qjOAyGC4RwCOfB2JAGqrSb2WnTw/1f3UaWcSGYNKTdf/P+mOkTrE+yJBulvfvLT2A5ruenaVHyIks33npl/6C4s/ZLAM45SOi/1FtZPyFur1OYofBX3w7d54Bxm+E8db+nDr12ttmESZ4zludJEG5S7TO72YPlKZFyE+YCYUJTBZsMiNS5Sd7NlDmKM2Eg2JQg8awbglfqgbhArjxkS7dgp2RH6hc9AMLdZYUtZN5DJr4molC8BfKrEkPKEnEVjLbgW1fLy77ZVOJagoIcLIl+IxaQZGjiX597HopF5CkaXVMDO9Pyix3AFV3kw4lQLCbHuMovz8FallbcQIJ5Ta0vks9RnolbCK84BtjKRS5uA43hYoZcOBGIG2Epbv6CvFVQ8m8loh66WNySsnN7htL58LNp+NXT8/PhXiBXPMjLSxtwp8W9f/1AngRierBkA+kk/IpUSOeKByzn8y3kAAAf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Y7cgX4gHwclQKl1zhx0THf+tCAUValzjI7Wg9EhptrkIcfIJjA94evOn8B2eHaVzvBrnl2ig0So6hvPaz0IGcOvTHvUIlE2+prqAxLSQxZlU2stql1NqCCLdIiIN/i1DBEHUoElM9dBravbiAnKqgpi4IBkw+utSPIoBijDXJipSVV7MpOEJUAc5Qmm3BnUN+w3hteEieYKfRZSIUcXKMVf0u5wD4EwsUNVvZOtUT7A2GkffHjByWpHqvRBYrTV72a6j8zZ6W0DTE86Hn04bmyWX3Ri9WH7ZU6Q7h+ZHo0nHUAcsQvVhXRDZHChwiyi/hnPuOsSEF6Exk3o6Y9DT1eZ+6cASXk2Y9k+6EOQMDGm6WBK10wOQJCBwren86cPPWUcRAnTVjGcU1LBgs9FURiX/e6479yZcLwCBmTxiawEwrOcleuu12t3tbLv/N4RLYIBhYexm7Fcn4OJcn0+zc+s8/VfPeddZHAGN6TT8eGczHdR/Gts1/MzDkThr23zqrVfAMFT33Nx1RJsx1k5zuWILLnG/vsH+Fv5D4NTVcp1Gzo8AAAAAElFTkSuQmCC\u0026labelColor=white)](https://huggingface.co/spaces/opendatalab/MinerU)\n[![ModelScope](https://img.shields.io/badge/Demo_on_ModelScope-purple?logo=data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjIzIiBoZWlnaHQ9IjIwMCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KCiA8Zz4KICA8dGl0bGU+TGF5ZXIgMTwvdGl0bGU+CiAgPHBhdGggaWQ9InN2Z18xNCIgZmlsbD0iIzYyNGFmZiIgZD0ibTAsODkuODRsMjUuNjUsMGwwLDI1LjY0OTk5bC0yNS42NSwwbDAsLTI1LjY0OTk5eiIvPgogIDxwYXRoIGlkPSJzdmdfMTUiIGZpbGw9IiM2MjRhZmYiIGQ9Im05OS4xNCwxMTUuNDlsMjUuNjUsMGwwLDI1LjY1bC0yNS42NSwwbDAsLTI1LjY1eiIvPgogIDxwYXRoIGlkPSJzdmdfMT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ii8+CiAgPHBhdGggaWQ9InN2Z18yNCIgZmlsbD0iIzYyNGFmZiIgZD0ibTQ3Ljg0LDExNS40OWwtMjIuMTksMGwwLDQ3Ljg0bDQ3Ljg0LDBsMCwtMjIuMTlsLTI1LjY1LDBsMCwtMjUuNjV6Ii8+CiA8L2c+Cjwvc3ZnPg==\u0026labelColor=white)](https://www.modelscope.cn/studios/OpenDataLab/MinerU)\n\n### Quick CPU Demo\n\n#### 1. Install magic-pdf\n\n```bash\nconda create -n mineru python=3.10\nconda activate mineru\npip install -U \"magic-pdf[full]\" --extra-index-url https://wheels.myhloli.com\n```\n\n#### 2. Download model weight files\n\nRefer to [How to Download Model Files](docs/how_to_download_models_en.md) for detailed instructions.\n\n#### 3. Modify the Configuration File for Additional Configuration\n\nAfter completing the [2. Download model weight files](#2-download-model-weight-files) step, the script will automatically generate a `magic-pdf.json` file in the user directory and configure the default model path.\nYou can find the `magic-pdf.json` file in your 【user directory】.\n\n\u003e [!TIP]\n\u003e The user directory for Windows is \"C:\\\\Users\\\\username\", for Linux it is \"/home/username\", and for macOS it is \"/Users/username\".\n\nYou can modify certain configurations in this file to enable or disable features, such as table recognition:\n\n\n\u003e [!NOTE]\n\u003e If the following items are not present in the JSON, please manually add the required items and remove the comment content (standard JSON does not support comments).\n\n```json\n{\n    // other config\n    \"layout-config\": {\n        \"model\": \"doclayout_yolo\" // Please change to \"layoutlmv3\" when using layoutlmv3.\n    },\n    \"formula-config\": {\n        \"mfd_model\": \"yolo_v8_mfd\",\n        \"mfr_model\": \"unimernet_small\",\n        \"enable\": true  // The formula recognition feature is enabled by default. If you need to disable it, please change the value here to \"false\".\n    },\n    \"table-config\": {\n        \"model\": \"rapid_table\",  // Default to using \"rapid_table\", can be switched to \"tablemaster\" or \"struct_eqtable\".\n        \"sub_model\": \"slanet_plus\",  // When the model is \"rapid_table\", you can choose a sub_model. The options are \"slanet_plus\" and \"unitable\"\n        \"enable\": true, // The table recognition feature is enabled by default. If you need to disable it, please change the value here to \"false\".\n        \"max_time\": 400\n    }\n}\n```\n\n### Using GPU\n\nIf your device supports CUDA and meets the GPU requirements of the mainline environment, you can use GPU acceleration. Please select the appropriate guide based on your system:\n\n- [Ubuntu 22.04 LTS + GPU](docs/README_Ubuntu_CUDA_Acceleration_en_US.md)\n- [Windows 10/11 + GPU](docs/README_Windows_CUDA_Acceleration_en_US.md)\n- Quick Deployment with Docker\n\u003e [!IMPORTANT]\n\u003e Docker requires a GPU with at least 8GB of VRAM, and all acceleration features are enabled by default.\n\u003e\n\u003e Before running this Docker, you can use the following command to check if your device supports CUDA acceleration on Docker.\n\u003e \n\u003e ```bash\n\u003e docker run --rm --gpus=all nvidia/cuda:12.1.0-base-ubuntu22.04 nvidia-smi\n\u003e ```\n  ```bash\n  wget https://github.com/opendatalab/MinerU/raw/master/docker/global/Dockerfile -O Dockerfile\n  docker build -t mineru:latest .\n  docker run -it --name mineru --gpus=all mineru:latest /bin/bash -c \"echo 'source /opt/mineru_venv/bin/activate' \u003e\u003e ~/.bashrc \u0026\u0026 exec bash\"\n  magic-pdf --help\n  ```\n\n### Using NPU\n\nIf your device has NPU acceleration hardware, you can follow the tutorial below to use NPU acceleration:\n\n[Ascend NPU Acceleration](docs/README_Ascend_NPU_Acceleration_zh_CN.md)\n\n### Using MPS\n\nIf your device uses Apple silicon chips, you can enable MPS acceleration for certain supported tasks (such as layout detection and formula detection).\n\nYou can enable MPS acceleration by setting the `device-mode` parameter to `mps` in the `magic-pdf.json` configuration file.\n\n```json\n{\n    // other config\n    \"device-mode\": \"mps\"\n}\n```\n\n\u003e [!TIP]\n\u003e Since the formula recognition task cannot utilize MPS acceleration, you can disable the formula recognition feature in tasks where it is not needed to achieve optimal performance.\n\u003e\n\u003e You can disable the formula recognition feature by setting the `enable` parameter in the `formula-config` section to `false`.\n\n## Usage\n\n### Command Line\n\n[Using MinerU via Command Line](https://mineru.readthedocs.io/en/latest/user_guide/usage/command_line.html)\n\n\u003e [!TIP]\n\u003e For more information about the output files, please refer to the [Output File Description](docs/output_file_en_us.md).\n\n### API\n\n[Using MinerU via Python API](https://mineru.readthedocs.io/en/latest/user_guide/usage/api.html)\n\n\n### Deploy Derived Projects\n\nDerived projects include secondary development projects based on MinerU by project developers and community developers,  \nsuch as application interfaces based on Gradio, RAG based on llama, web demos similar to the official website, lightweight multi-GPU load balancing client/server ends, etc.\nThese projects may offer more features and a better user experience.  \nFor specific deployment methods, please refer to the [Derived Project README](projects/README.md)\n\n\n### Development Guide\n\nTODO\n\n# TODO\n\n- [x] Reading order based on the model  \n- [x] Recognition of `index` and `list` in the main text  \n- [x] Table recognition\n- [x] Heading Classification\n- [ ] Code block recognition in the main text\n- [ ] [Chemical formula recognition](docs/chemical_knowledge_introduction/introduction.pdf)\n- [ ] Geometric shape recognition\n\n# Known Issues\n\n- Reading order is determined by the model based on the spatial distribution of readable content, and may be out of order in some areas under extremely complex layouts.\n- Vertical text is not supported.\n- Tables of contents and lists are recognized through rules, and some uncommon list formats may not be recognized.\n- Code blocks are not yet supported in the layout model.\n- Comic books, art albums, primary school textbooks, and exercises cannot be parsed well.\n- Table recognition may result in row/column recognition errors in complex tables.\n- OCR recognition may produce inaccurate characters in PDFs of lesser-known languages (e.g., diacritical marks in Latin script, easily confused characters in Arabic script).\n- Some formulas may not render correctly in Markdown.\n\n# FAQ\n\n[FAQ in Chinese](docs/FAQ_zh_cn.md)\n\n[FAQ in English](docs/FAQ_en_us.md)\n\n# All Thanks To Our Contributors\n\n\u003ca href=\"https://github.com/opendatalab/MinerU/graphs/contributors\"\u003e\n  \u003cimg src=\"https://contrib.rocks/image?repo=opendatalab/MinerU\" /\u003e\n\u003c/a\u003e\n\n# License Information\n\n[LICENSE.md](LICENSE.md)\n\nThis project currently uses PyMuPDF to achieve advanced functionality. However, since it adheres to the AGPL license, it may impose restrictions on certain usage scenarios. In future iterations, we plan to explore and replace it with a more permissive PDF processing library to enhance user-friendliness and flexibility.\n\n# Acknowledgments\n\n- [PDF-Extract-Kit](https://github.com/opendatalab/PDF-Extract-Kit)\n- [DocLayout-YOLO](https://github.com/opendatalab/DocLayout-YOLO)\n- [StructEqTable](https://github.com/UniModal4Reasoning/StructEqTable-Deploy)\n- [RapidTable](https://github.com/RapidAI/RapidTable)\n- [PaddleOCR](https://github.com/PaddlePaddle/PaddleOCR)\n- [PyMuPDF](https://github.com/pymupdf/PyMuPDF)\n- [layoutreader](https://github.com/ppaanngggg/layoutreader)\n- [fast-langdetect](https://github.com/LlmKira/fast-langdetect)\n- [pdfminer.six](https://github.com/pdfminer/pdfminer.six)\n\n# Citation\n\n```bibtex\n@misc{wang2024mineruopensourcesolutionprecise,\n      title={MinerU: An Open-Source Solution for Precise Document Content Extraction}, \n      author={Bin Wang and Chao Xu and Xiaomeng Zhao and Linke Ouyang and Fan Wu and Zhiyuan Zhao and Rui Xu and Kaiwen Liu and Yuan Qu and Fukai Shang and Bo Zhang and Liqun Wei and Zhihao Sui and Wei Li and Botian Shi and Yu Qiao and Dahua Lin and Conghui He},\n      year={2024},\n      eprint={2409.18839},\n      archivePrefix={arXiv},\n      primaryClass={cs.CV},\n      url={https://arxiv.org/abs/2409.18839}, \n}\n\n@article{he2024opendatalab,\n  title={Opendatalab: Empowering general artificial intelligence with open datasets},\n  author={He, Conghui and Li, Wei and Jin, Zhenjiang and Xu, Chao and Wang, Bin and Lin, Dahua},\n  journal={arXiv preprint arXiv:2407.13773},\n  year={2024}\n}\n```\n\n# Star History\n\n\u003ca\u003e\n \u003cpicture\u003e\n   \u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"https://api.star-history.com/svg?repos=opendatalab/MinerU\u0026type=Date\u0026theme=dark\" /\u003e\n   \u003csource media=\"(prefers-color-scheme: light)\" srcset=\"https://api.star-history.com/svg?repos=opendatalab/MinerU\u0026type=Date\" /\u003e\n   \u003cimg alt=\"Star History Chart\" src=\"https://api.star-history.com/svg?repos=opendatalab/MinerU\u0026type=Date\" /\u003e\n \u003c/picture\u003e\n\u003c/a\u003e\n\n# Magic-doc\n\n[Magic-Doc](https://github.com/InternLM/magic-doc) Fast speed ppt/pptx/doc/docx/pdf extraction tool\n\n# Magic-html\n\n[Magic-HTML](https://github.com/opendatalab/magic-html) Mixed web page extraction tool\n\n# Links\n\n- [LabelU (A Lightweight Multi-modal Data Annotation Tool)](https://github.com/opendatalab/labelU)\n- [LabelLLM (An Open-source LLM Dialogue Annotation Platform)](https://github.com/opendatalab/LabelLLM)\n- [PDF-Extract-Kit (A Comprehensive Toolkit for High-Quality PDF Content Extraction)](https://github.com/opendatalab/PDF-Extract-Kit)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopendatalab%2FMinerU","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopendatalab%2FMinerU","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopendatalab%2FMinerU/lists"}