Aller au contenu
login
arrow_backRetour aux issues
krapcys1-maker/adaptive-agent-memory-research #19

Add a verify subcommand to the project-memory CLI

ecoDébutant good first issue track:engine effort:S no-expertise-needed

descriptionDescription

## The problem `scripts/verify_memory_integrity.py` checks the canonical memory log against every invariant that is decidable from its bytes. It runs in CI. But a contributor working locally has to know the script exists and remember its path. Meanwhile `tools/project_memory/cli.py` is the documented entry point for everything else: `status`, `search`, `context`, `timeline`, `get`, `add`, `supersede`, `rebuild`. Integrity verification belongs alongside them. ## The task Add a `verify` subcommand so this works: ```bash python tools/project_memory/cli.py verify python tools/project_memory/cli.py verify --format json ``` It should reuse `scripts/verify_memory_integrity.py` rather than reimplementing the checks, and it should exit non-zero when a violation is found so it stays usable in a shell pipeline or a git hook. Note that `scripts/` is not currently an importable package from `tools/`. Deciding how to bridge that cleanly is part of the task; adding `sys.path` manipulation is acceptable if the existing code already does it, but a tidier arrangement is welcome. ## Acceptance criteria - [ ] `python tools/project_memory/cli.py verify` reports the same result as running the script directly. - [ ] Exit code is 0 when clean and 1 when a violation exists. - [ ] `--format json` and `--format text` both work. - [ ] The check logic is not duplicated. - [ ] A test covers the success and failure exit codes. - [ ] `memory/README.md` mentions the new subcommand. ## Getting started Small, self-contained, and a good way to learn how the memory tool fits together. No research background needed.
codeOuvre sur GitHub