Skip to main content

ONEX Core Framework - Base classes and essential implementations

Project description

omnibase_core

Contract-driven execution layer for agent tools and workflows.

CI Python 3.12+ License: MIT

Install

uv add omnibase_core

Minimal Example

Every ONEX node starts as a contract-driven declaration with zero custom code:

from omnibase_core.nodes import NodeCompute

class NodeMyFeature(NodeCompute):
    pass  # All behavior driven by contract YAML

The contract YAML defines inputs, outputs, state transitions, and configuration:

name: node_my_feature
version: 1.0.0
type: COMPUTE
input_schema: MyInput
output_schema: MyOutput

When you need custom logic, opt in by overriding process():

class NodeMyFeature(NodeCompute):
    async def process(self, input_data):
        # Custom logic here
        return {"result": input_data.value * 2}

Why ONEX

Problem ONEX Solution
Inconsistent tool I/O Typed schemas (Pydantic + protocols)
Implicit state Deterministic lifecycle with contract FSMs
Opaque failures Structured errors with ModelOnexError
Framework lock-in Framework-agnostic protocol design
Untestable tools Pure nodes with injected dependencies

Key Features

  • Four-node architecture: EFFECT (I/O), COMPUTE (transform), REDUCER (aggregate), ORCHESTRATOR (coordinate) -- details
  • Contract-driven execution: YAML contracts define behavior; code is opt-in
  • Protocol-driven DI: ModelONEXContainer for dependency injection
  • Structured errors: ModelOnexError with proper error codes and traceability
  • Event system: ModelEventEnvelope for event-driven communication
  • 40+ mixins: Reusable behavior modules for common patterns
  • Subcontracts: Declarative configuration for FSM, caching, routing, and more
  • 12,000+ tests: Comprehensive test suite with strict type checking

Documentation

License

MIT

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

omnibase_core-0.38.0.tar.gz (8.1 MB view details)

Uploaded Source

Built Distribution

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

omnibase_core-0.38.0-py3-none-any.whl (5.4 MB view details)

Uploaded Python 3

File details

Details for the file omnibase_core-0.38.0.tar.gz.

File metadata

  • Download URL: omnibase_core-0.38.0.tar.gz
  • Upload date:
  • Size: 8.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.3 {"installer":{"name":"uv","version":"0.11.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for omnibase_core-0.38.0.tar.gz
Algorithm Hash digest
SHA256 1667dd1047f937e5239a10a9443f754c0079b1fd8d58a061b73b0b900bdc6204
MD5 359d40b354d82f18fded6d9943dcbf12
BLAKE2b-256 3ff09c2971cc3328ca592f19da9afe3b95317de52d476f8b80f6ca03a273254f

See more details on using hashes here.

File details

Details for the file omnibase_core-0.38.0-py3-none-any.whl.

File metadata

  • Download URL: omnibase_core-0.38.0-py3-none-any.whl
  • Upload date:
  • Size: 5.4 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.3 {"installer":{"name":"uv","version":"0.11.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for omnibase_core-0.38.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3ce216b042440e62db1959dd930f6807424de8511b0b03cf89a9868ead0c491a
MD5 51a2bcf01b40c026830e71d130e9d2f3
BLAKE2b-256 6bdd3061cb53bdd9725c216788652860d94bde720ae8883090ac4f18237faec4

See more details on using hashes here.

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