This repository was archived by the owner on May 26, 2026. It is now read-only.
feat(kora): KR-KORA-PIP-RESTRUCTURE-PHASE-1 — isokron-client BYOA foundation + kora-runtime first pip package#209
Merged
Conversation
…ndation + kora-runtime first pip package Two new pip-installable packages under packages/, extracted from the in-tree code with full backward-compat shims: * packages/isokron-client/ — 20 substrate-functional modules lifted from plugins/memory/isokron/ (non-provider files only). Pure library with zero Kora / Hermes coupling at import time. ANY Hermes-based agent can `pip install isokron-client` to gain IsoKron substrate primitives: events / reads / control / scratchpad / policy / constitution / capability / sea_tickets. README §"BYOA usage example" shows a non-Kora custom plugin consuming the library. 5/5 dry-run wheel-install smoke tests pass in a clean venv. * packages/kora-runtime/ — 28 modules (7 sub-plugins + orchestrator) lifted from kora_cli/reasoning/kora_hermes_plugin/. Declares `isokron-client` as a PyPI dep; Hermes is source-only per the 2026-05-25 operator decision (README documents `git clone hermes-agent && pip install -e . && pip install kora-runtime`). Entry point `hermes_agent.plugins.kora = kora_runtime:register` validated via `importlib.metadata.entry_points()` after dry-run install. 5/5 dry-run wheel-install smoke tests + 142/151 in-tree tests pass (8 pre-existing Marvin data-dir failures unrelated; 0 regressions from extraction). Back-compat shims at plugins/memory/isokron/__init__.py and kora_cli/reasoning/kora_hermes_plugin/__init__.py do sys.path bootstrap (mirrors the plugins/marvin/__init__.py POC pattern from #204) plus sys.modules aliasing of the moved sub-modules. Existing in-tree imports of the form `from plugins.memory.isokron.X import Y` and `from kora_cli.reasoning.kora_hermes_plugin.X import Y` continue working unchanged — no per-file shims, no caller sweep across the rest of the Kora tree. §4 STOP-ASK A.1 resolved by operator decision: (B) tight-scoped extraction. provider.py + active_provider.py + sea_ticket_poller* stay in plugins/memory/isokron/ as the Hermes-plugin half importing from isokron-client. kora_cli/clients/kora_control_writer.py + kora_cli/audit/jsonl_sink.py deferred to Phase 1b (operator task NousResearch#450). API surface uses real grep'd names (events / reads / control / scratchpad / policy / constitution / capability / sea_tickets), not the bucket's audit/conversation/workspace strawman that didn't map to what was in the tree. Companion kora-docs PR amends AUDIT.md from 4-package to 5-package split + closes §7.1 (Hermes source-only) + §7.2 (isokron-client separate package). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Phase 1 of the KR-KORA-PIP-RESTRUCTURE program. Two new pip-installable packages under
packages/, extracted from in-tree code with full backward-compat shims so existing imports work unchanged.packages/isokron-client/— 20 substrate-functional modules lifted fromplugins/memory/isokron/(non-provider files only). Pure library with zero Kora/Hermes coupling at import time. ANY Hermes-based agent canpip install isokron-clientto gain IsoKron substrate primitives. Public surface:events / reads / control / scratchpad / policy / constitution / capability / sea_tickets. 5/5 dry-run smoke tests pass in a clean venv. Seepackages/isokron-client/README.md§"BYOA usage example".packages/kora-runtime/— 28 modules (7 sub-plugins + orchestrator) lifted fromkora_cli/reasoning/kora_hermes_plugin/. Declaresisokron-clientas a PyPI dep. Hermes is source-only per the 2026-05-25 operator decision; README documents the install order. Entry pointhermes_agent.plugins.kora = kora_runtime:registervalidated viaimportlib.metadata.entry_points()after dry-run install. 5/5 dry-run smoke tests pass + 142/151 in-tree tests pass (8 pre-existing Marvin data-dir failures unrelated; 0 regressions).§4 STOP-ASK resolution
The bucket's K-DG block hypothesized the IsoKron client at
kora_cli/isokron/. PM-verify pass found it atplugins/memory/isokron/(29 files, IS a Hermes MemoryProvider plugin). API shape in reality:events / reads / control / scratchpad / ...— not the bucket's strawmanaudit / conversation / workspace. Surfaced to operator; operator confirmed (B) tight-scoped:isokron-clientprovider.py+active_provider.py+active_poller.py+sea_ticket_poller*+tools/→ STAY inplugins/memory/isokron/importing FROMisokron-clientkora_cli/clients/kora_control_writer.py+kora_cli/audit/jsonl_sink.py→ deferred to Phase 1b (operator task fix: correct KawaiiSpinner file location in AGENTS.md NousResearch/hermes-agent#450)Back-compat mechanics
Both shims (
plugins/memory/isokron/__init__.py+kora_cli/reasoning/kora_hermes_plugin/__init__.py) do sys.path bootstrap (mirrorsplugins/marvin/__init__.pyPOC from #204) plus sys.modules aliasing of the moved sub-modules. Existing in-tree imports continue working unchanged — no per-file shim files, no caller sweep across the rest of the Kora tree. Test logger names in 6 test files updated fromplugins.memory.isokron.X→isokron_client.Xfor moved modules; STAY-module loggers untouched.Build/install transcripts
AUDIT.md closure
Companion PR on
rafe-walker/kora-docsamendskora_docs/14_research/kora_pip_packaging_2026-05-24/AUDIT.mdfrom 4-package to 5-package split + closes §7.1 (Hermes source-only) + §7.2 (isokron-client separate package, BYOA). Seedocs/kora-KR-KORA-PIP-RESTRUCTURE-PHASE-1-RUNTIME-AND-ISOKRON-CLIENT-MEGABUCKETon kora-docs.Test plan
packages/isokron-client/tests/smoke tests (5/5) against fresh-venv wheel installpackages/kora-runtime/tests/smoke tests (5/5) against fresh-venv wheel install + entry-point discoverytests/plugins/memory/suite — 369/374 pass (5 failures all pre-existing on baseline; 0 regressions)tests/plugins/test_kora_hermes_plugin_*.py+tests/kora_cli/reasoning/kora_hermes_plugin/— 142/151 pass (8 pre-existing Marvin failures; 0 regressions)tests/kora_cli/router/test_cost_router.py+tests/kora_cli/short_circuit/test_dm_phrasebook.pycanonical-path assertions updated tokora_runtime.*(the canonical module path post-move)🤖 Generated with Claude Code