Simplify processors#231
Draft
AZOGOAT wants to merge 16 commits into
Draft
Conversation
…ocessorConfig(ProcessorConfig) for the only processor with extra settings + Add ProcessorRegistry.get_by_name()
Collaborator
|
I'll solve the merge conflicts Update: done |
Collaborator
383501f to
b47a6bf
Compare
Introduces a new optional PDF processor based on pymupdf4llm, opt-in via
`file_type_processors: { .pdf: PyMuPDF4LLMProcessor }`. Faster than the
default marker-based PDFProcessor and produces LLM-friendly markdown,
without GPU OCR. PDFProcessor remains the default.
Adds an opt-in `pymupdf4llm` backend to PDFProcessor, configured via the
`processors:` block (same style as MediaProcessor). Faster than the
default marker-based extraction and produces LLM-friendly markdown,
without GPU OCR. The marker backend remains the default.
Usage:
processors:
PDFProcessor:
backend: pymupdf4llm
…/mmore into task-simplify-processors
Adds a third PDF extraction backend, `mistral`, exposed under the `processors:` block alongside `marker` (default) and `pymupdf4llm`. Adapts the CloudPDFProcessor work from upstream PR (issue EPFLiGHT#15) and integrates it as a backend of PDFProcessor for a unified config UX. - Mistral OCR call via the official `mistralai` SDK with PDF base64 encoding and base64 image decoding for extracted figures. - Asyncio rate limiter (`mistral_max_calls_per_second`) to maximise throughput without hitting Mistral's 429 - Too Many Requests, plus exponential backoff retries on transient failures. - API key read from MISTRAL_API_KEY (loaded via python-dotenv in run_process) — no key in the YAML config.
1b215e3 to
b35da8a
Compare
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes : #79
Closes : #191