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.0.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.0-py3-none-any.whl (33.1 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for oks_connector-0.1.0.tar.gz
Algorithm Hash digest
SHA256 14ea9df5215e5f31d8a4c7321d5487785ff216bda96f3e8ab877335a0d40b16b
MD5 bd077786fdf7d61a97298e2e361ef986
BLAKE2b-256 9a1559140258aad7839b02c1b731803fca8f5462b5b60bae4b54c2a685130b44

See more details on using hashes here.

Provenance

The following attestation bundles were made for oks_connector-0.1.0.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.0-py3-none-any.whl.

File metadata

  • Download URL: oks_connector-0.1.0-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.12

File hashes

Hashes for oks_connector-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 deae57591f612cef3f857c2fee27ad3f5c2046a808941df962842ac374bbd45a
MD5 95221348c6aa288dbb57fb42ee3f439c
BLAKE2b-256 4a4a04c298b2a0f82a0db66f3100da6a831012f548b5a26aa208bb33c76e2794

See more details on using hashes here.

Provenance

The following attestation bundles were made for oks_connector-0.1.0-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