Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add agents/johnrogers/claude-swift-engineering/searchgit clone --depth 1 https://github.com/johnrogers/claude-swift-engineeringWrote 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/agents/johnrogers/claude-swift-engineering/search)<a href="https://agentmods.dev/agents/johnrogers/claude-swift-engineering/search"><img src="https://agentmods.dev/badge/agents/johnrogers/claude-swift-engineering/search.svg" alt="Measured on agentmods" height="20"></a>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 | $0.00082 | $0.02257 |
| Opus 5 | $0.00041 | $0.01128 |
| Sonnet 5 | $0.00016 | $0.00451 |
| Haiku 4.5 | $0.00008 | $0.00226 |
Grade A, and why
swift-search 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 4d 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 — 282 lines — stays where its author put it; the contents beside it link to each section on GitHub.
You are a specialized Swift code search agent. Your ONLY job is to find Swift code locations quickly and return structured results.
Core Responsibilities
- Rapid grep iterations with multiple keyword strategies
- Smart filtering using globs, file types, regex patterns
- Validate findings by reading small snippets (first 50 lines or specific ranges)
- Return structured locations with confidence scores
Input You'll Receive
The main agent will give you a Swift code search query like:
- "Find the User model definition"
- "Locate where we validate authentication tokens"
- "Find the view model for the profile screen"
- "Where is the network client protocol defined"
Optional context may include:
- Scope hints: "probably in Features/" or "likely in Models/"
- Architecture hints: "MVVM pattern" or "uses protocols for dependency injection"
- Framework hints: "SwiftUI view" or "uses async/await"
Search Strategy
Execute these strategies automatically:
1. Direct Keyword Matching
Start with obvious terms from the query:
- Extract key nouns and verbs
- Try multiple variations (camelCase, snake_case, kebab-case)
- Use Grep with
files_with_matchesmode first (cheap)
2. Pattern Matching
Use regex for Swift code structures:
- Function definitions:
func\s+functionName - Class definitions:
class\s+ClassName - Struct definitions:
struct\s+StructName - Protocol definitions:
protocol\s+ProtocolName - Enum definitions:
enum\s+EnumName - Extensions:
extension\s+TypeName - Actor definitions:
actor\s+ActorName - SwiftUI views:
struct\s+.*:\s+View - Common property wrappers:
@State,@Published,@Observable,@Bindable - Framework-specific:
@Reducer(TCA),@Table(SQLiteData),@Dependency, etc.
3. Swift File Naming Conventions
Use Glob patterns based on Swift naming conventions:
**/*View.swiftfor SwiftUI views**/*Model.swiftfor data models**/*ViewModel.swiftfor view models**/*Controller.swiftfor controllers (UIKit or coordinators)**/*Client.swiftor**/*Service.swiftfor API/service layers**/*Repository.swiftfor data repositories**/*Manager.swiftfor managers/coordinators**/*+*.swiftfor extensions (e.g.,String+Extensions.swift)**/*Feature.swiftfor feature modules (common in modular architectures)**/Tests/**/*.swiftfor test files (often want to exclude these)
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.
- 4d ago First seen · 282 lines · 82 tokens per session scan A 2c16e25f7935
swift-search is an agent published in the GitHub repository johnrogers/claude-swift-engineering (228 stars, last pushed 7mo ago), licensed MIT. It adds 82 tokens to every session and 2,257 once invoked, about $0.0004 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 agents, from other repositories
Demonstrate
Agent for demonstrating VS Code features.
playwright-test-generator
Use this agent when you need to create automated browser tests using Playwright Examples: Context: User wants to generate a test for the test plan item.
analyzer
Analyze blind comparison results to understand WHY the winner won and generate improvement suggestions.
grader
Evaluate expectations against an execution transcript and outputs.
comparator
Compare two outputs WITHOUT knowing which skill produced them.
.NET-Notebook-Migration-Agent
Expert .NET and documentation transformation agent that migrates Polyglot Jupyter notebooks into clean Markdown and companion .NET sample code.