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 skills add TashanGKD/cognitive-os --skill cognitive-detect-contradictiongit clone --depth 1 https://github.com/TashanGKD/cognitive-osWrote 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/tashangkd/cognitive-os/cognitive-detect-contradiction)<a href="https://agentmods.dev/skills/tashangkd/cognitive-os/cognitive-detect-contradiction"><img src="https://agentmods.dev/badge/skills/tashangkd/cognitive-os/cognitive-detect-contradiction/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/tashangkd/cognitive-os/cognitive-detect-contradiction"><img src="https://agentmods.dev/badge/skills/tashangkd/cognitive-os/cognitive-detect-contradiction.svg" alt="Reviewed on agentmods" width="80" 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.1 | $0.00077 | $0.02507 |
| Opus 5 | $0.00039 | $0.01254 |
| Sonnet 5 | $0.00015 | $0.00501 |
| Haiku 4.5 | $0.00008 | $0.00251 |
Grade A, and why
cognitive-detect-contradiction 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 — 166 lines — stays where its author put it; the contents beside it link to each section on GitHub.
矛盾检测 Skill(Detect Contradiction)
识别认知结构中的逻辑矛盾,基于L1.5更高层原则提出消解方案,确保知识体系保持自洽。
认知根(L1.5 P15 共性优先):当检测到多个文档存在相似矛盾时,优先识别共同根因,生成统一消解方案;而非逐个矛盾单独处理。
激活后立即执行
Step 1 确定检测范围
→ 用户指定了具体文档/章节 → 精确检测
→ 用户说"全库"或"全部" → 系统级扫描(较慢,提前告知用户)
→ 用户说"刚才修改的地方" → 针对最近变更的文档
→ 不确定时,询问:「要检测哪个范围?[特定文档] [两文档之间] [全库] [最近更新]」
Step 2 读取目标文档
Read: 指定的L1文档(相关章节,不是整篇)
Read: cognitive/L1.5_principles/principles.md(P1/P2全文)
Read: cognitive/L0_brain_map.md(了解文档间依赖关系)
Step 3 矛盾检测分析
逐一检查以下矛盾类型:
[直接冲突] 两处明确相反的表述
例:"文档A说「先做调研再决策」,文档B说「直接MVP不做调研」"
[隐式张力] 两处在字面上不矛盾,但推论相冲突
例:"文档A的原则A暗示X,文档B的原则B暗示非X"
[范围不一致] 同一概念在不同文档的定义/边界不同
例:"「闭环」在文档A指用户路径,在文档B指组织协作流程"
[层次混淆] L2碎片级别的具体观察被当作L1原则表述
例:"一次具体经历被写成了通用规律"
[价值优先级冲突] 两条都成立的原则,在特定场景下建议方向相反(T4C 新增)
例:"原则A要求先路由再执行,原则B要求自动捕捉不依赖触发——当用户说了一句模糊但可能是碎片的话时,两条原则冲突"
→ 处理方式:不是哪条原则错了,而是需要明确优先级仲裁
→ 将冲突场景记录到「底层原则库.md §五 候选原则间已知优先级冲突」
Step 4【γ】 对每个发现的矛盾,展示分析结果(矛盾消解方案涉及认知方向选择,须用户决策)
「━━ 矛盾发现 ━━
类型:[直接冲突 | 隐式张力 | 范围不一致 | 层次混淆]
严重程度:[🔴 致命 | 🟡 中等 | 🟢 轻微]
位置A:[文档X] 第Y章 — 「...原文摘录...」
位置B:[文档Z] 第W章 — 「...原文摘录...」
矛盾描述:[一句话说清楚矛盾在哪里]
基于L1.5原则(P?「...」)推导消解方案:
选项A:修改[文档X]的[位置]:将「...」改为「...」
选项B:修改[文档Z]的[位置]:将「...」改为「...」
选项C:两者均成立,在[文档X]的[位置]添加前提说明:「适用场景为...时」
─────────────────────────
AI推荐:选项[?](原因:[一句话])
[选A] [选B] [选C] [我来决定] [这不是矛盾,跳过(需填原因)]」
→ 等用户明确选择后才能执行修改
价值优先级冲突(E类)的展示格式:
「━━ 价值优先级冲突 ━━
类型:价值优先级冲突(E类)
严重程度:🟡 中等
原则A:P??「...」— 在此场景建议:[X]
原则B:P??「...」— 在此场景建议:[Y]
冲突场景:[具体描述]
不是哪条原则错了,而是需要明确优先级仲裁:
选项A:此场景 A > B(原因:[...])
选项B:此场景 B > A(原因:[...])
选项C:场景再细分,A 和 B 各适用不同子场景
─────────────────────────
[选A] [选B] [选C] [我来决定] [这不是冲突,跳过(需填原因)]
→ 用户决策后,将结果追加到「底层原则库.md §五」仲裁表」
Step 5【α】 执行用户选择的消解方案(用户已在 Step 4 授权,AI 直接写入)(T7A 修复:跳过时强制记录原因)
→ 用户确认后,Write 修改对应文档
→ 追加 [文档名]_变更记录.md
→ 追加 cognitive/L3_logs/system_log.md
→ 写入 cognitive/L3_logs/consistency_record.md(新增检查结果条目)
→ 更新 L0_大脑总地图.md
[强制条件] 用户选择「跳过」时:
→ 【强制询问原因】「请简述跳过原因(必填):
[两者适用场景不同,不冲突] [已有更高层原则解决] [暂时不确定,需要更多证据] [自定义:...]」
→ 将跳过记录写入 cognitive/L3_logs/consistency_record.md,格式:
`[SKIP-JUDGMENT] 日期 | 文档对:[A]×[B] | 跳过原因:[用户选择的原因] | 矛盾描述:[简述]`
→ 告知:「已记录跳过理由。若此对文档累计跳过 ≥3 次,cognitive-consistency-check C13 将触发提醒。」
Step 6 如果无矛盾
「✅ 在[检测范围]内未发现矛盾。知识体系在该范围内保持自洽。」
→ 仍然追加一条 cognitive/L3_logs/consistency_record.md(记录「通过」)
→ 追加 cognitive/L3_logs/system_log.md
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 · 166 lines · 77 tokens per session scan A 0b4babc0a187
cognitive-detect-contradiction is a skill published in the GitHub repository TashanGKD/cognitive-os (9 stars, last pushed 5mo ago), licensed MIT. It adds 77 tokens to every session and 2,507 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-31.
Other skills, from other repositories
cocoaudit
View and export the append-only session audit trail for regulated environments.
audit-add
Add a clearly marked manual CocoAudit event. Usage: $audit add " ".
audit-timeline
Render CocoAudit records as a compact chronological timeline. Usage: $audit timeline.
810-regulations-eu-mifid-ii
Use when reviewing Java enterprise evidence for MiFID II investment services, investment activities, client classification, suitability, appropriateness, order-handling evidence, best-execution evidence, algorithmic-trading governance evidence, market-access governance evidence, transaction evidence, record keeping…
811-regulations-eu-market-abuse-regulation
Use when reviewing, designing, or modifying Java enterprise systems that may support EU Market Abuse Regulation concerns, market surveillance, suspicious order and transaction reports, insider dealing controls, unlawful disclosure controls, market manipulation detection, inside information disclosure workflows…
812-regulations-eu-product-liability-directive
Use when reviewing, designing, or modifying Java enterprise software products, AI-enabled products, RAG assistants, AI agents, generated instructions, related services, automated updates, vulnerability handling, corrective updates, warnings, instructions, or product-safety evidence under Directive (EU) 2024/2853, the…