okf-frontmatter

okf-frontmatter is a skill for Claude Code, Codex from longsizhuo/openInvest. It costs 243 tokens per session (1,635 once invoked), scanned A, original, MIT.

A documentation method that puts a small YAML information block at the top of each Open Knowledge Format (OKF) document. The block records facts such as the document type, title, tags, purpose, and links to source code.

In plain words
What is it for?
Use it to maintain Markdown chapters and architecture decision records, link documentation to code schemas, find documents, and run consistency checks.
Why use it?
It keeps structured facts in one place and avoids copying code schemas into prose that can become outdated. The accompanying tools help find and check documents.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to maintain Markdown chapters and architecture decision records, link documentation to code schemas, find documents, and run consistency checks.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/longsizhuo/openinvest/okf-frontmatter
Install

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.

Any agent
npx skills add longsizhuo/openInvest --skill okf-frontmatter
Clone the repo
git clone --depth 1 https://github.com/longsizhuo/openInvest

Made for: Claude Code, Codex.

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 okf-frontmatter

README.md
[![agentmods](https://agentmods.dev/badge/skills/longsizhuo/openinvest/okf-frontmatter/github.svg)](https://agentmods.dev/skills/longsizhuo/openinvest/okf-frontmatter)
Your own site
<a href="https://agentmods.dev/skills/longsizhuo/openinvest/okf-frontmatter"><img src="https://agentmods.dev/badge/skills/longsizhuo/openinvest/okf-frontmatter/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 okf-frontmatter

Your own site · 80×15
<a href="https://agentmods.dev/skills/longsizhuo/openinvest/okf-frontmatter"><img src="https://agentmods.dev/badge/skills/longsizhuo/openinvest/okf-frontmatter.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 243 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,635 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00243 $0.01635
Opus 5 $0.00121 $0.00817
Sonnet 5 $0.00049 $0.00327
Haiku 4.5 $0.00024 $0.00163

Measured 12d ago against content hash 76110e4ade53, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

okf-frontmatter 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 12d ago.

The scan reads SKILL.md. This mod also ships 2 executable files (scripts/find_docs.py, scripts/run.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

skills/okf-frontmatter/SKILL.md · 119 lines

How it starts

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

okf-frontmatter

OpenInvest's docs live in docs/wiki/ (numbered chapters) and docs/wiki/adr/ (decision records). Under OKF each doc starts with a YAML frontmatter block that is the single source of truth about that doc. Tooling reads the frontmatter; humans read the prose. The goal: stop maintaining huge prose docs that duplicate what the code already says — link to the code instead, and let find_docs.py do navigation.

Point the script at a repo with --repo <path>, or just run it from inside that repo (it auto-detects the nearest ancestor containing docs/wiki/, else uses the working dir). It is read-only except for docs you explicitly edit. The conventions below use openInvest as the worked example, but the mechanics (find / schema / lint) work on any repo whose markdown carries OKF frontmatter.


Job 1 — maintain docs the OKF way

The rule of thumb: frontmatter is structured truth; prose is explanation. Anything that is a schema (a Pydantic model, a dataclass, a config key, an endpoint contract) lives in code — the doc points to it via schema_source / documents, it does not re-type it. When the code changes, lint tells you which doc's pointer went stale. Don't grow a doc past a few screens of "why / how it fits together"; if you're copying field tables out of code, stop and add a schema_source pointer instead.

Frontmatter schema

Common to every doc:

field required meaning
type wiki-chapter | adr | index | reference | report | readme
title rec. human title (usually the H1)
tags opt. [api, rest, ...] — coarse categories
intent opt. one short phrase the lookup ranks on, e.g. API Contract, 决策参数, 部署
schema_source opt. list of relpath:Symbol pointers to the authoritative code, e.g. connectors/web_api/models.py:PortfolioResponse
documents opt. {endpoints: [GET /api/x], config_keys: [a.b], symbols: [Foo]} — concrete things this doc covers

Read the full file on GitHub · 119 lines

Files

What ships with it

7 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 12d ago First seen · 119 lines · 243 tokens per session scan A 76110e4ade53

Subscribe to this mod's changes

okf-frontmatter is a skill published in the GitHub repository longsizhuo/openInvest (83 stars, last pushed today), licensed MIT. It adds 243 tokens to every session and 1,635 once invoked, about $0.0012 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-30.

Related

Other skills, from other repositories

paper-translation

Use when translating academic papers (PDF to Chinese Markdown), extracting PDFs with MinerU API, or needing to preserve LaTeX formulas/images/tables through a translation workflow.

APLaS-Plus/paper-translation · 37 tokens

morph-ppt

Use this skill when the user wants a .pptx with smooth cross-slide animation — PowerPoint Morph transitions, Keynote-style continuous motion, shapes that grow / move / rotate as the slide advances. Trigger on: 'morph', 'morph transition', 'smooth transition', 'continuous animation across slides', 'Keynote-style…

iOfficeAI/OfficeCLI · 169 tokens

officecli-financial-model

Use this skill when the user wants to build a financial model — 3-statement model, DCF valuation, LBO, SaaS unit economics, sensitivity / scenario analysis, debt schedule, or fundraising projections — in Excel. Trigger on: 'financial model', '3-statement model', 'P&L + BS + CF', 'DCF', 'WACC', 'NPV', 'terminal value'…

iOfficeAI/OfficeCLI · 222 tokens

officecli-word-form

Use this skill to create fillable Word forms (.docx) with real Content Controls (SDT) + legacy FormField checkboxes + MERGEFIELD mail-merge placeholders + document protection. Trigger on: 'fillable form', 'form fields', 'content controls', 'SDT', 'word form', 'fill in', 'only editable fields', 'protect document'…

iOfficeAI/OfficeCLI · 224 tokens

officecli-academic-paper

Use this skill to build academic-style .docx output: journal / conference / thesis chapters carrying formal citation style (APA, Chicago, IEEE, MLA), numbered equations, figure & table cross-references, footnotes/endnotes, bibliography, or multi-column journal layout. Trigger on: 'research paper', 'journal paper'…

iOfficeAI/OfficeCLI · 141 tokens

officecli-docx

Use this skill any time a .docx file is involved -- as input, output, or both. This includes: creating Word documents, reports, letters, memos, or proposals; reading, parsing, or extracting text from any .docx file; editing, modifying, or updating existing documents; working with templates, tracked changes, comments…

iOfficeAI/OfficeCLI · 114 tokens