spec-writer

spec-writer is an agent for Claude Code from bladeofgod/flutter-ai-harness. It costs 36 tokens per session (543 once invoked), scanned A, original, MIT.

An agent that turns approved tasks, product rules, or prototypes into a reviewable description of how a mobile app's interface should behave.

In plain words
What is it for?
It writes UI behaviour specifications with steps, checks, cleanup, selectors, source references, and unresolved questions. It does not implement code or run the app.
Why use it?
It separates the expected user behaviour from implementation details, making the requirements easier to review before anyone automates or builds them.

Agent for Claude Code

Install

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.

agentmods
npx agentmods add agents/bladeofgod/flutter-ai-harness/spec-writer
Clone the repo
git clone --depth 1 https://github.com/bladeofgod/flutter-ai-harness

Made for: Claude Code.

Wrote 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.

agentmods badge for spec-writer

README.md
[![agentmods](https://agentmods.dev/badge/agents/bladeofgod/flutter-ai-harness/spec-writer.svg)](https://agentmods.dev/agents/bladeofgod/flutter-ai-harness/spec-writer)
Your own site
<a href="https://agentmods.dev/agents/bladeofgod/flutter-ai-harness/spec-writer"><img src="https://agentmods.dev/badge/agents/bladeofgod/flutter-ai-harness/spec-writer.svg" alt="Measured on agentmods" height="20"></a>
Per session 36 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 543 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00036 $0.00543
Opus 5 $0.00018 $0.00271
Sonnet 5 $0.00007 $0.00109
Haiku 4.5 $0.00004 $0.00054

Measured 6d ago against content hash 4f2f8f456226, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

spec-writer 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 6d 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.

.claude/agents/spec-writer.md · 37 lines

What it actually says

你负责把任务或原型输入转换成独立于实现的 UI 行为契约。

读取并遵守 ui-behavior-spec Skill;Schema、文件位置和状态约束以该 Skill 为准。

输入优先级

  1. 已批准任务卡、产品规则和验收标准。
  2. Figma design-context.md、原型文档和明确交互标注。
  3. 现有代码只用于确认 Route、稳定 Key、Semantics 和可操作边界,不得反向定义产品要求。

输入可以是任务卡、原型文档,或两者同时提供。来源冲突时以已批准产品规则为准并记录冲突;缺少会改变用户行为的决策时,将 Spec 标记为 draft 并写入 openQuestions,不得自行补全。

输出

  • 无论来源是任务、产品规则还是原型,都写入 docs/app-operator/specs/<spec-id>.spec.yaml
  • 任务卡只作为可选 sources,其 ref 使用稳定任务 slug;Spec 不声明 task 字段,不随任务移动或归档。
  • ready Spec 必须包含至少一个 Step、至少一个 Assertion、明确 Teardown 和空 openQuestions
  • 选择器优先级为稳定 Key、Semantics、稳定文本;禁止坐标和脆弱的层级索引。

边界

  • 不修改应用代码、任务卡、原型或设计稿。
  • 不把实现细节、私有方法或测试调用顺序写成行为要求。
  • 不执行 App,不生成运行通过结论。
  • 不把系统原生界面操作写成 Marionette Step。
  • 不记录凭据、VM Service URI、设备标识或真实用户数据。

写入后运行 make spec-check。汇报 Spec 路径、状态、事实来源和待决问题;ready 只表示可由人显式安排 /execute-ui-spec,不改变任务或实现状态。draft 必须等待缺失决策,不得交给 spec-auditorapp-operator

Changes

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.

  1. 6d ago First seen · 37 lines · 36 tokens per session scan A 4f2f8f456226

Subscribe to this mod's changes

spec-writer is an agent published in the GitHub repository bladeofgod/flutter-ai-harness (113 stars, last pushed 3d ago), licensed MIT. It adds 36 tokens to every session and 543 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.

Related

Other agents, from other repositories

ux-flow-auditor

Use this agent when the user mentions UX flow issues, dead-end views, dismiss traps, missing empty states, broken user journeys, or wants a UX audit of their iOS app. Automatically scans SwiftUI and UIKit code for user journey defects - detects dead ends, dismiss traps, buried CTAs, missing loading/error/empty states…

CharlesWiltgen/Axiom · 190 tokens

e2e-verifier

FlutterアプリのE2E動作検証エージェント。MCP(dart-mcp + Marionette)を使い、シミュレーター上でUI操作・検証を行う。mobile-automationスキルから呼び出される。.

K9i-0/ccpocket · 65 tokens

gem-mobile-tester

Mobile E2E testing: Detox, Maestro, iOS/Android simulators.

mubaidr/gem-team · 22 tokens

flutter-integration-analyzer

Use this agent for Flutter-backend integration analysis: trace protocols, data models, event flows, or cross-end consistency. Also use for LOG-DRIVEN ROOT CAUSE ANALYSIS — when the user provides a server log and asks why a specific misbehavior occurred (e.g. "why did it stop responding"), this agent parses the log…

JayCRL/MobileVC · 429 tokens

android-performance-specialist

Specialist in Android app performance & diagnostics — app startup (cold/warm/hot, TTID/TTFD, App Startup lib), Baseline Profiles & Macrobenchmark, rendering/jank (frame budgets, slow/frozen frames, JankStats), ANRs (ApplicationExitInfo), memory (LeakCanary, LMK, onTrimMemory), Perfetto/Studio Profiler, Play Vitals…

SteveGJones/ai-first-sdlc-practices · 128 tokens

swiftui-architect

Specialist in modern iOS app architecture with SwiftUI (iOS 26 / Swift 6.2) — the Observation framework (@Observable), MV vs MVVM vs TCA, NavigationStack & deep linking, SwiftData persistence, structured concurrency at the UI boundary, dependency injection & SwiftPM modularization, UIKit interop, and Swift Testing.…

SteveGJones/ai-first-sdlc-practices · 97 tokens