precise: Skill for Claude Code

.claude/skills/estimate-online-covariance/SKILL.md

estimate-online-covariance is a skill for Claude Code from microprediction/precise. It costs 58 tokens per session (526 once invoked), scanned A, original, MIT.

A method for updating a covariance, correlation, or precision matrix one observation at a time. Unlike batch-only methods, it can work with streaming data as new observations arrive.

In plain words
What is it for?
Use it for online statistics, streaming analysis, or incremental machine-learning pipelines.
Why use it?
It avoids waiting to collect the entire dataset and can replace batch covariance tools when data is continuously received.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

This is microprediction/precise's own configuration. It tells Claude Code how to work on precise itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything precise configures →

Reuse

Borrowing it

Nothing to install: this file belongs to microprediction/precise. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/microprediction/precise/main/.claude/skills/estimate-online-covariance/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/microprediction/precise

Made for: Claude Code.

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 estimate-online-covariance

README.md
[![agentmods](https://agentmods.dev/badge/skills/microprediction/precise/estimate-online-covariance/github.svg)](https://agentmods.dev/skills/microprediction/precise/estimate-online-covariance)
Your own site
<a href="https://agentmods.dev/skills/microprediction/precise/estimate-online-covariance"><img src="https://agentmods.dev/badge/skills/microprediction/precise/estimate-online-covariance/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 estimate-online-covariance

Your own site · 80×15
<a href="https://agentmods.dev/skills/microprediction/precise/estimate-online-covariance"><img src="https://agentmods.dev/badge/skills/microprediction/precise/estimate-online-covariance.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 58 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 526 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.00058 $0.00526
Opus 5.5 $0.00023 $0.00210
Sonnet 5.5 $0.00012 $0.00105
Haiku 4.5 $0.00006 $0.00053

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

Security

Grade A, and why

estimate-online-covariance 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 2mo 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.

.claude/skills/estimate-online-covariance/SKILL.md · 51 lines

What it actually says

Estimate online covariance with precise

precise provides sklearn-style estimators with a single partial_fit contract. Pure numpy.

pip install precise

The pattern

import numpy as np
from precise import EwaCovariance        # exponentially weighted; recency-biased

est = EwaCovariance(r=0.05)              # r in (0,1]; larger = faster forgetting
for y in stream:                         # y is a 1-D array (one observation)
    est.partial_fit(y)

est.covariance_     # (d, d) ndarray, symmetric and PSD by construction
est.correlation_    # unit-diagonal correlation
est.precision_      # inverse covariance (when well-conditioned)
est.location_       # running mean
est.n_samples_      # observations seen

fit(X) is the batch drop-in (X is 2-D, rows = observations); it resets then replays rows, so it matches sklearn.covariance's call shape.

Choosing the class

all_estimators() lists every estimator; estimator_from_name("LedoitWolfCovariance") looks one up. Sensible defaults by situation:

  • general / recency-weighted: EwaCovariance(r=...)
  • many variables relative to samples (p/n large) or ill-conditioned: LedoitWolfCovariance, OASCovariance, ShrunkCovariance, FactorCovariance
  • heavy tails / outliers: HuberCovariance, TylerCovariance
  • regime changes: AdaptiveEwaCovariance, DCCCovariance
  • you don't know: use the choose-covariance-estimator skill (suggest(X)).

Notes

  • All estimators are truly online — constant work per observation, no growing buffers.
  • State is a JSON-able dict: est.get_state() / est.set_state(s) for mid-stream checkpointing.
  • covariance_ is always symmetric PSD; don't hand-symmetrize or clip it yourself.
  • Named series with a changing universe? Use the keyed-dynamic-universe skill instead.
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. 2mo ago First seen · 51 lines · 58 tokens per session scan A c6407101865f

Subscribe to this mod's changes

estimate-online-covariance is a skill published in the GitHub repository microprediction/precise (338 stars, last pushed 5d ago), licensed MIT. It adds 58 tokens to every session and 526 once invoked, about $0.0002 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-01.

Related

estimate-online-covariance compared with skills from other repositories

estimate-online-covariance next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
estimate-online-covariancemicroprediction/preciseSkill3385d agoMITA58Claude Code
arboretoK-Dense-AI/scientific-agent-skillsSkill56k4d agoMITA55Claude Code, Codex
deepspot-mK-Dense-AI/scientific-agent-skillsSkill56k4d agoMITA70Claude Code
torchdrugK-Dense-AI/scientific-agent-skillsSkill56k4d agoMITA64Claude Code
pyhealthK-Dense-AI/scientific-agent-skillsSkill56k4d agoMITA84Claude Code, Codex
nemo-mbridge-perf-expert-parallel-overlapNVIDIA/skillsSkill3.9kyesterdayApache-2.0A56Claude Code
ml-training-recipesOrchestra-Research/AI-Research-SKILLsSkill14k26d agoMITA88Claude Code