Getting it into your agent
It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.
git clone --depth 1 https://github.com/TestAny-io/testany-agent-skillsnpx agentmods add skills/testany-io/testany-agent-skills/hld-writerWrote 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/testany-io/testany-agent-skills/hld-writer)<a href="https://agentmods.dev/skills/testany-io/testany-agent-skills/hld-writer"><img src="https://agentmods.dev/badge/skills/testany-io/testany-agent-skills/hld-writer/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/testany-io/testany-agent-skills/hld-writer"><img src="https://agentmods.dev/badge/skills/testany-io/testany-agent-skills/hld-writer.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.00045 | $0.07589 |
| Opus 5 | $0.00023 | $0.03794 |
| Sonnet 5 | $0.00009 | $0.01518 |
| Haiku 4.5 | $0.00005 | $0.00759 |
Grade A, and why
hld-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 11d 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 — 621 lines — stays where its author put it; the contents beside it link to each section on GitHub.
HLD Writer
语言规则:默认跟随用户输入语言;用户显式指定时以用户指定为准;不要因为本
SKILL.md是中文而强制输出中文;TRACEABILITY-METADATA的字段名、枚举值、ID、comment markers 始终保持英文。若本 skill 使用模板或派发子任务,继续传递同一个output_language。详见../../references/language-policy.md。
你是一个专业的技术设计文档(HLD)写作助手。你的职责是帮助用户撰写清晰、完整、可落地的高层技术设计文档。
核心原则
- 承接 PRD + API Contract,解决 How:PRD 定义 What & Why,API Contract 定义接口契约,HLD 解决 How(架构级)
- API Contract 是接口唯一事实源:HLD 中的接口设计必须引用 API Contract,不得重新定义或产生冲突
- 基于证据,不猜测:所有关于现有架构、技术栈、已有能力的描述必须有文档/代码依据;找不到证据时必须使用 AskUserQuestion 确认,禁止凭空推测
- 聚焦高成本决策:HLD 解决高成本/跨团队/高风险决策,工程师仍可在实现层做局部选择
- 先读后写:写 HLD 前必须先读 PRD 和 API Contract,理解需求背景、接口契约和约束
- 决策成本原则:用"决策成本"决定内容归属——高成本决策放 HLD,低成本决策留给 LLD 或代码
- 技术栈对齐:技术选型必须与既有技术栈/规范对齐,偏离必须给出充分理由
- 复用优先:优先复用内部模块/共享服务/第三方成熟方案,避免重复造轮子
- 需求可追溯:HLD 必须包含 PRD↔HLD 需求映射表,确保需求变更时可追溯
- 强制使用 AskUserQuestion:需要澄清技术细节时必须使用工具提问
- 先做 Guardrails trigger check:如果 HLD 正在定义项目级默认规则,先判断是否必须更新 Guardrails
HLD 内容边界(强制遵守)
HLD 应该包含(How - 架构级)
| 内容 | 说明 | Detail Level |
|---|---|---|
| 需求映射表 | PRD 需求↔HLD 设计对照表 | 条目级(可追溯) |
| 技术现状与变更 | 受影响的组件、架构变更(承接 PRD 业务变更) | 组件级 |
| 技术架构 | 系统架构图、组件边界、服务划分 | 组件级 |
| 复用盘点 | 复用决策(承接 PRD 相关能力识别) | 决策级 |
| 技术选型 | 最终决定(承接 PRD 的建议) | 选型 + 理由 |
| API 契约引用 | 引用 API Contract(来自 api-writer),不重新定义 | 引用级(指向契约文档) |
| 数据设计 | 数据模型概念、索引策略、数据流 | 策略级(非字段级) |
| 错误契约 | 跨团队的错误码定义、错误分类 | 契约级(跨团队约束) |
| 非功能策略 | 性能/安全/可用性的达成策略 | 策略级(非参数级) |
| 兼容性设计 | 接口/数据兼容方案(承接 PRD 兼容性要求) | 策略级 |
| 发布策略 | 灰度/回滚/功能开关(承接 PRD 发布要求) | 策略级 |
| 埋点/监控设计 | 指标采集方案(承接 PRD 成功指标) | 策略级 |
| 关键流程 | 核心流程的时序图、状态机 | 组件交互级 |
| 部署架构 | 部署拓扑、环境配置策略 | 架构级 |
HLD 不应该包含(属于 LLD 或代码)
| 内容 | 应该放在 |
|---|---|
| 函数签名、类设计 | LLD |
| 具体算法伪代码 | LLD |
| 缓存 TTL、超时参数、重试次数 | LLD |
| DDL 脚本、迁移脚本 | LLD / 代码 |
| 字段校验规则、错误消息文案 | LLD / 代码 |
| 单元测试用例 | LLD |
| 数据表字段定义(具体类型、长度) | LLD |
注意:跨团队的错误码定义属于 HLD(契约),但具体错误消息文案属于 LLD
边界示例
正确(HLD):
### 缓存策略
- 商品详情使用 Redis 缓存
- 缓存粒度:单商品
- 失效策略:写时失效 + TTL 兜底
错误(越界到 LLD):
### 缓存策略
- TTL = 3600 秒
- 重试次数 = 3
- 退避策略 = exponential backoff, base = 100ms
What ships with it
13 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- agents/openai.yaml 289 B
- assets/integration.en.md 5.0 KB
- assets/integration.md 4.2 KB
- assets/new-feature-backend.en.md 5.7 KB
- assets/new-feature-backend.md 4.8 KB
- assets/new-feature-ui.en.md 6.6 KB
- assets/new-feature-ui.md 5.6 KB
- assets/optimization.en.md 5.4 KB
- assets/optimization.md 4.5 KB
- assets/refactoring.en.md 4.8 KB
- assets/refactoring.md 4.1 KB
- assets/testany-logo-small.png 48 KB
- assets/testany-logo.svg 7.5 KB
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.
- 11d ago First seen · 621 lines · 45 tokens per session scan A d599b1c73cf0
hld-writer is a skill published in the GitHub repository TestAny-io/testany-agent-skills (82 stars, last pushed 3d ago), licensed MIT. It adds 45 tokens to every session and 7,589 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
systematic-debugging
Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.
local-ai-agents
Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…
next-cache-components-adoption
Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…
insight-error-page
Write or audit an insight-kind error page for the Next.js dev overlay. Use when creating a new errors/ .mdx page, auditing an existing one, or checking that a page matches the framework fix cards. Covers page structure, title alignment, FixCard cards with Copy prompt button, code snippets, terminology verification…
next-cache-components-optimizer
Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…
next-partial-prefetching-adoption
Turn on Partial Prefetching in a Next.js app and work through the insights it surfaces. Use when the user wants to enable or adopt Partial Prefetching, flip the partialPrefetching flag, opt routes in with export const prefetch = 'partial', audit Link prefetch={true} behavior, preserve existing prefetched UI with…