diff --git a/README.md b/README.md index 60d0091..23ed9b7 100644 --- a/README.md +++ b/README.md @@ -26,10 +26,38 @@ AGENT_PLATFORM=codex npx --no-install torch-lock lock --agent docs-agent --caden # List all active locks npx --no-install torch-lock list +# Mark a task as completed (permanent) +AGENT_PLATFORM=codex npx --no-install torch-lock complete --agent docs-agent --cadence daily + +# Initialize TORCH in a new repository +npx --no-install torch-lock init + +# Update TORCH configuration and scripts +npx --no-install torch-lock update + # Run the Dashboard npx --no-install torch-lock dashboard ``` +### Memory CLI + +The `torch-lock` CLI also supports memory operations: + +```bash +# List memories (optional filters: --agent, --type, --tags, --pinned) +npx --no-install torch-lock list-memories --limit 5 + +# Inspect a specific memory +npx --no-install torch-lock inspect-memory --id + +# Pin/Unpin a memory +npx --no-install torch-lock pin-memory --id +npx --no-install torch-lock unpin-memory --id + +# Check memory stats +npx --no-install torch-lock memory-stats +``` + ### Configuration (`torch-config.json`) Create a `torch-config.json` file in your project root to configure TORCH for your repository. You can use the included `torch-config.example.json` as a template. diff --git a/artifacts/docs-alignment-report.md b/artifacts/docs-alignment-report.md new file mode 100644 index 0000000..4627656 --- /dev/null +++ b/artifacts/docs-alignment-report.md @@ -0,0 +1,33 @@ +# Documentation Alignment Report +**Agent:** docs-alignment-agent +**Date:** 2026-02-14 + +## Audit Summary +A comprehensive audit of the repository documentation (`README.md`, `src/docs/TORCH.md`) was performed against the codebase (`bin/torch-lock.mjs`, `src/lib.mjs`, `src/ops.mjs`, `src/torch-config.mjs`). + +The audit revealed that while the core locking commands were documented, several administrative and new commands (init, update, complete, memory operations) were missing from the primary documentation. + +## Claims Map + +| Claim / Feature | Source Doc | Code Implementation | Status | Notes | +| :--- | :--- | :--- | :--- | :--- | +| `check` command | `README.md` | `bin/torch-lock.mjs` | ✅ Matches | Correctly documented. | +| `lock` command | `README.md` | `bin/torch-lock.mjs` | ✅ Matches | Correctly documented. | +| `list` command | `README.md` | `bin/torch-lock.mjs` | ✅ Matches | Correctly documented. | +| `dashboard` command | `README.md` | `bin/torch-lock.mjs` | ✅ Matches | Correctly documented. | +| `complete` command | `README.md` | `src/lib.mjs` (cmdComplete) | ⚠️ Missing | **Fixed:** Added usage example. | +| `init` command | `README.md` | `src/ops.mjs` (cmdInit) | ⚠️ Missing | **Fixed:** Added usage example. | +| `update` command | `README.md` | `src/ops.mjs` (cmdUpdate) | ⚠️ Missing | **Fixed:** Added usage example. | +| Memory CLI | `README.md` | `bin/torch-lock.mjs` | ⚠️ Missing | **Fixed:** Added `list-memories`, `inspect-memory`, etc. | +| Quick Start | `src/docs/TORCH.md` | `bin/torch-lock.mjs` | ⚠️ Outdated | **Fixed:** Updated `node src/nostr-lock.mjs` to `npx torch-lock`. | +| Configuration | `README.md` | `src/torch-config.mjs` | ✅ Matches | Config keys align with implementation. | + +## Validation Notes +- **Verification Method:** Static code analysis of `bin/torch-lock.mjs` arg parsing and `src/lib.mjs` / `src/ops.mjs` function signatures compared against documentation text. +- **Updates Applied:** + - `README.md`: Added `complete`, `init`, `update` commands and Memory CLI section. + - `src/docs/TORCH.md`: Updated outdated command examples to use the `npx torch-lock` convention. + +## Recommendations +- Future updates to the CLI should include a documentation update step in the PR checklist. +- Consider auto-generating the CLI usage section from the `bin/torch-lock.mjs` help text (output of `usage()`) to ensure perfect synchronization. diff --git a/src/docs/TORCH.md b/src/docs/TORCH.md index c7af3b7..0fde538 100644 --- a/src/docs/TORCH.md +++ b/src/docs/TORCH.md @@ -6,13 +6,13 @@ TORCH is a decentralized task-locking protocol for multi-agent software developm ```bash # Check active locks -node src/nostr-lock.mjs check --cadence daily +npx torch-lock check --cadence daily # Claim a task -AGENT_PLATFORM=codex node src/nostr-lock.mjs lock --agent docs-agent --cadence daily +AGENT_PLATFORM=codex npx torch-lock lock --agent docs-agent --cadence daily # List all active locks -node src/nostr-lock.mjs list +npx torch-lock list ``` ## Defaults diff --git a/task-logs/daily/2026-02-14T21-04-45Z__docs-alignment-agent__completed.md b/task-logs/daily/2026-02-14T21-04-45Z__docs-alignment-agent__completed.md new file mode 100644 index 0000000..75c52c8 --- /dev/null +++ b/task-logs/daily/2026-02-14T21-04-45Z__docs-alignment-agent__completed.md @@ -0,0 +1,25 @@ +--- +agent: docs-alignment-agent +status: completed +date: 2026-02-14 +--- + +# Docs Alignment Report + +## Summary +Audited `README.md` and `src/docs/TORCH.md` against the codebase. +Identified missing documentation for: +- `complete` command +- `init` command +- `update` command +- Memory CLI commands + +## Actions +- Updated `README.md` to include usage examples for the missing commands. +- Updated `src/docs/TORCH.md` to replace outdated `node src/nostr-lock.mjs` examples with `npx torch-lock`. +- Created `artifacts/docs-alignment-report.md` with a detailed claims map. + +## Validation +- Verified updates by reading the files. +- Verified linting passed. +- Published completion event.