Skip to content

Commit 11513c1

Browse files
abrichrclaude
andcommitted
fix: skip visual alignment when demo has no real screenshots
Placeholder screenshots (19 bytes) cause pHash to produce garbage distances → low confidence → adaptive disabling kicks in after 3 steps → guidance disabled for entire episode. Manual demos with descriptions but no screenshots need sequential alignment to work. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 82ec2aa commit 11513c1

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

openadapt_evals/demo_library.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1382,10 +1382,18 @@ def align_step(
13821382
alignment_trace: AlignmentTraceEntry | None = None
13831383
demo_dir = self._demo_dir(task_id, demo.demo_id)
13841384

1385+
# Check if demo has real screenshots (not placeholders)
1386+
_has_real_screenshots = any(
1387+
s.screenshot_path and (demo_dir / s.screenshot_path).exists()
1388+
and (demo_dir / s.screenshot_path).stat().st_size > 100
1389+
for s in demo.steps
1390+
)
1391+
13851392
if (
13861393
use_visual_alignment
13871394
and current_screenshot is not None
13881395
and self._alignment_strategy is not None
1396+
and _has_real_screenshots
13891397
):
13901398
t0 = time.monotonic()
13911399

0 commit comments

Comments
 (0)