The agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.
docs: align videodb event directory handling
Affaan Mustafa192d2b63f2d0
diff --git a/skills/videodb/SKILL.md b/skills/videodb/SKILL.mdindex 02c417d9e..5742e59da 100644--- a/skills/videodb/SKILL.md+++ b/skills/videodb/SKILL.md@@ -303,10 +303,11 @@ Use `ws_listener.py` to capture WebSocket events during recording sessions. Desk#### Quick Start-1. **Start listener**: `python scripts/ws_listener.py --clear &`-2. **Get WebSocket ID**: `cat "${VIDEODB_EVENTS_DIR:-$HOME/.local/state/videodb}/videodb_ws_id"`-3. **Run capture code** (see reference/capture.md for the full workflow)-4. **Events written to**: `${VIDEODB_EVENTS_DIR:-$HOME/.local/state/videodb}/videodb_events.jsonl`+1. **Choose state dir**: `STATE_DIR="${VIDEODB_EVENTS_DIR:-$HOME/.local/state/videodb}"`+2. **Start listener**: `VIDEODB_EVENTS_DIR="$STATE_DIR" python scripts/ws_listener.py --clear "$STATE_DIR" &`+3. **Get WebSocket ID**: `cat "$STATE_DIR/videodb_ws_id"`+4. **Run capture code** (see reference/capture.md for the full workflow)+5. **Events written to**: `$STATE_DIR/videodb_events.jsonl`Use `--clear` whenever you start a fresh capture run so stale transcript and visual events do not leak into the new session.@@ -314,10 +315,12 @@ Use `--clear` whenever you start a fresh capture run so stale transcript and vis```pythonimport json+import osimport timefrom pathlib import Path-events_file = Path.home() / ".local" / "state" / "videodb" / "videodb_events.jsonl"+events_dir = Path(os.environ.get("VIDEODB_EVENTS_DIR", Path.home() / ".local" / "state" / "videodb"))+events_file = events_dir / "videodb_events.jsonl"events = []if events_file.exists():diff --git a/skills/videodb/scripts/ws_listener.py b/skills/videodb/scripts/ws_listener.pyindex 105aabc77..0ec201056 100644--- a/skills/videodb/scripts/ws_listener.py+++ b/skills/videodb/scripts/ws_listener.py@@ -89,6 +89,9 @@ def parse_args() -> tuple[bool, Path]:output_dir = argif output_dir is None:+ events_dir = os.environ.get("VIDEODB_EVENTS_DIR")+ if events_dir:+ return clear, ensure_private_dir(Path(events_dir))return clear, ensure_private_dir(default_output_dir())return clear, ensure_private_dir(Path(output_dir))