← back to Videos Agentabrams Worker
ignore runtime files (cursor, logs)
170bcf7d2eb322e5723c7b953cf6a9c794539a9d · 2026-05-06 11:01:57 -0700 · steve
Files touched
M .gitignoreM cursor.txtM flow-map.jsonM log.jsonlM poll.py
Diff
commit 170bcf7d2eb322e5723c7b953cf6a9c794539a9d
Author: steve <steve@designerwallcoverings.com>
Date: Wed May 6 11:01:57 2026 -0700
ignore runtime files (cursor, logs)
---
.gitignore | 4 ++++
cursor.txt | 2 +-
flow-map.json | 4 ++--
log.jsonl | 25 +++++++++++++++++++++++++
poll.py | 40 ++++++++++++----------------------------
5 files changed, 44 insertions(+), 31 deletions(-)
diff --git a/.gitignore b/.gitignore
index 7e6a9c3..5331c23 100644
--- a/.gitignore
+++ b/.gitignore
@@ -10,3 +10,7 @@ dist/
build/
.next/
*.bak
+cursor.txt
+log.jsonl
+poll.stdout.log
+poll.stderr.log
diff --git a/cursor.txt b/cursor.txt
index 46c50e8..06cfe41 100644
--- a/cursor.txt
+++ b/cursor.txt
@@ -1 +1 @@
-2026-05-06T17:10:00.000Z
+2026-05-06T17:35:21.999Z
\ No newline at end of file
diff --git a/flow-map.json b/flow-map.json
index 01d2171..c5cef7b 100644
--- a/flow-map.json
+++ b/flow-map.json
@@ -9,13 +9,13 @@
"flow_file": "Animals-Pitch.json",
"url": "/Users/stevestudio2/Projects/animals/exports/animals-sales-pitch-latest.html",
"app_name": "Animals-Pitch",
- "selectors_hint": "th (sort columns); .btn-pitch (pitch button); #themeBtn (theme toggle); tr.tier-1, tr.tier1, tr.tier-A (Tier-A row variants); table tbody tr:first-child (top row); .filter-tier (tier filter)"
+ "selectors_hint": "th (clickable column headers — name/city/category/tier/paid_pixels); button.btn-pitch (per-row pitch button); #themeBtn (theme toggle); .theme-tog (alt theme btn); tr.tier-1 (Tier-A / TIER1_HEAVY row); tr.tier-2 (Tier-B); tr.tier-3 (Tier-C); #filter (search input); #tbody tr (any row); input[data-tier=TIER1_HEAVY] (Tier-A filter checkbox)"
},
"Doctor-Pitch": {
"flow_file": "Doctor-Pitch.json",
"url": "/Users/stevestudio2/Projects/professional-directory/exports/doctor-sales-pitch-latest.html",
"app_name": "Doctor-Pitch",
- "selectors_hint": "th; .btn-pitch; #themeBtn; tr.tier-1; table tbody tr:first-child"
+ "selectors_hint": "th (sort columns); button.btn-pitch (pitch); #themeBtn; tr.tier-1 (Tier-A row); tr.tier-2; tr.tier-3; #filter (search); #tbody tr (any row)"
},
"Ventura-Corridor": {
"flow_file": "Ventura-Corridor.json",
diff --git a/log.jsonl b/log.jsonl
index d85cc7a..38bafbd 100644
--- a/log.jsonl
+++ b/log.jsonl
@@ -8,3 +8,28 @@
{"event": "no_change", "video_id": "Animals-Pitch-2026-05-06.mp4", "ts": "2026-05-06T17:20:24.846187+00:00"}
{"event": "tick", "new_count": 1, "cursor": "2026-05-06T17:10:00.000Z", "ts": "2026-05-06T17:21:27.115638+00:00"}
{"event": "process_start", "request_ts": "2026-05-06T17:10:43.483Z", "video_ids": ["Animals-Pitch-2026-05-06.mp4"], "message": "add a hover step on Tier-A row before clicking the pitch button \u2014 make narration punchier", "ts": "2026-05-06T17:21:27.116457+00:00"}
+{"event": "ollama_error", "error": "timed out", "ts": "2026-05-06T17:27:27.126483+00:00"}
+{"event": "no_change", "video_id": "Animals-Pitch-2026-05-06.mp4", "ts": "2026-05-06T17:27:27.127507+00:00"}
+{"event": "tick", "new_count": 1, "cursor": "2026-05-06T17:10:00.000Z", "ts": "2026-05-06T17:28:03.767554+00:00"}
+{"event": "process_start", "request_ts": "2026-05-06T17:10:43.483Z", "video_ids": ["Animals-Pitch-2026-05-06.mp4"], "message": "add a hover step on Tier-A row before clicking the pitch button \u2014 make narration punchier", "ts": "2026-05-06T17:28:03.767800+00:00"}
+{"event": "llm_invalid_schema", "reason": "no steps[]", "flow": {}, "ts": "2026-05-06T17:28:27.686939+00:00"}
+{"event": "no_change", "video_id": "Animals-Pitch-2026-05-06.mp4", "ts": "2026-05-06T17:28:27.709079+00:00"}
+{"event": "tick", "new_count": 1, "cursor": "2026-05-06T17:10:00.000Z", "ts": "2026-05-06T17:32:00.974794+00:00"}
+{"event": "process_start", "request_ts": "2026-05-06T17:10:43.483Z", "video_ids": ["Animals-Pitch-2026-05-06.mp4"], "message": "add a hover step on Tier-A row before clicking the pitch button \u2014 make narration punchier", "ts": "2026-05-06T17:32:00.975364+00:00"}
+{"event": "llm_invalid_schema", "reason": "no steps[]", "flow": {}, "ts": "2026-05-06T17:32:04.554885+00:00"}
+{"event": "no_change", "video_id": "Animals-Pitch-2026-05-06.mp4", "ts": "2026-05-06T17:32:04.560432+00:00"}
+{"event": "tick", "new_count": 1, "cursor": "2026-05-06T17:10:00.000Z", "ts": "2026-05-06T17:32:28.588516+00:00"}
+{"event": "process_start", "request_ts": "2026-05-06T17:10:43.483Z", "video_ids": ["Animals-Pitch-2026-05-06.mp4"], "message": "add a hover step on Tier-A row before clicking the pitch button \u2014 make narration punchier", "ts": "2026-05-06T17:32:28.589980+00:00"}
+{"event": "llm_response_raw", "head": "{}", "ts": "2026-05-06T17:32:34.162378+00:00"}
+{"event": "llm_invalid_schema", "reason": "no steps[]", "flow": {}, "ts": "2026-05-06T17:32:34.166225+00:00"}
+{"event": "no_change", "video_id": "Animals-Pitch-2026-05-06.mp4", "ts": "2026-05-06T17:32:34.166925+00:00"}
+{"event": "tick", "new_count": 1, "cursor": "2026-05-06T17:10:00.000Z", "ts": "2026-05-06T17:32:55.453917+00:00"}
+{"event": "process_start", "request_ts": "2026-05-06T17:10:43.483Z", "video_ids": ["Animals-Pitch-2026-05-06.mp4"], "message": "add a hover step on Tier-A row before clicking the pitch button \u2014 make narration punchier", "ts": "2026-05-06T17:32:55.454393+00:00"}
+{"event": "llm_response_raw", "head": "```json\n{\"_comment\": \"Generic flow for pitch-table HTML pages. Uses only skill-supported actions: scroll/click/wait/hover.\", \"steps\": [{\"action\": \"wait\", \"ms\": 1800, \"narration\": \"Loading the directory\"}, {\"action\": \"scroll\", \"y\": 0, \"duration\": 600, \"narration\": \"The full cohort, sortable + filterable\"}, {\"action\": \"hover\", \"selector\": \"th\", \"narration\": \"Click any column to sort\"}, {\"action\": \"w", "ts": "2026-05-06T17:33:11.192010+00:00"}
+{"event": "flow_updated", "video_id": "Animals-Pitch-2026-05-06.mp4", "flow_file": "/Users/stevestudio2/.claude/skills/app-demo-video/flows/Animals-Pitch.json", "backup": "/Users/stevestudio2/.claude/skills/app-demo-video/flows/Animals-Pitch.1778088791.bak.json", "old_steps": 12, "new_steps": 14, "ts": "2026-05-06T17:33:11.199036+00:00"}
+{"event": "ship_video_done", "video_id": "Animals-Pitch-2026-05-06.mp4", "app_name": "Animals-Pitch", "returncode": 0, "stdout_tail": "[ship-video] using flow flows/Animals-Pitch.json\n[ship-video] LOCAL \u2192 /Users/stevestudio2/Videos/shipped-apps/Animals-Pitch-2026-05-06.mp4\n[ship-video] PUBLISH \u2192 https://videos.agentabrams.com/Animals-Pitch-2026-05-06.mp4\n", "stderr_tail": "", "ts": "2026-05-06T17:33:33.383939+00:00"}
+{"event": "tick", "new_count": 1, "cursor": "2026-05-06T17:33:34.000Z", "ts": "2026-05-06T17:35:22.194426+00:00"}
+{"event": "process_start", "request_ts": "2026-05-06T17:35:21.999Z", "video_ids": ["Animals-Pitch-2026-05-06.mp4"], "message": "Add a hover step on the first Tier-A row (selector tr.tier-1) right before the click on .btn-pitch \u2014 narration should call out heaviest paid-ad spend", "ts": "2026-05-06T17:35:22.194845+00:00"}
+{"event": "llm_response_raw", "head": "```json\n{\n \"_comment\": \"Generic flow for pitch-table HTML pages. Uses only skill-supported actions: scroll/click/wait/hover.\",\n \"steps\": [\n {\n \"action\": \"wait\",\n \"ms\": 1800,\n \"narration\": \"Loading the directory\"\n },\n {\n \"action\": \"scroll\",\n \"y\": 0,\n \"duration\": 600,\n \"narration\": \"The full cohort, sortable + filterable\"\n },\n {\n \"action\": \"ho", "ts": "2026-05-06T17:35:29.604304+00:00"}
+{"event": "flow_updated", "video_id": "Animals-Pitch-2026-05-06.mp4", "flow_file": "/Users/stevestudio2/.claude/skills/app-demo-video/flows/Animals-Pitch.json", "backup": "/Users/stevestudio2/.claude/skills/app-demo-video/flows/Animals-Pitch.1778088929.bak.json", "old_steps": 12, "new_steps": 13, "ts": "2026-05-06T17:35:29.605259+00:00"}
+{"event": "ship_video_done", "video_id": "Animals-Pitch-2026-05-06.mp4", "app_name": "Animals-Pitch", "returncode": 0, "stdout_tail": "[ship-video] serving /Users/stevestudio2/Projects/animals/exports/animals-sales-pitch-latest.html at http://127.0.0.1:55890/index.html\n[ship-video] using flow flows/Animals-Pitch.json\n[ship-video] LOCAL \u2192 /Users/stevestudio2/Videos/shipped-apps/Animals-Pitch-2026-05-06.mp4\n[ship-video] PUBLISH \u2192 https://videos.agentabrams.com/Animals-Pitch-2026-05-06.mp4\n", "stderr_tail": "/Users/stevestudio2/bin/ship-video: line 88: 71671 Terminated: 15 /usr/bin/python3 -m http.server $PORT --bind 127.0.0.1 > /dev/null 2>&1 (wd: /var/folders/2n/jmw9_4v56_x4m3539tr4v0lr0000gn/T/tmp.XQHEVzhzp3)\n", "ts": "2026-05-06T17:35:57.479605+00:00"}
diff --git a/poll.py b/poll.py
index 2d1a0a6..701ce28 100755
--- a/poll.py
+++ b/poll.py
@@ -19,8 +19,8 @@ LOG = ROOT / 'log.jsonl'
MAP_FILE = ROOT / 'flow-map.json'
FLOWS_DIR = Path.home() / '.claude' / 'skills' / 'app-demo-video' / 'flows'
SHIP_VIDEO = Path.home() / 'bin' / 'ship-video'
-OLLAMA_URL = os.environ.get('OLLAMA_URL', 'http://192.168.1.133:11434')
-OLLAMA_MODEL = os.environ.get('OLLAMA_MODEL', 'qwen3:14b')
+OLLAMA_URL = os.environ.get('OLLAMA_URL', 'http://localhost:11434')
+OLLAMA_MODEL = os.environ.get('OLLAMA_MODEL', 'gemma3:4b') # fast + no-thinking for flow JSON edits
API_BASE = 'https://videos.agentabrams.com'
API_AUTH = ('admin', 'DWSecure2024!')
@@ -41,14 +41,11 @@ def http_get(url):
def call_ollama(system, user, timeout=360):
- # /no_think disables qwen3 reasoning tokens (massive speedup, otherwise hangs on long prompts)
body = json.dumps({
'model': OLLAMA_MODEL,
- 'system': system,
- 'prompt': '/no_think\n\n' + user,
+ 'prompt': system + '\n\n' + user + '\n\nOutput only the updated JSON object, no explanation, no markdown.',
'stream': False,
- 'format': 'json',
- 'options': {'temperature': 0.4, 'num_ctx': 8192, 'num_predict': 2048},
+ 'options': {'temperature': 0.4, 'num_predict': 1500, 'num_ctx': 4096},
}).encode()
req = urllib.request.Request(
f'{OLLAMA_URL}/api/generate',
@@ -96,29 +93,15 @@ def validate_flow(flow):
def edit_flow_via_llm(current_flow, user_msg, entry):
system = (
- "You edit JSON flow files for a web-app demo video recorder.\n\n"
- "Schema: { \"steps\": [ ... ] }\n\n"
- "Action shapes:\n"
- " {\"action\":\"wait\",\"ms\":<int 500-3000>,\"narration\":\"<5-10 words>\"}\n"
- " {\"action\":\"scroll\",\"y\":<int>,\"duration\":<ms>,\"narration\":\"<5-10 words>\"}\n"
- " {\"action\":\"click\",\"selector\":\"<css>\",\"narration\":\"<5-10 words>\"}\n"
- " {\"action\":\"hover\",\"selector\":\"<css>\",\"narration\":\"<5-10 words>\"}\n\n"
- "Rules:\n"
- "- Use ONLY the four action types above. There is no \"type\" action.\n"
- "- Selectors must be valid CSS, ideally drawn from the provided selector hints.\n"
- "- Narration: short, punchy, 5-10 words, sales-pitch tone.\n"
- "- Total steps must be ≥6 and ≤14.\n"
- "- Output VALID JSON object only. NO commentary, NO markdown fences."
+ "Edit a JSON flow for a demo recorder. Action types: wait{ms,narration}, "
+ "scroll{y,duration,narration}, click{selector,narration}, hover{selector,narration}. "
+ "6-14 steps. Narration 5-10 words. Output ONE JSON object, nothing else."
)
user = (
- f"Current flow JSON:\n{json.dumps(current_flow, indent=2)}\n\n"
- f"App: {entry['app_name']}\n"
- f"URL: {entry['url']}\n"
- f"Available selectors / hints: {entry.get('selectors_hint', '(none)')}\n\n"
- f"User request: \"{user_msg}\"\n\n"
- "Output the COMPLETE updated flow JSON. Be creative — change narration tone, "
- "add hovers, reorder, swap selectors — whatever the user is asking for. If the "
- "request is ambiguous, make your best guess. Return only the JSON."
+ f"FLOW:\n{json.dumps(current_flow)}\n\n"
+ f"SELECTORS: {entry.get('selectors_hint', '(none)')}\n\n"
+ f"REQUEST: {user_msg}\n\n"
+ "Output the updated flow JSON."
)
try:
resp = call_ollama(system, user)
@@ -126,6 +109,7 @@ def edit_flow_via_llm(current_flow, user_msg, entry):
log_event({'event': 'ollama_error', 'error': str(e)})
return None
+ log_event({'event': 'llm_response_raw', 'head': (resp or '')[:400]})
new_flow = None
try:
new_flow = json.loads(resp)
← e82f4cb initial scaffold (gitify-all 2026-05-06)
·
back to Videos Agentabrams Worker
·
keep gemma3:4b warm with 30m keep_alive (eliminate 6min cold dbaac8f →