Skip to main content

ConvertDocumentsRequestOptions

Struct ConvertDocumentsRequestOptions 

Source
pub struct ConvertDocumentsRequestOptions {
Show 29 fields pub from_formats: Option<Vec<InputFormat>>, pub to_formats: Option<Vec<OutputFormat>>, pub image_export_mode: Option<ImageRefMode>, pub do_ocr: Option<bool>, pub force_ocr: Option<bool>, pub ocr_engine: Option<OcrEngine>, pub ocr_lang: Option<Vec<String>>, pub pdf_backend: Option<PdfBackend>, pub table_mode: Option<TableFormerMode>, pub table_cell_matching: Option<bool>, pub pipeline: Option<ProcessingPipeline>, pub page_range: Option<(i64, i64)>, pub document_timeout: Option<f64>, pub abort_on_error: Option<bool>, pub do_table_structure: Option<bool>, pub include_images: Option<bool>, pub images_scale: Option<f64>, pub md_page_break_placeholder: Option<String>, pub do_code_enrichment: Option<bool>, pub do_formula_enrichment: Option<bool>, pub do_picture_classification: Option<bool>, pub do_chart_extraction: Option<bool>, pub do_picture_description: Option<bool>, pub picture_description_area_threshold: Option<f64>, pub vlm_pipeline_model: Option<VlmModelType>, pub picture_description_local: Option<Value>, pub picture_description_api: Option<Value>, pub vlm_pipeline_model_local: Option<Value>, pub vlm_pipeline_model_api: Option<Value>,
}
Expand description

Options for document conversion. All fields are optional — the server applies sensible defaults for any omitted field.

Fields§

§from_formats: Option<Vec<InputFormat>>

Input format(s) to convert from.

§to_formats: Option<Vec<OutputFormat>>

Output format(s) to convert to. Defaults to ["md"].

§image_export_mode: Option<ImageRefMode>

Image export mode. Defaults to embedded.

§do_ocr: Option<bool>

Enable OCR processing. Defaults to true.

§force_ocr: Option<bool>

Force OCR over existing text. Defaults to false.

§ocr_engine: Option<OcrEngine>

OCR engine to use. Defaults to easyocr.

§ocr_lang: Option<Vec<String>>

Languages for the OCR engine.

§pdf_backend: Option<PdfBackend>

PDF parsing backend. Defaults to dlparse_v4.

§table_mode: Option<TableFormerMode>

Table structure extraction mode. Defaults to accurate.

§table_cell_matching: Option<bool>

Match table cell predictions back to PDF cells. Defaults to true.

§pipeline: Option<ProcessingPipeline>

Processing pipeline. Defaults to standard.

§page_range: Option<(i64, i64)>

Page range to convert [start, end]. Pages start at 1.

§document_timeout: Option<f64>

Per-document processing timeout in seconds. Defaults to 604800.

§abort_on_error: Option<bool>

Abort on error. Defaults to false.

§do_table_structure: Option<bool>

Extract table structure. Defaults to true.

§include_images: Option<bool>

Extract images from documents. Defaults to true.

§images_scale: Option<f64>

Scale factor for images. Defaults to 2.0.

§md_page_break_placeholder: Option<String>

Placeholder between pages in markdown output.

§do_code_enrichment: Option<bool>

Enable OCR code enrichment. Defaults to false.

§do_formula_enrichment: Option<bool>

Enable formula OCR (LaTeX). Defaults to false.

§do_picture_classification: Option<bool>

Enable picture classification. Defaults to false.

§do_chart_extraction: Option<bool>

Enable chart data extraction. Defaults to false.

§do_picture_description: Option<bool>

Enable picture description. Defaults to false.

§picture_description_area_threshold: Option<f64>

Minimum area percentage for picture processing. Defaults to 0.05.

§vlm_pipeline_model: Option<VlmModelType>

VLM pipeline model preset.

§picture_description_local: Option<Value>

Options for running a local VLM for picture description. Pass as a JSON object. Mutually exclusive with picture_description_api.

§picture_description_api: Option<Value>

API details for a VLM used for picture description. Pass as a JSON object. Mutually exclusive with picture_description_local.

§vlm_pipeline_model_local: Option<Value>

Options for running a local VLM for the VLM pipeline. Pass as a JSON object. Mutually exclusive with vlm_pipeline_model_api and vlm_pipeline_model.

§vlm_pipeline_model_api: Option<Value>

API details for a VLM used in the VLM pipeline. Pass as a JSON object. Mutually exclusive with vlm_pipeline_model_local and vlm_pipeline_model.

Trait Implementations§

Source§

impl Clone for ConvertDocumentsRequestOptions

Source§

fn clone(&self) -> ConvertDocumentsRequestOptions

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for ConvertDocumentsRequestOptions

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for ConvertDocumentsRequestOptions

Source§

fn default() -> ConvertDocumentsRequestOptions

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for ConvertDocumentsRequestOptions

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Serialize for ConvertDocumentsRequestOptions

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,