Repository navigation
feat(core): add a synthetic archive generator for demos and checks - #17
Merged
Merged
Conversation
Add a synth example and scripts/synth-archive.sh so every later check can run on a reproducible fake Claude and Codex profile instead of real agent history.
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.
Why
Later P1 checks need a reproducible fake archive. No check should read real agent history.
What changed
crates/lore-core/examples/synth.rs. It takes<out_dir> <claude_count> <codex_count> <seed>and callslore_core::synthetic::generate.scripts/synth-archive.sh. It runs the example in release mode and passes the exit code through.<out_dir>resolves where the caller is.Scope
Cargo.tomlchange was needed, because Cargo findsexamples/on its own.lore_core::syntheticis unchanged.Blast Radius
cargo buildor shipped in the app.cargo clippy --all-targetsandcargo testnow also compile the example.Verification
scripts/synth-archive.sh /tmp/p1-0-a 30 20 7printed/tmp/p1-0-aandclaude 30 codex 20, exit 0./tmp/p1-0-banddiff -r /tmp/p1-0-a /tmp/p1-0-bprinted nothing.findcounted 30 files underclaude/projectsand 20 undercodex/sessions.lorectl scan --archive /tmp/p1-0-archwithCLAUDE_CONFIG_DIRandCODEX_HOMEset to the generated homes andLORE_ARCHIVE_DIRunset reportedingested 50 skipped 0 failed 0.lorectl search health --archive /tmp/p1-0-archreturned hits (41 output lines).0 5and5 0wrote only Codex files and only Claude files, exit 0.other/note.txtand two unrelated.jsonlfiles, the generator left their SHA-1 sums unchanged and added 50 session files.time scripts/synth-archive.sh /tmp/p1-0-big 3000 1000 7, three runs: 4.55 s, 8.43 s, 3.51 s. The median is 4.55 s against a 60 s budget. The output is 3000 and 1000 files, 16 MB.cargo fmt --all -- --checkpassed.cargo clippy -p lore-core -p lore-ipc -p lorectl --all-targets --all-features -- -D warningspassed.cargo test -p lore-core syntheticpassed 7 tests in the library target.Not verified here:
lorectl mcpis not onmainyet (PR 15), so thesearch_sessionscheck is not run.main's CI "Rust core" job is red from an unrelated egress-sandbox issue that PR 16 fixes. This PR does not touch it./deslopand/no-commentsare not installed here, so both were skipped.