portfolio-lineage

portfolio-lineage is a skill for Claude Code from cogni-work/insight-wave. It costs 128 tokens per session (2,689 once invoked), scanned A, original, Apache-2.0.

A source-tracking tool that records where portfolio information came from, detects changed documents or web pages, and marks related work for refresh.

In plain words
What is it for?
Use it to register sources, check for changes, trace dependencies, and guide updates through the portfolio chain.
Why use it?
It helps prevent outdated features, messages, and solutions from remaining based on changed source material.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

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-portfolio plugin — 16 skills, 14 agents shipped together

Good fit Use it to register sources, check for changes, trace dependencies, and guide updates through the portfolio chain.

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-portfolio

Made for: Claude Code.

Or install cogni-portfolio, the plugin that ships this one along with the rest of its 16 skills, 14 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 portfolio-lineage

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

Your own site · 80×15
<a href="https://agentmods.dev/skills/cogni-work/insight-wave/portfolio-lineage"><img src="https://agentmods.dev/badge/skills/cogni-work/insight-wave/portfolio-lineage.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 128 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,689 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 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.00128 $0.02689
Opus 5.5 $0.00051 $0.01076
Sonnet 5.5 $0.00026 $0.00538
Haiku 4.5 $0.00013 $0.00269

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

Security

Grade A, and why

portfolio-lineage 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 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.

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.

cogni-portfolio/skills/portfolio-lineage/SKILL.md · 210 lines

How it starts

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

Source Lineage

Track input sources, detect changes, and guide refresh cascades through the portfolio entity chain.

Core Concept

Plugin root resolution. Bash invocations below resolve the plugin root inline as ${CLAUDE_PLUGIN_ROOT:-$(ls -td "$HOME"/.claude/plugins/cache/insight-wave/cogni-portfolio/*/ | head -1)} — the first call works whether or not the harness injects $CLAUDE_PLUGIN_ROOT. Keep the inline form in every call; do not strip it.

Portfolio entities (features, propositions, solutions) are derived from input sources — uploaded documents, web research URLs, and TIPS enrichment. When those sources change (a document is re-uploaded, a URL's content changes), downstream entities become stale. This skill manages the full lineage lifecycle:

  1. Register sources with fingerprints during ingestion
  2. Detect when sources have changed
  3. Trace which entities came from which sources
  4. Cascade staleness through the dependency chain
  5. Guide the user through a refresh in the correct order

The source registry (source-registry.json) is the central manifest. It tracks every input source, its SHA-256 fingerprint, and which entities it created. The portfolio-ingest skill creates registry entries automatically; this skill manages the registry lifecycle afterward.

Prerequisites

  • An active cogni-portfolio project (portfolio.json must exist)
  • For full lineage tracking: a source-registry.json (created automatically by portfolio-ingest or via the status mode of this skill)

Workflow Modes

Detect the user's intent and route to the appropriate mode. If ambiguous, start with Status to orient.

Mode 1: Status

Triggers: "lineage status", "source status", "show sources", "lineage overview"

  1. Find the active project (same discovery as portfolio-resume).
  2. Run the source-registry script:
    bash "${CLAUDE_PLUGIN_ROOT:-$(ls -td "$HOME"/.claude/plugins/cache/insight-wave/cogni-portfolio/*/ | head -1)}/scripts/source-registry.sh" "<project-dir>" status
    
  3. If no registry exists, offer to create one:
    • Run bash "${CLAUDE_PLUGIN_ROOT:-$(ls -td "$HOME"/.claude/plugins/cache/insight-wave/cogni-portfolio/*/ | head -1)}/scripts/source-registry.sh" "<project-dir>" init
    • Then scan for existing source_file fields on entities and offer to backfill registry entries from them
  4. Present a summary table:

Read the full file on GitHub · 210 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 First seen · 210 lines · 128 tokens per session scan A 34bc7f941dbb

Subscribe to this mod's changes

portfolio-lineage is a skill published in the GitHub repository cogni-work/insight-wave (13 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 128 tokens to every session and 2,689 once invoked, about $0.0005 per session on Opus 5.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-09-04.