Execution and orchestration environment around Core.
Core Runtime consumes Core (tradingchassis_core) and provides local/cluster entrypoints,
configuration, adapter integration, runtime packaging, and reproducible execution workflows.
Core Runtime is the runtime layer for executing Core semantics in concrete environments.
- local hftbacktest-backed backtest execution
- runtime entrypoints for orchestration flows
- reproducible dependency/runtime packaging
- CI and infrastructure wiring for deployment workflows
Core Runtime provides:
- executable runtime entrypoints (
core_runtime/...) - runtime configs and environment wiring
- adapter-facing integration layers around Core
- orchestration integration (Argo/Kubernetes)
- runtime validation and smoke/test workflows
Core Runtime is not the semantic source of truth for Core concepts.
It consumes Core and should not redefine canonical terms such as Event, Event Stream, Processing Order, State, or Risk Engine.
Current local smoke is usable from the core-runtime repository root:
python -m core_runtime.local.backtest --config core_runtime/local/local.jsonDefault output location:
.runtime/local/results/
This confirms current local usability and does not claim full canonical Event Stream completion.
From the core-runtime repository root:
python -m pip install -e .
python -m core_runtime.local.backtest --config core_runtime/local/local.jsonIf tradingchassis_core is not already resolvable in your environment, install core as a
sibling editable package in a monorepo workspace:
python -m pip install -e ../core| Mode | Entrypoint | Command shape | Notes |
|---|---|---|---|
| Local backtest | core_runtime/local/backtest.py |
python -m core_runtime.local.backtest --config core_runtime/local/local.json |
Main local runner. |
| Argo plan/run orchestration | core_runtime/backtest/runtime/entrypoint.py |
python -m core_runtime.backtest.runtime.entrypoint --config core_runtime/argo/argo.json --plan |
Planner and sweep-context emitter for Argo flow. |
| Sweep worker | core_runtime/backtest/runtime/run_sweep.py |
python -m core_runtime.backtest.runtime.run_sweep --context <path-to-sweep-json> |
Executes one sweep context. |
| Capability area | Status | Notes |
|---|---|---|
| Canonical runtime paths | Active | MarketEvent, OrderSubmittedEvent, ControlTimeEvent |
| Compatibility paths | Active | Post-submission order/fill progression via snapshots, OrderStateEvent, and DerivedFillEvent |
| Deferred capabilities | Deferred | Runtime FillEvent ingress, ExecutionFeedbackRecordSource, replay/storage/Event Stream persistence, ProcessingContext |
- Local hftbacktest flow is usable for current transitional runtime paths.
- Compatibility mechanisms remain in place for post-submission progression.
- Deferred capabilities are intentionally not presented as shipped runtime behavior.
MarketEventOrderSubmittedEventControlTimeEvent
- snapshot-based post-submission progression
OrderStateEventDerivedFillEvent
- runtime
FillEventingress ExecutionFeedbackRecordSource- replay/storage/Event Stream persistence
ProcessingContext
- Human-facing concept name: Core Runtime
- Distribution/project name:
tradingchassis-core-runtime - Python import package:
core_runtime - Core distribution/project name:
tradingchassis-core - Core Python import package:
tradingchassis_core
.github/workflows/ CI and deployment workflows
.github/argo-launchers/ Argo Workflow submit wrappers used by GitHub Actions
argo/templates/ Argo WorkflowTemplates shown in Argo UI
core_runtime/ Runtime entrypoints and execution modules
docs/ Runtime implementation notes
scripts/ Build/validation helper scripts
tests/ Runtime tests and deterministic fixtures
Primary local config:
core_runtime/local/local.json- OCI config template (for local object storage auth setups):
core_runtime/local/oci.config.example
Note: local JSON configs use cwd-relative paths for tests/data/... inputs and .runtime/...
outputs. The supported default workflow is to run commands from the core-runtime repo root.
python -m pip install -e .
python -m pytest -q tests
./scripts/check.shpython -m pip install -e core
python -m pip install -e core-runtime
python -m pytest -q core-runtime/tests
python -m pytest -q core/testsFrom core-runtime root:
python -m pytest -q tests
./scripts/check.shFrom monorepo root:
python -m pytest -q core-runtime/tests
python -m pytest -q core/testsCore provides deterministic semantics and domain contracts.
Core Runtime provides execution environments and orchestration around those semantics.
Core dependency can be pinned by commit SHA through environment configuration:
TRADINGCHASSIS_CORE_COMMIT=<commit-sha>To compile reproducible requirements:
./scripts/compile-requirements.shArtifacts:
requirements.txtrequirements-dev.txt
Argo WorkflowTemplates (visible in Argo UI) are defined in:
argo/templates/workflowtemplate-build-push-ghcr.yamlargo/templates/workflowtemplate-backtest-fanout.yaml
GitHub-only Argo submit wrappers are in:
.github/argo-launchers/run-build.yaml.github/argo-launchers/run-backtest.yaml
Automation that applies templates and starts workflows is in:
.github/workflows/argo-build-and-backtest.yaml
Use this model to avoid confusion:
argo/templates/*: reusableWorkflowTemplatedefinitions that appear in the Argo UI..github/argo-launchers/*: one-offWorkflowmanifests used by GitHub Actions withenvsubst.
Namespace intent:
dev: branch and development runs.prod: main branch and production-like runs.
Template: build-push-ghcr
Recommended parameters:
git_repo: keep defaulthttps://github.com/TradingChassis/core-runtime.git.image_repo: keep defaultghcr.io/tradingchassis/core-runtime.git_branch: set the branch name for tagging (defaultmain).core_runtime_commit: set to a real commit SHA (required).
Guardrails:
core_runtime_commitmust be a 7-40 character hex SHA.git_repomust be an HTTPS URL ending in.git.
Tagging behavior:
- always pushes
<image_repo>:<branch-tag> - always pushes
<image_repo>:<commit-sha> - also pushes
<image_repo>:latestwhengit_branch=main
Template: backtest-fanout
Recommended parameters:
image_repo: keep default.image_tag: set to the exact commit SHA built bybuild-push-ghcrfor reproducibility.experiment_config: keep default unless intentionally testing a different in-image config.scratch_root: keep default/mnt/scratch.
Guardrails:
- prefer commit SHA tags for
prodruns. - use mutable tags such as
latestonly for quick smoke checks.
Core Runtime and MLflow serve different purposes in cluster runs:
- Backtest output artifacts are written by Core Runtime directly to OCI Object Storage.
- MLflow is used for tracking metadata only (params, metrics, tags), not for artifact files.
Backtest artifact storage path:
- bucket:
data - prefix:
backtests/<experiment_id>/... - auth mode: OCI Instance Principals (IAM policy controlled)
Code anchors:
- backtest result download/upload pipeline:
core_runtime/backtest/runtime/run_sweep.py - OCI Object Storage adapter + auth behavior:
core_runtime/backtest/io/s3_adapter.py - MLflow tracking logger (no artifact logging):
core_runtime/backtest/runtime/mlflow_segment_logger.py
Tracking-only policy:
- MLflow run metadata remains in the backend store.
- MLflow artifact storage is intentionally unsupported in this setup.
- If a client starts calling artifact APIs (for example
mlflow.log_artifact(...)), treat failures as expected until artifact storage is intentionally added.
| Script | Purpose |
|---|---|
compile-requirements.sh |
Resolves dependencies and pins Core revision inputs |
post-create.sh |
Dev container bootstrap |
check.sh |
Local validation helpers |
- Runtime adapter design:
docs/venue-adapter-abstraction-design-v1.md - Shared terminology source of truth:
docs/docs/00-guides/terminology.md - Core library scope:
core/README.md
MIT licensed. Versioning follows semantic versioning.