diff --git a/agent-evolution/README.md b/agent-evolution/README.md index f52b164..71280c3 100644 --- a/agent-evolution/README.md +++ b/agent-evolution/README.md @@ -30,6 +30,19 @@ The `build-standalone-fixed.cjs` script: 4. Embeds unified JSON data directly into the HTML file 5. Updates JavaScript functions to use embedded data +## Incremental DB Sync + +The `watch-db.cjs` script provides incremental database synchronization: + +1. Watches for changes in `.kilo/agents/*.md` and `kilo-meta.json` +2. Only processes changed files (incremental update) +3. Determines change type (model_change vs prompt_change) +4. Updates database with new versions and metadata +5. Exports updated data to JSON +6. Clean shutdown on SIGINT/SIGTERM +7. Configurable polling interval via `WATCH_INTERVAL_MS` env var +8. Logging to `.kilo/logs/watch-db.log` + ## Validation The build process ensures: @@ -47,6 +60,18 @@ The build process ensures: Simply open `index.standalone.html` in any modern browser. No server or external dependencies required. +To run the incremental DB watcher: +```bash +# Run with default 60 second interval +node agent-evolution/scripts/watch-db.cjs + +# Run with custom interval (10 seconds) +WATCH_INTERVAL_MS=10000 node agent-evolution/scripts/watch-db.cjs + +# Run in background +nohup node agent-evolution/scripts/watch-db.cjs > watch-db.log 2>&1 & +``` + ## Agent Count The dashboard currently tracks **34 agents** across multiple categories: diff --git a/agent-evolution/index.html b/agent-evolution/index.html index 0abe0fb..f60127c 100644 --- a/agent-evolution/index.html +++ b/agent-evolution/index.html @@ -794,13 +794,13 @@
- - - - - - - + + + + + + +
@@ -990,6 +990,21 @@ + + +