Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,16 @@ versioning follows [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

_Nothing yet._

---

## [0.2.0] — 2026-10-05

The first runtime release since 0.1.0: korg becomes a verifiable ledger for AI-agent work. Captured sessions can be minted into signed `korgcert@v1` Certificates that anyone re-verifies offline in Rust, Python, JS or the browser, and the swarm now runs an honest pipeline whose ledger attests only work the worktree actually shows.

**Breaking:** the certificate format formerly called `goldseal@v1` is now `korgcert@v1` (schema string, verifier, fixtures and adapters). Seals minted under the old name must be re-minted.

### Security & correctness (multi-agent adversarial bug hunt — 15 real bugs fixed)

A fan-out review across every component, with each finding refuted-by-default by an independent verifier, surfaced **15 confirmed real bugs** (9 false positives filtered out). All fixed, with regression tests + the differential fuzzer extended to lock them:
Expand Down Expand Up @@ -49,6 +59,10 @@ Gate after second pass: 13 Rust test binaries, **232 Python tests**, JS conforma
Gate after third pass: 14 Rust test binaries, **235 Python tests** (incl. NaN/Inf, Stop-flush, concurrency, receipt-domain regressions), JS conformance, differential fuzz 0 divergences. Three adversarial passes, **32 real bugs fixed** — the iterative fix-audit caught regressions in both prior passes' fixes.

### Added
- **Zero-config verifiable Claude Code capture (#8).** `korg-setup` registers a Claude Code hook that writes one verifiable korg-ledger@v1 ledger per session under `~/.korg/sessions/`; `korg-backfill` captures past transcripts retroactively and migrates the legacy flat ledger. Cross-language conformance and adapter suites are gated in CI.
- **Trust hardening (#9).** Optional Ed25519 per-event signatures and structural git-tip anchors across Rust, Python and JS (`korg-verify --pin-event-pubkey` / `--anchors`), a zero-install in-browser ledger verifier, tamper-evident rewinds routed through `rewind_with_seal`, and proptests over canonicalization and rewind chain invariants.
- **The Honest Pipeline for the swarm (#11–#14).** Workers apply real patches in git worktrees and the ledger attests the real diff (files changed, paths) instead of synthetic telemetry; synthetic injectors are gated behind `--inject-stress` (default off). Personas pass real data downstream, run under per-persona permissions (read-only personas never mutate), and reuse a pre-warmed shared cargo cache behind `--speculative`.
- **`korg run-once` (#12, #15).** Drives the honest pipeline visibly on a fixture, and with `--provider ollama --model … --base-url …` on a real local model for arbitrary tasks. Invalid model output is attested as an honest null, never a fabricated count.
- **Adversarial hardening of the verifiers — fuzzed + differentially tested across all three impls.** Property-based fuzzing of the korgcert verifiers proves two security invariants: they never crash on hostile input, and never accept junk or any single-character hash/seal-signature flip. The fuzzers **found and fixed two real robustness bugs** — the Python and JS verifiers crashed (`AttributeError` / `TypeError`) on a `null`/non-object event; both now degrade gracefully to "invalid" like Rust always did (guards added across `verify_chain`/`verify_dag`/`verify_anchors`/`derive_summary`/`verify_structure`/`verify_seal` and the JS equivalents). Coverage: Python `test_korgcert_properties.py` (Hypothesis, ~1700 examples), Rust `crates/korg-verify/tests/fuzz.rs` (proptest, 5 properties), JS fuzz block in `conformance.mjs`. **Differential fuzzer** `spec/korg-ledger-v1/tools/diff_fuzz.py` runs 24 adversarial mutations of a Certificate through the Rust, Python, and JS verifiers and asserts all three return the **same** verdict (a divergence = a conformance bug) — **0 divergences**; gated in CI (Build & Test job). 211 Python tests.
- **Time-travel session explorer** ([`spec/korg-ledger-v1/web/explore.html`](spec/korg-ledger-v1/web/explore.html)) — a zero-install, client-side replay of any korg-ledger@v1 session or Certificate. Drop a ledger/seal and scrub the timeline: the **cumulative state** (agents, tools, files touched) is re-derived live over the slice up to the playhead, so you watch what the agent did evolve step by step, while the hash-chain verifies under every frame. A tampered chain lights up red and auto-jumps the playhead to the exact break; a Certificate additionally shows its claim + signer. Play/pause, scrub, click an event for full args/result. Same Web Crypto engine as the verifiers; linked from the landing page (a third card). Verified in a real browser across session / tampered / Certificate inputs.
- **Trusted *time* — `korg-seal anchor` + `korg-seal resolve` close the provenance triad (what + who + WHEN).** A Certificate proves *what* (re-derived summary) and *who* (Ed25519 seal) offline; it could not prove *when*. The new commands do: `korg-seal anchor <seal> --repo <url> --commit <sha>` binds a `git-tip` time anchor and re-signs (post-hoc flow: mint → publish/commit → anchor); `korg-seal resolve <seal>` performs the one network step — fetches each anchor's public commit (stdlib `urllib`, GitHub API) and confirms it *introduced* the anchored `entry_hash`, yielding a "the chain existed no later than `<commit date>`" bound. A public commit is immutable once mirrored, so an owner who rewrote the chain would have to force-push the witness (detectable). **Demoed live against the real repo:** the committed fixture's tip `bd8389e3…` is genuinely witnessed by public commit `0e566b0` (committed `2026-06-14T06:01:28Z`); `korg-seal resolve` confirms it over the live GitHub API, and the anchored seal still verifies offline. The resolver is injectable-fetcher-based so it's unit-tested hermetically (witnessed / not-witnessed / commit-404 / repo-URL parsing) + the anchor re-bind roundtrip. KORGCERT.md §6/§8 + positioning updated (time is now an explicit opt-in network step, not a gap). +5 korg-seal tests (14 total).
Expand All @@ -66,6 +80,12 @@ Gate after third pass: 14 Rust test binaries, **235 Python tests** (incl. NaN/In
- **Transport-agnostic proof trio complete.** Three adapter PoCs across three architectural extremes (stdio JSONL, WebSocket, NDJSON streaming) all round-trip cleanly through the ledger with spec §2a causal coherence — moving the "universal capability ledger" claim from aspirational to demonstrated.

### Changed
- **`goldseal@v1` renamed to `korgcert@v1` (#18, #19)**, with fixtures re-minted and re-signed so Rust, Python and JS conformance stays green. Display name "Gold Seal" is now "Certificate".
- **Launch-ready README (#21, #22):** one-line pitch, a 30-second quickstart that runs verbatim from a fresh clone, the N=3 cross-vendor validation table, and a tamper GIF. Adds `LICENSE-APACHE` and fixes the dead license links.

### Fixed
- **Multi-persona campaigns (#16):** worker log lines on stdout corrupted the ACP channel, so every successful worker was recorded as crashed. Tracing now goes to stderr and the campaign reports real results.
- CI: hanging worker-subprocess tests are gated and every job has a timeout guard (#15).
- README cleaned up: placeholder crates.io / docs.rs badges dropped (not yet published), install path corrected, test count updated to 175 (162 cargo + 13 pytest).
- `cargo fmt` cleanup across korg-bridge.
- `.gitignore` extended for transient `*_report.html` artifacts.
Expand Down Expand Up @@ -158,6 +178,8 @@ Gate after third pass: 14 Rust test binaries, **235 Python tests** (incl. NaN/In

See [ROADMAP.md](ROADMAP.md) for planned features.

[Unreleased]: https://github.com/New1Direction/korg/compare/v0.2.0...HEAD
[0.2.0]: https://github.com/New1Direction/korg/releases/tag/v0.2.0
[0.1.0]: https://github.com/New1Direction/korg/releases/tag/v0.1.0
[bridge-v0.3.0]: https://github.com/New1Direction/korg/releases/tag/bridge-v0.3.0
[bridge-v0.3.1]: https://github.com/New1Direction/korg/releases/tag/bridge-v0.3.1
Expand Down
22 changes: 11 additions & 11 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ axum = { version = "0.7", features = ["macros"] }

[package]
name = "korg"
version = "0.1.0"
version = "0.2.0"
edition = "2021"
description = "A tamper-evident, verifiable ledger for AI agent cognition: every decision is recorded in a hash-chained, causally-ordered journal that anyone can independently verify — no blockchain, no trust in the tool that produced it."
license = "MIT OR Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion crates/korg-auth/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "korg-auth"
version = "0.1.0"
version = "0.2.0"
edition = "2021"
description = "Authentication, authorization, and subscription tier logic for korg"
license = "MIT OR Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion crates/korg-core/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "korg-core"
version = "0.1.0"
version = "0.2.0"
edition = "2021"
description = "Foundational types and traits for the korg cognitive runtime"
license = "MIT OR Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion crates/korg-embeddings/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "korg-embeddings"
version = "0.1.0"
version = "0.2.0"
edition = "2021"
description = "Semantic embedding backend for korg (candle ML stack)"
license = "MIT OR Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion crates/korg-ledger/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "korg-ledger"
version = "0.1.0"
version = "0.2.0"
edition = "2021"
description = "korg-ledger@v1 — the tamper-evident hash-chain spec implementation (canonicalize, chain_hash, verify_chain, verify_dag). Byte-identical to the Python and JS references; SHA-256 or HMAC-keyed."
license = "MIT OR Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion crates/korg-llm/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "korg-llm"
version = "0.1.0"
version = "0.2.0"
edition = "2021"
description = "LLM routing and prompt machinery for korg (Claude, OpenAI, Grok)"
license = "MIT OR Apache-2.0"
Expand Down
4 changes: 2 additions & 2 deletions crates/korg-registry/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
[package]
name = "korg-registry"
version = "0.1.0"
version = "0.2.0"
edition = "2021"
description = "Capability journal, ledger, and plan execution for korg"
license = "MIT OR Apache-2.0"

[dependencies]
korg-core = { path = "../korg-core" }
korg-ledger = { path = "../korg-ledger", version = "0.1.0" }
korg-ledger = { path = "../korg-ledger", version = "0.2.0" }
serde = { workspace = true }
serde_json = { workspace = true }
uuid = { workspace = true }
Expand Down
2 changes: 1 addition & 1 deletion crates/korg-runtime/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "korg-runtime"
version = "0.1.0"
version = "0.2.0"
edition = "2021"
description = "Orchestration engine: leader, workers, DAG, personas, blackboard, ACP"
license = "MIT OR Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion crates/korg-server/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "korg-server"
version = "0.1.0"
version = "0.2.0"
edition = "2021"
description = "Axum HTTP server and SSE cockpit for korg"
license = "MIT OR Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion crates/korg-tui/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "korg-tui"
version = "0.1.0"
version = "0.2.0"
edition = "2021"
description = "Ratatui operator dashboard for korg"
license = "MIT OR Apache-2.0"
Expand Down
4 changes: 2 additions & 2 deletions crates/korg-verify/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "korg-verify"
version = "0.1.0"
version = "0.2.0"
edition = "2021"
description = "Independent, dependency-light verifier for korg receipts and journals (hash chain + causal DAG + Ed25519 tip signature). No network, no Python."
license = "MIT OR Apache-2.0"
Expand All @@ -15,7 +15,7 @@ name = "korg-verify"
path = "src/main.rs"

[dependencies]
korg-ledger = { path = "../korg-ledger", version = "0.1.0", features = ["signing"] }
korg-ledger = { path = "../korg-ledger", version = "0.2.0", features = ["signing"] }
serde_json = { workspace = true }
ed25519-dalek = "2"
hex = "0.4"
Expand Down
Loading