Devils Advocate logo

Devils Advocate

CommunityPopular
daymade
devils-advocate

结构化压力测试一个论点(devil's advocate / 魔鬼代言人):把论点拆成显性断言与隐性假设(A1/A2 编号), 逐条在用户给定的证据材料里检索带出处的反方论证,标 High/Medium/Low 风险等级,补基础比率外部视角, 最后给出「可监测的证伪信号」清单;输出结构化 findings + 人读叙事双层结果。找不到反证时如实声明「未找到」, 绝不编造。复刻自 LinqAlpha(对冲基金 AI 产品)公开的 Devil's Advocate 架构,叠加 CIA 结构化分析技术与 RAND 假设规划。当用户要「压力测试 / 唱反调 / 找盲点 / 拆假设 / 挑战这个论点 / bear case / 红队这个方案 / 上投委会前过一遍 / pressure test my thesis」,或拿着投资论点、IC memo、研究结论、商业决策要人挑刺时, 用本 skill——即使用户没说出"魔鬼代言人"这个词。

Overview

Publisherdaymade
Repositoryclaude-code-skills
Skill namedevils-advocate
Stars
1.4K
Forks
219
Bundled files
2
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 2 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by daymade on GitHub. Read the source before you install it.

Installation

Install the Devils Advocate AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/daymade/claude-code-skills.git /tmp/claude-code-skills
mkdir -p .claude/skills
cp -r /tmp/claude-code-skills/daymade-financial/devils-advocate .claude/skills/devils-advocate
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Devils Advocate in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Devils Advocate on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Devils Advocate is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Devil's Advocate 结构化反方论证

把「唱反调」从一种态度变成一道有出处、可审计、可持续监测的工序。

为什么这样设计(读懂了才不会走样)

三个实证结论决定了本 skill 的形状:

  1. 默认状态的 LLM 会讨好提问者。 经 RLHF 训练的模型系统性倾向于迎合用户已表达的信念而非说真话(Sharma et al., ICLR 2024)。分析师直接问模型「我这个论点对吗」,得到的答案有结构性偏正。所以反方角色必须被显式赋予,不能指望模型自发唱反调。
  2. 没有证据的唱反调不但没用,还会帮倒忙。 社会心理学的经典结果:角色扮演式的「指派反方」效果不如真实异议(Nemeth et al., 2001);后续研究进一步指出,不真实的异见反而让人更固守原判断(Nemeth, 2018)。所以本 skill 的每一条反方论证都必须锚定到具体材料的具体位置——证据锚定是「真实异议」的代理,自由发挥的抬杠被禁止。
  3. 显式反方人设的多 agent 结构有量化增益。「批评者」角色相对此前最优评估方法(G-Eval)有 6.4-12.5 个百分点的相关系数提升(DEBATE, ACL Findings 2024);论文另以定性结论指出反方人设显著优于中立多 agent 基线;多个「中立」agent 互评反而可能互相强化错误共识。

两个 references 常规执行不需要读:需要向使用者解释设计依据、或对某一步的做法产生疑问时才加载——完整谱系与逐字步骤见 references/structured_analytic_techniques.md;被复刻产品的原始 prompt 与 schema 见 references/linqalpha_reference_implementation.md

入口判断

用户给了什么走哪条路
论点 + 证据材料(文件/目录/URL 清单)完整六步流程(下文)
只有论点,没有材料先问用户要材料;用户说没有 → 请用户在两个选项里选:①先做检索把材料建起来再回来跑(若有检索类 skill 可先用)②只交付 Step 1 的假设拆解 + Step 5 的信号标(这两步不依赖材料;此时无 risk_flag 可筛,信号标覆盖全部负重假设),并明确说明反证检索未做
论点含混(一段散文、一个 IC memo)先按 Step 0 提炼出核心断言让用户确认,再继续
假设超过 8 条,或材料超大(总量超过约 20 万字 / 单文件读不完)主会话中用 fan-out 模式(见文末),全部负重假设进入检索;在子代理里运行本 skill 时只能单上下文,按负重排序取前 8 条

Step 0 · 输入确认

三样东西,缺一样就先补齐:

  1. 论点:一句核心断言 + 它的支撑推理。用户给的是长文时,提炼成「X 将因为 Y 而 Z」形态并请用户确认——拆错了论点,后面全白做。在子代理内运行、没有用户可确认时:写出规范化论点,放进两份产物的头部并标注「未经确认」,然后继续。
  2. 证据材料清单:具体的文件路径 / 目录 / URL。逐个确认可读;不可读的当场报告,不静默跳过。
  3. 用途:上会前自查、还是评估别人的方案?决定人读层的语气与详略。

Step 1 · 拆假设

把论点分解为两类,统一编号 A1、A2、A3……:

  • 显性断言(explicit assertions):论点里直接写出来的。
  • 隐性假设(implicit assumptions):没写出来、但论点要成立就必须为真的前提。这一类才是盲点的主产区——确认偏误让人看不见自己依赖了什么。

每条假设标两个属性:

  • 类型:事实性(现在就能核对)/ 预测性(关于未来)/ 机制性(关于因果链)。类型决定 Step 2 用什么反证。
  • 负重(load-bearing,RAND ABP 的判据):把这条假设推翻,结论会不会实质改变?不会 → 降级,不进入反证检索,只在附录列出。

枚举不设上限,照实列全;「8 条」约束的是进入反证检索的条数。一条假设里若藏着结论可能相反的两个子命题(例如「壁垒存在」与「壁垒的收益归属某一家」——前者可能幸存、后者可能被反转),拆成两条分别检索,再一起参加负重排序。单上下文模式下超过 8 条进入检索时按负重取前 8,其余明确列为「未检索」——宁可深挖 6 条也不要浅扫 15 条;主会话 fan-out 模式不受此限,全部负重假设进入检索。

Step 2 · 逐假设检索反证

对每条假设做两问(第二问是最容易漏的):

  1. 材料里有什么直接削弱、矛盾或引入不确定性的内容?
  2. 如果这条假设为真,材料里本应看到、却没看到的证据是什么?(ACH 的核心一问——缺席的证据也是证据)

检索时按信源可信度排序采信(改编自 LinqAlpha 的 SEC > 专家访谈 > 券商报告):

官方申报/公告/一手数据 → 专家访谈与电话会转录 → 券商/分析师报告 → 权威媒体报道 → 聚合转述/社媒(只能作线索,不能作反证锚点)

硬规则:

  • 每条反方论证必须带引用:来源文件(或 URL)+ 定位(页码/行号/章节)+ 逐字摘录。引语必须逐字,省略用省略号,禁止改写后仍加引号。
  • 找不到就写「未在给定材料中找到反证」,citations 置空。这是合法且有信息量的输出——但要在最终报告里注明它的含义只是「材料没覆盖」,不是「假设成立」。例外:材料里明确记录了「专门检索过且未找到」时,这本身是可引用的证据(「不存在的证据」强于「证据的不存在」),citations 指向那条记录。
  • 一条证据归一个主家:放在它最直接反驳的那条假设下,其他假设需要时以引用编号指向它;只有当它对两条假设各自构成独立的直接反驳时才可重复出现。

Step 3 · 结构化 findings(审计层)

默认写入当前工作目录的 da_findings.json(用户指定了位置则用用户的;供程序处理与复核)。顶层是一个对象而不是裸数组——覆盖面声明要有处安放(原厂 prompt 用裸数组,本 skill 为此改为对象):

json
{
  "run_metadata": { "thesis_normalized": "<规范化论点(无用户确认时标「未经确认」)>",
                    "materials": ["<材料清单与各自偏性>"],
                    "coverage": "<枚举 N 条 / 检索 M 条 / 未检索 K 条 / 降级 J 条>" },
  "findings": [ "<每条假设一个条目,结构见下>" ],
  "deferred_assumptions": [ "<降级与未检索的假设及理由>" ]
}

findings 里每条假设一个条目:

json
{
  "assumption_id": "A1",
  "assumption": "<该假设的一句话精炼复述>",
  "type": "事实性 | 预测性 | 机制性",
  "counter_argument": "<证据支撑的反方论证,分析师文风,2-3 句>",
  "citations": [ { "doc": "<文件名或URL>", "loc": "<页/行/节>", "excerpt": "<逐字摘录>" } ],
  "rebuttal": "<材料中削弱本条反证的反-反证(如「打断者自己也延期了」),有则填;无则 null>",
  "missing_evidence": "<若假设为真本应看到却没看到的证据;无则 null>",
  "base_rate": "<外部视角:这类断言的历史成立率,有数据才写,无则 null>",
  "risk_flag": "High | Medium | Low",
  "signpost": "<可观测的证伪信号:什么事件/阈值出现说明这条假设正在失效,到哪里看>"
}

risk_flag 衡量的是这条反证对论点的杀伤力,不是发生概率。三档锚定:High = 该反证若成立,论点的核心结论不再成立;Medium = 结论仍立,但幅度或时间表显著折损;Low = 边际修正。防膨胀约束:若超过半数条目被判 High,先把全部条目按杀伤力互相排序再重新定档——全是 High 等于没有分级(首次实测第一版就判出了 6/8 个 High)。citations 至少一条(例外见 Step 2 的置空规则);强反证常由多条独立事实叠加而成,全部列入而不是只挑一条。base_rate 是 Mauboussin 外部视角(LinqAlpha 没有的一层):把假设放进参考类问「别人处在同样处境时结果如何」——只在给定材料内能构建参考类时填写(例如用材料自身记录的历史预测修正幅度),撑不起来就诚实置空。禁止编一个基础比率,也不为此另起检索:另查会破坏「论点 vs 给定材料」的检验边界,确需外部基础比率时明示使用者补充材料。

Step 4 · 人读层渲染(交付层)

结构化条目不直接给人看(原厂的实际产品也是渲染成叙事层交付的)。人读层默认写入工作目录的 da_report.md 并同时在对话中交付。渲染规则:

  • 开头一小段:先给覆盖面声明(检索了哪些材料、多少条假设进入检索、多少条未检索、材料构成有何偏性——例如「三份研报全是买入评级」这类元问题),再用几句话点出最有杀伤力的 2-3 条反证与论点最薄弱的一面。不下「论点对/错」的整体判决。
  • 正文按主题分组(分组维度默认跟随论点自身的推理链条、每个环节一组,几条相关假设合并成一个小标题),不按 A1/A2 流水罗列;行文里用行内编号 [1] [2] 挂引用——[n] 按引用在正文首次出现的顺序编号。
  • 每条论证 2-3 句,机构分析师文风:事实、克制、聚焦实质风险(竞争、监管、利润率、技术替代),不用感叹号不用反问句。
  • 文末三个清单:References([n] 编号对应的来源与逐字摘录,每条注明它反驳的假设编号 A1/A2)、幸存假设(检索后未找到反证的条目,注明「未找到 ≠ 成立」)、覆盖面附录(降级的非负重假设 + 超限未检索的假设,给开头的覆盖面声明以明细支撑)。

Step 5 · 信号标清单

报告的最后一节:每条 High/Medium 假设一行——「盯什么、到哪看、什么读数算警报」(无材料模式下无 risk_flag 可筛,覆盖全部负重假设)。假设的脆弱性随时间变化,这一步把一次性批判延伸成可持续监测,是本 skill 长期价值所在——建议使用者把它并入自己的监测例程。

红线

  • 不替用户判断论点整体对错、不给买卖建议——本 skill 的产出是「压力清单」,决策留给人。
  • 反证的强度以证据为限:材料只支持「引入不确定性」就不许写成「证伪」。
  • 语气校准:全程事实中立。魔鬼代言人是一道工序,不是一种情绪。
  • 覆盖面诚实:报告开头声明检索了哪些材料、多少条假设进入了检索、多少条未检索。

本 skill 不能做什么(写给使用者,也写给执行的模型)

  • 它检验的是「论点 vs 给定材料」,不是「论点 vs 世界」。 材料本身有偏(比如全是看多研报),反证自然贫瘠——报告要指出材料构成的偏性,必要时建议补什么类型的材料。
  • 它不能替代真实的持仓反方。 Nemeth 的结果同样约束 AI:证据锚定缓解了「角色扮演无效」问题,但一个真金白银持反方仓位的人类对手仍是更强的测试(Buffett 请做空者上股东会是这个道理)。
  • 一次运行是快照。 假设的脆弱性随时间变化——所以信号标清单才是长期价值所在,建议用户把它并入自己的监测例程。

Fan-out 模式(仅主会话可用)

材料量大或假设多时,主会话按此并行:

  1. 主会话完成 Step 0-1(拆假设必须在主上下文做——它需要完整理解论点)。
  2. 每条(或每 2-3 条)假设派一个子代理:prompt 给「假设原文 + 材料路径清单 + Step 2 的两问 + Step 3 的 JSON 结构与 risk_flag 三档锚定(逐字内联)+ 逐字引用与禁编造规则」,并指定各自的落盘绝对路径(工作目录下 da_findings_A<编号>.json),要求先落盘再返回摘要。
  3. 主会话收齐后合并为 da_findings.json:去重(同一证据被多条假设引用时,归属给 risk_flag 更高的那条,其余条目改为指向同一引用编号)、按三档锚定复核 risk_flag,再做 Step 4-5 的渲染与信号标。
  4. 子代理内运行本 skill 时不可再派代理——退回单上下文模式。

与其他 skill 的组合

  • 材料不足时,先用检索/行业研究类 skill(如同套件的 daymade-sector-research)把证据库建起来,再回来跑本流程——本 skill 假定材料已在手。
  • 压测完成后的自然下一步:把信号标清单并入用户的监测例程,或对修订后的论点 2.0 再跑一轮(版本化对比:哪些反证被吸收了、哪些被反驳了)。按需建议,不强推。

设计依据(速查)

设计元素来源
四步流程、显性/隐性假设分类、citation 强制、风险分级、双层输出LinqAlpha Devil's Advocate(AWS 官方技术博客 2026-02 公开的生产 prompt 与 schema)
「未说明但必须为真」的假设定义、逐条追问「为什么必须成立」CIA Key Assumptions Check(Tradecraft Primer, 2009)
证伪优先、「该看到而没看到的证据」Analysis of Competing Hypotheses(Heuer / CIA Primer)
负重假设、信号标(signpost)RAND Assumption-Based Planning(1993/2002)
外部视角 / 基础比率层Mauboussin & Callahan, The Base Rate Book(2016)
证据锚定的必要性(角色扮演式异议无效)Nemeth et al.(2001)
显式反方人设优于中立多 agentDEBATE(ACL Findings 2024);Du et al. 多智能体辩论(2023)

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Devils Advocate AI skill do?

结构化压力测试一个论点(devil's advocate / 魔鬼代言人):把论点拆成显性断言与隐性假设(A1/A2 编号), 逐条在用户给定的证据材料里检索带出处的反方论证,标 High/Medium/Low 风险等级,补基础比率外部视角, 最后给出「可监测的证伪信号」清单;输出结构化 findings + 人读叙事双层结果。找不到反证时如实声明「未找到」, 绝不编造。复刻自 LinqAlpha(对冲基金 AI 产品)公开的 Devil's Advocate 架构,叠加 CIA 结构化分析技术与 RAND 假设规划。当用户要「压力测试 / 唱反调 / 找盲点 / 拆假设 / 挑战这个论点 / bear case / 红队这个方案 / 上投委会前过一遍 / pressure test my thesis」,或拿着投资论点、IC memo、研究结论、商业决策要人挑刺时, 用本 skill——即使用户没说出"魔鬼代言人"这个词。

Why use Devils Advocate on TypingMind?

Because you install it once and use it with any model. Devils Advocate is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Devils Advocate in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/daymade/claude-code-skills/tree/main/daymade-financial/devils-advocate. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Devils Advocate?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Devils Advocate?

As many as you like. As long as a model supports skills, you can use Devils Advocate with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Devils Advocate AI skill free?

Yes. It is published on GitHub by daymade under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇