competitive-teardown
Positioning map + feature matrix + pricing comparison + opportunity windows: transforms competitor materials into an actionable product decision report.
1How It Works & Mechanism
The template itself contains no executable code: loader reads frontmatter and body from src/lib/templates/skills/<id>/SKILL.md, and returns body along with example content as LoadedSkill.
const raw = safeRead(path.join(dir, "SKILL.md"));
The host assembles the prompt in a fixed manner before dispatch: the template body is sandwiched between SHARED_DESIGN_DIRECTIVES and [Input Format]/[User Content].
Wrap a per-template instruction body with the shared design directives and
Shared directives formulate hard constraints as explicit prohibitions for the agent and enforce a content-driven quantity rule (numbers in templates serve only as reference lower bounds).
**禁止使用 Write / Edit / MultiEdit / Bash / Create / 任何文件系统工具**。
Actual execution is performed by the coding agent CLI already installed and logged in on the user's local machine: the host spawns a child process, hands the prompt to it, and streams HTML output from stdout.
import { spawn, type ChildProcessWithoutNullStreams } from "node:child_process";
/api/convert is the execution path for templates: it assembles skill.body and user content into a prompt and passes it to invokeAgent.
prompt = assemblePrompt({ body: skill.body, content, format });
The core of the template is a fixed 9-section structure: from Header, Executive takeaway, Positioning map, all the way to 30/90/180-day Recommended moves; missing sections constitute failure.
【必须输出的结构】
The positioning map and feature matrix are mandated to be generated from user content rather than template boilerplate: axes must derive from source materials, matrix columns include Us / Opportunity, and ✓/△/— are used for coverage.
3. Positioning map: 用 2×2 象限或坐标图表现竞品定位。坐标轴必须来自用户内容, 不要套模板词。
One card per competitor with fixed fields: target user / core promise / pricing signal / primary strength / visible weakness; opportunity windows strictly include why now, target segment, first move, and risk.
8. Opportunity windows: 3 个机会窗口, 每个包含 why now、target segment、first move、risk。
Includes a dedicated content authenticity section: use only user-provided materials, label missing information as 'not found in source' / 'unknown', prohibit fabricating market share/ARR/customer names/pricing, and list gaps under Evidence gaps if data is insufficient.
- 只使用用户提供的竞品、价格、功能、评论。缺失信息用 "not found in source" 或 "unknown" 标注。
Three stylistic choices are provided via HTML references in assets/ (war-room-grid as default, radar-map dark intelligence console, analyst-dossier paper research report), requiring selection based on input characteristics without mixing.
- `assets/war-room-grid.html`: 默认风格。浅色战情室 / 咨询报告, 适合产品团队、PM、普通商业读者。
2Core Capabilities
4Recommended Governance & Evidence
- SKILL.md: Pure prompt directives and rule text, without script execution or external side effects
5Second-Pass Verification
- [discrepancy] 九段结构在示例中的覆盖度 — example.html 展示了 Header、Executive takeaway(3 条)、Positioning map、3 张竞品卡、Feature matrix(含 not found / unknown 单元格)、30/90/180 天 moves;但第 6 段 Pricing / packaging read 与第 7 段 UX / messaging notes 未独立成节,第 8 段 Opportunity windows 亦未以独立小节出现(部分内容并入卡片与矩阵注释)。模板能力以 SKILL.md 为准,示例属精简演示。
- [ok] 内容真实性纪律的可见落地 — 矩阵中逐字出现 unknown(Transcript library 行)与 not found(CRM / sales workflow、Cross-interview insight cards 行),与 SKILL.md 要求的标注词一致,证明该纪律可被执行。
- [ok] 三套 assets 是否为真实不同风格 — war-room-grid:浅色 --paper:#f7f4ec + Inter;radar-map:深色 panel rgba(13,27,45,.76) + 径向雷达网格 repeating-radial-gradient;analyst-dossier:双线规则 .rule + 红色 stamp 旋转 -2deg + IBM Plex Serif 衬线。三份互不相同的实现坐实风格三选一。
- [ok] 端点与判级 — SKILL.md 正文无 URL/端点要求;端点只出现在 assets 与 example 的 cdn.tailwindcss.com <script> 及字体链接,属产物期引用层,执行期零外发,维持 green。
- [ok] license / stars / commit 元数据 — GitHub API(api.github.com/repos/nexu-io/html-anything):spdx_id=Apache-2.0、stargazers_count=8827、pushed_at=2026-09-15T03:36:24Z;工作副本 git HEAD = 553ed98c283f9c0f489902d035416a972d6a9699(与任务表 pin 553ed98c283f 同源)。
- [ok] skill.path 与目录资产面 — pin 目录内该路径存在且含 SKILL.md;目录内文件清单已用 glob 全量核对(含隐藏文件),无 scripts/、无 references/、无二进制资产(competitive-teardown 的 assets/ 为纯 HTML,另行记录)。
6Verdict & Scenarios
99cee63fe9181008…