Skip to main content

Independent Level-1 multimodal Raw-Bundle extractor for Open Knowledge Studio

Project description

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

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

oks_connector-0.1.1.tar.gz (31.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

oks_connector-0.1.1-py3-none-any.whl (33.1 kB view details)

Uploaded Python 3

File details

Details for the file oks_connector-0.1.1.tar.gz.

File metadata

  • Download URL: oks_connector-0.1.1.tar.gz
  • Upload date:
  • Size: 31.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for oks_connector-0.1.1.tar.gz
Algorithm Hash digest
SHA256 a6b76fb6566185918e3507247977425b36635e852466639bd92c086db2e17cb6
MD5 68c329febfeac210ddd102e084dc34c1
BLAKE2b-256 72084cd9a2bd09a2b3a482944c5ec16c2fa12e02ab44c7d8759cae3a14c3335d

See more details on using hashes here.

Provenance

The following attestation bundles were made for oks_connector-0.1.1.tar.gz:

Publisher: publish.yml on open-agent-power/oks-connector

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oks_connector-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: oks_connector-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 33.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for oks_connector-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 cd8b339920d1533964608b464970f487c991071db929c4f62c9374d161fc31b8
MD5 c95637575b83099fb7dde041d286e794
BLAKE2b-256 20f72a9b1aed2841d0e4f2ab1ce64fe88775e61e85879b2a1d2e1397074c6dfc

See more details on using hashes here.

Provenance

The following attestation bundles were made for oks_connector-0.1.1-py3-none-any.whl:

Publisher: publish.yml on open-agent-power/oks-connector

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page