Add Muse Code hook tracing - #70
Draft
Stephen Belanger (Qard) wants to merge 5 commits into
Draft
Conversation
Stephen Belanger (Qard)
force-pushed
the
t3code/plan-sdk-312-implementation
branch
2 times, most recently
from
September 11, 2026 13:21
a86284a to
345b900
Compare
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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
musedaemon translator for Muse Code 1.1 hook payloads.btCLI's enable, disable, doctor, and import surfaces.bt trace import muse --allby enumerating durable session IDs through Muse's read-only MSPsession/listAPI before exporting each session.Behavior and fidelity
bt trace import muse SESSION_IDinvokesmuse export --session, imports the staged export through the normal delivery pipeline, and removes the temporary export after import. The export reader uses stable session/run/request identifiers and native timestamps, restores complete committed assistant output, and preserves token metrics.Persistent live hooks remain a low-latency transport. Export-v1 is the authoritative historical fallback when hook output is incomplete.
--alldoes not resume sessions, obtain writer leases, or subscribe to views.The following are deliberately not exposed yet:
--attach, because it needs a durable MSP subscription and cursor-following implementation.bt trace run muse, because Muse currently has no safe ephemeral configuration overlay; cloning user configuration would be unsafe and could conflict with existing managed hooks.The embedding
btrepository must update its embedded daemon revision before the public CLI exposes the new Muse commands.Validation
cargo fmt --manifest-path bt-daemon/Cargo.toml -- --checkcargo clippy --manifest-path bt-daemon/Cargo.toml --all-features --locked -- -D warningscargo test --manifest-path bt-daemon/Cargo.toml --all-features --lockedimport muse --allrun enumerated and imported all three durable local Muse sessions through MSP.The suite passed: 123 unit tests and enabled integration suites. Existing real-agent tests for Codex, Claude, OpenCode, and Pi remain ignored by their own prerequisite checks.