feat: Autonomous agent commands — watch, scan-bounties, batch sell#1
Merged
feat: Autonomous agent commands — watch, scan-bounties, batch sell#1
Conversation
Phase 0 — MCP compatibility fixes: - Align Base mainnet contract to 0x69Aa385686AEdA505013a775ddE7A59d045cb30d - Fix ECDH commit-reveal: commit against encrypted key when buyer pubkey known - Add marketplace publishing to sell command - Bridge MCP JSON key storage (~/.datafund/escrow-keys/) bidirectionally - Extend CLIError with retryAfterSeconds, suggestedCommand, 10 new error codes - Add HTTPS enforcement for API and RPC URLs Phase 1 — New commands: - `ade watch` — escrow automation daemon with NDJSON event protocol, three-tier spending limits, HMAC-SHA256 state integrity, PID-based locking - `ade scan-bounties` — match local files to open bounties via keyword overlap, security filters for sensitive files, optional auto-respond mode - `ade sell --dir` — batch sell files from directory with rate limiting, --skip-existing, --max-files, partial error reporting Schema v1.1.0 with auth levels, credentials, protocols, error formats. Version bumped to 0.2.0. 213 tests pass. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
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
ade watch— Escrow automation daemon. Polls for funded/released escrows, auto-commits/reveals keys (seller), downloads/decrypts data (buyer), claims payments. NDJSON event protocol on stdout, three-tier spending limits, HMAC-SHA256 state integrity, PID-based locking.ade scan-bounties— Matches local files against open marketplace bounties via keyword overlap scoring. Security filters exclude sensitive files (.env, .pem, keys). Optional--respondmode auto-creates escrows for best matches.ade sell --dir— Batch sell files from a directory. Sequential execution with rate limiting,--skip-existingmarketplace check,--max-filescap, partial error reporting (exit code 6).MCP Compatibility Fixes (Phase 0)
0x69Aa385686AEdA505013a775ddE7A59d045cb30dsellcommand~/.datafund/escrow-keys/JSON files)retryAfterSeconds,suggestedCommand, 10 new error codesOther
Verification
Verified (213 unit tests pass, build compiles, CLI smoke tested):
ade help,ade version,ade schema,ade help watch,ade help scan-bountiesall produce correct output--max-valuerequired,minScoreforced to 0.5)--yesrequires--max-value, price vs max-value)--max-filestruncation)Not verified (requires real credentials/chain — needs integration testing):
0x69Aa38...is correct and live on Base mainnetTest plan
bun run test:unit— 213 pass, 0 failbun build src/index.ts --compile— compiles cleanade version→ 0.2.0ade help→ shows watch, scan-bounties, batch sell sectionsade schema→ v1.1.0 with new commands and protocolsade sell --file test.csv --price 0.001 --yeson Base Sepoliaade watch --once --dry-runade scan-bounties --dir ./test-data/🤖 Generated with Claude Code