> ## Documentation Index
> Fetch the complete documentation index at: https://docs.trelent.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Processing config

> Control how each job handles documents and videos

Every `JobInput` accepts an optional `config` block. If you omit it, both SDKs inject defaults that match the values in `models.py` and `sdk/typescript/src/models.ts`. Override only what you need to keep jobs predictable and repeatable.

<Info>
  `config.documents` and `config.video` map 1:1 across the Python and TypeScript SDKs. You can mix overrides from both sections in the same job without providing the entire structure.
</Info>

<Steps>
  <Step title="Decide what needs tuning">
    List the behaviors you want to change (for example, reprocessing previously seen PDFs or sampling video frames more frequently). This keeps your overrides minimal.
  </Step>

  <Step title="Override the relevant section">
    Set `config.documents` or `config.video` fields directly inside the job payload. Defaults fill in any fields you skip.
  </Step>

  <Step title="Submit and verify">
    Send the job through the SDK or REST API. Monitor status using the Jobs endpoints to confirm the config produced the expected behavior.
  </Step>
</Steps>

<Columns cols={2}>
  <Card title="Document config" icon="file" href="/data-ingestion/config/documents" arrow="true" cta="Tune document processing">
    Control reprocessing and element extraction for PDFs, office docs, and text.
  </Card>

  <Card title="Video config" icon="film" href="/data-ingestion/config/video" arrow="true" cta="Tune video processing">
    Adjust screenshot cadence, sensitivity, token budgets, and advanced SSIM thresholds.
  </Card>
</Columns>

<CodeGroup>
  ```ts TypeScript theme={null}
  import type { JobInput } from "@trelent/data-ingestion";

  const job: JobInput = {
    connector: {
      type: "url",
      urls: ["https://signed.example.com/sample.pdf"],
    },
    output: { type: "s3-signed-url" },
    config: {
      documents: {
        reprocess_documents: false,
        extract_elements: true,
      },
      video: {
        screenshot_interval_seconds: 2,
        sensitivity: 0.2,
      },
    },
  };
  ```

  ```python Python theme={null}
  from trelent_data_ingestion_sdk.models import JobInput, UrlConnector, S3SignedUrlOutput, ProcessConfig, ProcessDocumentsConfig, ProcessVideoConfig

  job = JobInput(
      connector=UrlConnector(urls=["https://signed.example.com/sample.pdf"]),
      output=S3SignedUrlOutput(),
      config=ProcessConfig(
          documents=ProcessDocumentsConfig(
              reprocess_documents=False,
              extract_elements=True,
          ),
          video=ProcessVideoConfig(
              screenshot_interval_seconds=2,
              sensitivity=0.2,
          ),
      ),
  )
  ```
</CodeGroup>
