Claude Skill MartBrowse skillsQuick linesLearn by videoTerminal guideWhat is a Skill?
← Back to list

TestDriver Caching Guide

A reference skill explaining how TestDriver caches AI-vision-found UI elements for fast, deterministic test replays.

Dev & CodingIntermediate★ 243⑂ 37AI score 6/10Last updated: Sep 21, 2026

What it does

  • Explains how TestDriver stores each element found by find() as a vision fingerprint (perceptual hash) for instant replays.
  • Documents the cache key inputs: test file SHA-256 hash, selector prompt text, screenshot context hash, and platform/browser version.
  • Shows how to configure caching via cacheKey, cacheDefaults.threshold, and per-call cacheThreshold.
  • Provides a debugging pattern using element.cacheHit, cacheStrategy, and similarity.

Who it's for

  • QA engineers and frontend developers writing E2E tests with TestDriver.
  • Teams trying to cut AI vision latency and cost in CI pipelines.
  • Anyone whose cache hit rate suffers from dynamic values inside prompts.

Examples

  1. A login test keeps re-running AI analysis → check whether the test file hash changed or the prompt text varies.
  2. Prompts like input for ${email} pollute the cache → pin them with cacheKey: 'email-input'.
  3. Matching feels too loose → tighten with cacheThreshold: 0.01 for 99% similarity.

· · · Install guide · · ·

Try it now, no install

Paste this into Claude to use the skill without installing anything.

Read the instructions in this file and follow them to help me:
https://raw.githubusercontent.com/testdriverai/testdriverai/HEAD/ai/skills/testdriver-caching/SKILL.md

What I want: (describe your task here)

If Claude can't open the link, open it yourself and paste the contents instead.

↓ If it works for you, download the ZIP below and install it. Then it runs on its own — no pasting each time.

Install in the Claude app (no terminal)
  1. Download the ZIP with the button below.
  2. In Claude, open Settings → Capabilities and turn on 'Code execution and file creation'. (one time)
  3. Go to Customize → Skills → + → 'Upload a skill' and upload the ZIP.
↓ Download ZIP
Install in Claude Code

Let Claude do it — paste this into Claude Code

Install the skill I found on Claude Skill Mart.
Copy the ai/skills/testdriver-caching folder from the GitHub repo testdriverai/testdriverai into my ~/.claude/skills/testdriver-caching/.
When it's done, tell me in one line what this skill can do.

Install with a command instead

git clone https://github.com/testdriverai/testdriverai.git && mkdir -p ~/.claude/skills && cp -r testdriverai/ai/skills/testdriver-caching ~/.claude/skills/

⚠ This is a third-party skill. Check the source repository before installing.

  1. Open a terminal.
  2. Clone the repo: git clone https://github.com/testdriverai/testdriverai.git
  3. Create the skills folder: mkdir -p ~/.claude/skills
  4. Copy the skill: cp -r testdriverai/ai/skills/testdriver-caching ~/.claude/skills/
  5. Restart Claude Code and confirm testdriver:caching appears in your skill list.
  6. For real usage, install the package with npm i testdriverai and set the TD_API_KEY environment variable.