Borrowing it
Nothing to install: this file belongs to anhtester/claude-testing-kit. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/anhtester/claude-testing-kit/main/.claude/skills/skills-smart-locator-agent/SKILL.mdgit clone --depth 1 https://github.com/anhtester/claude-testing-kitWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/anhtester/claude-testing-kit/skills-smart-locator-agent)<a href="https://agentmods.dev/skills/anhtester/claude-testing-kit/skills-smart-locator-agent"><img src="https://agentmods.dev/badge/skills/anhtester/claude-testing-kit/skills-smart-locator-agent/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/anhtester/claude-testing-kit/skills-smart-locator-agent"><img src="https://agentmods.dev/badge/skills/anhtester/claude-testing-kit/skills-smart-locator-agent.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00030 | $0.00788 |
| Opus 5 | $0.00015 | $0.00394 |
| Sonnet 5 | $0.00006 | $0.00158 |
| Haiku 4.5 | $0.00003 | $0.00079 |
Grade A, and why
skills-smart-locator-agent scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 146 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Smart Locator Agent
Purpose: Generate stable and maintainable locators for UI automation.
Applicable frameworks:
- Playwright
- Selenium
- Appium
When to Use
Use this skill when:
- Generating locators for new UI elements
- Reviewing existing locators for stability
- Migrating locators between frameworks
Responsibilities
The agent must:
- Inspect the DOM or mobile UI hierarchy (NEVER guess)
- Identify stable attributes
- Generate a reliable locator
- Validate locator uniqueness
- Provide fallback locator if primary is fragile
Locator Priority
Use the following priority order:
- Accessibility attributes (aria-label, role)
data-testid/data-test/data-qaidname- Framework semantic locator
css selectorxpath(last option)
Note: For detailed rules, refer to
.claude/rules/locator_strategy.md.
Playwright Locators
Preferred locator methods:
getByRole()— Best for semantic elementsgetByLabel()— Best for form fields with labelsgetByPlaceholder()— Best for inputs with placeholder textgetByText()— Best for text contentgetByTestId()— Best when data-testid is available
Example:
page.getByRole("button", { name: "Submit" })
page.getByLabel("Email")
page.getByPlaceholder("Enter your password")
Note: For detailed rules, refer to
.claude/rules/playwright_rules.md.
Selenium Locators
Preferred order:
iddata-testidnamecssSelectorxpath
Example:
driver.findElement(By.id("login-button"));
driver.findElement(By.cssSelector("button[data-testid='submit-btn']"));
Note: For detailed rules, refer to
.claude/rules/selenium_rules.md.
Appium Locators
Preferred order:
accessibility idresource-ididiOS predicate stringclass chainxpath
Example:
driver.findElement(AppiumBy.accessibilityId("login_button"));
driver.findElement(AppiumBy.id("com.app:id/login_button"));
driver.findElement(AppiumBy.iOSNsPredicateString("label == 'Login'"));
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 146 lines · 30 tokens per session scan A e5c8dec8a34b
skills-smart-locator-agent is a skill published in the GitHub repository anhtester/claude-testing-kit (53 stars, last pushed 1mo ago), licensed MIT. It adds 30 tokens to every session and 788 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
Smart Locator Agent
Skill sinh locator ổn định và dễ bảo trì cho UI automation, hỗ trợ Playwright, Selenium và Appium.
web-test
A browser-automation tool for testing the 1C:Enterprise web client. It uses Playwright to navigate sections, fill forms, read tables and reports, and perform user actions in a browser.
Katalon Studio Testing
Comprehensive testing patterns for Katalon Studio including codeless record-and-playback, Groovy scripted testing, custom keywords, data-driven testing, cross-browser execution, and CI/CD integration with Katalon TestOps.
shaft-web-actions
Use when implementing SHAFT WebDriver or Playwright navigation, browser state, element interaction, upload, drag-and-drop, window, cookie, or screenshot behavior.
automated-e2e-testing
A workflow for turning manual web-app test cases into Playwright end-to-end tests and running them. End-to-end tests check a complete user flow through the website.
Framework Architect
Skill thiết kế và scaffold automation framework hoàn chỉnh cho Playwright, Selenium, và Appium — bao gồm project structure, base classes, config management, reporting, và CI/CD integration.