- **Bulk PDF import driver** (`scripts/bulk_import/oc_bulk_import.py`, with `README.md` and `tests/`) — a resumable, client-side CLI for loading very large local PDF trees (100K+ files) into a corpus. It packs files into right-sized ZIP batches (under the server's file/size/folder import caps), submits them through the existing `POST /api/imports/zip-to-corpus/` endpoint (mirroring the local folder tree and running the normal parse pipeline), and records progress in a SQLite ledger so crashes/`Ctrl-C` never lose work. Re-runs are idempotent because re-importing the same relative path upversions rather than duplicating. The driver paces itself against the live corpus parse backlog (`documentStats.processingCount`) since the server has no built-in backpressure, and reconciles completion by corpus document count (the `zip-to-corpus` `job_id` is not pollable). Operational tuning — notably disabling `ADD_DOCUMENT` CorpusActions during the load to avoid a per-document analysis fan-out, and raising `DOCUMENT_PROCESSING_STALE_MINUTES` so the stuck-document reconciler does not false-fail a deep backlog — is documented in the README and `docs/test_scripts/bulk_import_200k.md`.
- **Bulk import on Auth0 deployments via worker tokens.** The `/api/imports/zip-to-corpus/`, `/api/imports/documents/`, and `/api/imports/chunked/*` endpoints now also accept a `CorpusAccessToken` presented as `Authorization: WorkerKey <token>`, with the same trust model as `/api/worker-uploads/`: the corpus is taken from the token binding (a mismatched `corpus_id` is rejected 403), the usage-cap and `visible_to_user` gates are skipped, and imported documents are owned by the corpus creator. The JWT path is unchanged. This lets the bulk-import CLI authenticate on Auth0 backends (where the `tokenAuth` flow does not), via `--worker-token` / `OC_WORKER_TOKEN`.
- **Chunked transport in the bulk-import CLI.** Large ZIP batches and oversize (≥100 MB) single files now upload through the existing chunked endpoints (`start` → parts → `complete`), so they stream past reverse-proxy body limits and the server's in-memory buffer. Oversize single files preserve their nested folder via a new `add_to_folder_path` on the single-document import path.
