knowledge-finalize

knowledge-finalize is a skill for Claude Code from cogni-work/insight-wave. It costs 137 tokens per session (31,289 once invoked), scanned C, original, Apache-2.0.

A final step for a research pipeline that saves a checked draft as a page in a connected wiki. It also updates the wiki's indexes, records the project, and runs structural checks.

In plain words
What is it for?
Use it to publish a verified research draft, update wiki navigation and records, and confirm the deposited page meets the wiki's format rules.
Why use it?
It prevents verified research from remaining as an isolated file that future research cannot reuse.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: mentions CLAUDE.md; names the AskUserQuestion tool.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the cogni-knowledge plugin — 23 skills, 16 agents shipped together

Good fit Use it to publish a verified research draft, update wiki navigation and records, and confirm the deposited page meets the wiki's format rules.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add cogni-work/insight-wave
Claude Code
/plugin install cogni-knowledge

Made for: Claude Code.

Or install cogni-knowledge, the plugin that ships this one along with the rest of its 23 skills, 16 agents.

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 knowledge-finalize

README.md
[![agentmods](https://agentmods.dev/badge/skills/cogni-work/insight-wave/knowledge-finalize/github.svg)](https://agentmods.dev/skills/cogni-work/insight-wave/knowledge-finalize)
Your own site
<a href="https://agentmods.dev/skills/cogni-work/insight-wave/knowledge-finalize"><img src="https://agentmods.dev/badge/skills/cogni-work/insight-wave/knowledge-finalize/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.

agentmods 80×15 button for knowledge-finalize

Your own site · 80×15
<a href="https://agentmods.dev/skills/cogni-work/insight-wave/knowledge-finalize"><img src="https://agentmods.dev/badge/skills/cogni-work/insight-wave/knowledge-finalize.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 137 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 31,289 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 2 findings. A grade says what 26 rules found in the file — not that it is safe.
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.00137 $0.31289
Opus 5.5 $0.00055 $0.12516
Sonnet 5.5 $0.00027 $0.06258
Haiku 4.5 $0.00014 $0.03129

Measured 1mo ago against content hash a545d7a1d115, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade C, and why

knowledge-finalize scanned grade C with 2 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 1mo 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.

Recursive force deletehighDestructive command

rm -rf with a variable or a broad path is one typo away from removing the wrong tree.

rm -rf "<project_path>/.metadata/verify-shards"

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

[`references/finalize-compose-subprocess.md`](../../references/finalize-compose-subprocess.md)
cogni-knowledge/skills/knowledge-finalize/SKILL.md · 1,146 lines

How it starts

The opening of the file, as written. The whole thing — 1,146 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Knowledge Finalize

Phase 7 of the inverted pipeline. Reads <project>/output/draft-vN.md + <project>/.metadata/verify-vN.json + <project>/.metadata/citation-manifest.json, runs cycle-guard.py to refuse self-citing loops, deposits the verified draft as <WIKI_ROOT>/wiki/syntheses/<synthesis-slug>.md, runs three cogni-wiki helpers (wiki_index_update.py, config_bump.py, rebuild_context_brief.py) directly at script level, appends a research_projects[] entry to binding.json, writes one ## [YYYY-MM-DD] finalize | … line to wiki/log.md, and runs a Step 10.5 conformance gate (lint_wiki.py --fix=all + health.py) so the deposited base passes cogni-wiki's own structural checks.

This is the inverted-pipeline closing step. Without it, every verified draft lives forever in <project>/output/ and the wiki cannot accumulate cross-source framing — the compounding property that differentiates cogni-knowledge from one-shot deep-research tools requires future knowledge-compose runs to read wiki/syntheses/*.md as prior context. Finalize is what makes that read non-empty.

Synthesis-page frontmatter shape (matches cogni-wiki SCHEMA for type: synthesis per cogni-wiki/CLAUDE.md §"Page Frontmatter"):

---
id: <synthesis-slug>
title: <plan.topic verbatim>
type: synthesis
tags: [synthesis]
created: <today ISO>
updated: <today ISO>
sources:
  - wiki://<cited-slug-1>
  - wiki://<cited-slug-2>
derived_from_research: <project-slug>
draft_revision_round: <verify.revision_round>
---

derived_from_research is stamped inline (no lineage-stamp.py dispatch — that helper walks raw/research-<slug>/, which inverted-pipeline projects don't write to). draft_revision_round is informational; cogni-wiki's lint allows arbitrary additive frontmatter keys.

Read ${CLAUDE_PLUGIN_ROOT}/references/inverted-pipeline.md §"Phase 7 — knowledge-finalize" once to anchor on the contract.

When to run

  • <project>/.metadata/verify-vN.json exists for the latest output/draft-vN.md (Phase 6 / knowledge-verify has run).
  • User explicitly invokes /cogni-knowledge:knowledge-finalize.

Read the full file on GitHub · 1,146 lines

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. 1mo ago Changed a545d7a1d115
  2. 1mo ago Changed · -2 lines b4f5463e1212
  3. 1mo ago First seen · 1,148 lines · 137 tokens per session scan C cd746008f592

Subscribe to this mod's changes

knowledge-finalize is a skill published in the GitHub repository cogni-work/insight-wave (13 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 137 tokens to every session and 31,289 once invoked, about $0.0005 per session on Opus 5.5. A static security scan graded it C with 2 findings (recursive force delete, runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

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…

microsoft/ai-agents-for-beginners · 200 tokens

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

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…

vercel/next.js · 95 tokens

chat-pet-sprite-creation

Use when creating or changing VS Code chat pet sprite art, sprite sheets, state animations, eye treatments, Stable/Insiders variants, or pet transitions under src/vs/workbench/contrib/chat/browser/widget/media/chatPet.

microsoft/vscode · 53 tokens

cpu-profile-analysis

Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…

microsoft/vscode · 71 tokens

next-cache-components-optimizer

Optimize the meaningful UI available immediately from a Next.js route on an initial load (hard navigation) or named client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route and entry point at a time; the shipped test then guards…

vercel/next.js · 123 tokens