Skip to main content

oks-connector

Independent Level-1 multimodal extractor for Open Knowledge Studio. It converts video / audio / image / Office / PDF sources into an OKS Raw Bundle (content.md + evidence.jsonl provenance sidecar).

This package is deliberately separate from the OKS core (oks / cli/):

  • Per CONSTITUTION P4/P5, the OKS core stays API-free and never wraps tools at runtime. Extractors are L1 capabilities the Agent spawns via Bash, guided by the routing table in settings/handlers.json.
  • Per the reframed A1, this is not a repo maintenance script (those stay in scripts/ inside the knowledge repo). It is an independently versioned, independently installed L1 tool — which is why it lives in its own package.

It never summarizes, corrects, grades, or promotes source content. Its only contract is faithful extraction plus provenance (P3: raw/ is mechanical).

Install

The core CLI is stdlib-only. Heavy extractors are opt-in extras, each best installed in its own isolated Python 3.12 interpreter (they pin conflicting heavyweight deps such as MinerU / PaddleOCR / faster-whisper):

# one interpreter per modality
pip install "oks-connector[document]"   # docx / pptx via markitdown
pip install "oks-connector[pdf]"        # PDF via MinerU
pip install "oks-connector[watch]"      # video / audio via faster-whisper + rapidocr
pip install "oks-connector[formula]"    # formula OCR via paddleocr

Use

oks-connector --version
oks-connector route  <source>                       # print the extraction plan
oks-connector image  <img>  --output <bundle_dir>   # OCR + bbox evidence
oks-connector markitdown <docx> --output <bundle_dir>
oks-connector mineru <mineru_result> --source <pdf> --output <bundle_dir>
oks-connector watch  <video> --output <bundle_dir>  # transcript + frames + OCR
oks-connector validate <bundle_dir>                 # check a bundle against v0.1

Output contract: raw-multimodal/v0.1 — see docs/raw-multimodal-standard.md in the OKS repo.

Wiring into the knowledge repo

Point settings/handlers.json command_argv at the installed entry point instead of the in-repo script path. For example:

"command_argv": ["{watch_python}", "-m", "raw_bundle_adapter", "watch", "{input}", "--output", "{output}"]

or, if the modality's interpreter is on PATH:

"command_argv": ["oks-connector", "watch", "{input}", "--output", "{output}"]

{watch_python} / {mineru_python} / {document_python} are resolved from settings/raw-tools.json so each modality can use its isolated environment.

Develop / test

python -m pytest scripts/tests -q

Metadata

Release files for oks-connector 0.5.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for oks-connector 0.5.0
File Size Uploaded Provenance
oks_connector-0.5.0.tar.gz 75.9 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for oks-connector 0.5.0
File Interpreter ABI Platform
oks_connector-0.5.0-py3-none-any.whl Python 3 none any Details

Total release size: 164.3 kB

Release files / oks_connector-0.5.0.tar.gz

Download URL oks_connector-0.5.0.tar.gz
Size 75.9 kB
Tags Source
SHA-256 checksum
How to use checksums
0c18da6ceb077f1a88397ba21b2ebee9553ff562ad7acb99a0478d63362a1f1f
BLAKE2b-256 checksum
How to use checksums
b841e6132ea16b9bab9c1ccb5e9cbf9fc048d042a85af2a498dbf41c118cf192
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 28, 2026.

Transparency log

Release files / oks_connector-0.5.0-py3-none-any.whl

Download URL oks_connector-0.5.0-py3-none-any.whl
Size 88.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5c3ef91631f6568fa3e2f54bc06c12faf8acb7badc2b2b28fede9cc59f61cf08
BLAKE2b-256 checksum
How to use checksums
e81b6992d2da5c7a3feb7500c17b632ec69b072c43e8ccbdefe3858320095f4b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 28, 2026.

Transparency log

Security for oks-connector 0.5.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for oks_connector-0.5.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 28, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page