Skip to content

Bus storage is unstorage: delete bespoke storage code, consumers pick the driver - #18

Merged
Tyler-R-Kendrick merged 1 commit into
mainfrom
claude/interface-redundancies-consolidate-8juzw3
Jul 12, 2026
Merged

Bus storage is unstorage: delete bespoke storage code, consumers pick the driver#18
Tyler-R-Kendrick merged 1 commit into
mainfrom
claude/interface-redundancies-consolidate-8juzw3

Conversation

@Tyler-R-Kendrick

Copy link
Copy Markdown
Owner

Summary

Replaces the harness's homegrown storage layer with unstorage. The bus now owns zero storage logic: it takes any unstorage instance, and the consumer picks the driver — memory, fs, redis, http, cloud KV, or anything else in the driver ecosystem.

Changes

Harness package

  • AgentBusSettings.storage accepts any unstorage Storage; unset, the bus uses unstorage's default in-memory driver. Entries live under the storage's entry:* keys, sorted by sequence on load, still parsed at the boundary with the zod entry schema so malformed values never enter the log. A bus expects sole write access to its entry:* keys; shared storages should be mounted or prefixed.
  • Deleted outright: JsonlBusStore, BusFileSystem, the AgentBusStore seam, all JSONL serialization/recovery code, and the memfs dependency. unstorage is the storage abstraction — nothing bespoke remains.

Root package

  • HarnessLoopOptions.bus/actionLogFile become one storage factory: (input: TrainingLoopInput) => Storage. Unset, a run's entries land on the local filesystem via the fs driver under <outputDir>/harness-actions (defaultActionLogDir). judge and contextProvider stay injectable as before.

Docs

  • Harness and root READMEs document the unstorage seam and driver choice; examples build the bus with createStorage({ driver: fsDriver(...) }).

Testing

  • npm run check passes (typecheck for all packages, 81 tests across 15 files, package build), including a driver-swap test (memory driver with an out-of-band writer, sequence resumption) and an fs-driver persistence test across bus instances.

🤖 Generated with Claude Code

https://claude.ai/code/session_01NG6fSKqgt8nD7JnEY9q245


Generated by Claude Code

The bus no longer owns any storage logic. AgentBusSettings.storage
takes any unstorage instance, and the consumer picks the driver —
memory (the default), fs, redis, http, or anything else in the driver
ecosystem. Entries live under the storage's entry:* keys. JsonlBusStore,
BusFileSystem, the AgentBusStore seam, and the memfs dependency are all
deleted. createHarnessLoop's bus option becomes a storage factory,
defaulting to the fs driver under the run's output directory.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NG6fSKqgt8nD7JnEY9q245
@coderabbitai

coderabbitai Bot commented Jul 12, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@Tyler-R-Kendrick, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 21 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: fb0a63eb-a1ac-413c-aa9e-c3fd134eacd7

📥 Commits

Reviewing files that changed from the base of the PR and between 578c640 and abe53ea.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (10)
  • README.md
  • package.json
  • packages/harness/README.md
  • packages/harness/package.json
  • packages/harness/src/bus.ts
  • packages/harness/src/index.ts
  • packages/harness/src/jsonl-store.ts
  • packages/harness/test/harness.test.ts
  • src/index.ts
  • src/providers/harness.ts
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch claude/interface-redundancies-consolidate-8juzw3

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@Tyler-R-Kendrick
Tyler-R-Kendrick merged commit 2920e87 into main Jul 12, 2026
3 checks passed
@Tyler-R-Kendrick
Tyler-R-Kendrick deleted the claude/interface-redundancies-consolidate-8juzw3 branch July 12, 2026 20:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants