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 cwinvestments/memstack --skill shardgit clone --depth 1 https://github.com/cwinvestments/memstackWrote 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/cwinvestments/memstack/shard)<a href="https://agentmods.dev/skills/cwinvestments/memstack/shard"><img src="https://agentmods.dev/badge/skills/cwinvestments/memstack/shard.svg" alt="Measured on agentmods" 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.00028 | $0.00687 |
| Opus 5 | $0.00014 | $0.00344 |
| Sonnet 5 | $0.00006 | $0.00137 |
| Haiku 4.5 | $0.00003 | $0.00069 |
Grade A, and why
shard 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 3d 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 — 92 lines — stays where its author put it; the contents beside it link to each section on GitHub.
💎 Shard: Refactoring Large File...
Split monolithic files into focused, maintainable modules.
Activation
When this skill activates, output:
💎 Shard: Refactoring large file...
Then execute the protocol below.
Context Guard
| Context | Status |
|---|---|
| User says "shard", "split file", or "refactor" | ACTIVE: full protocol |
| Editing a file over 1000 lines | ACTIVE: suggest refactor |
| User says "refactor" for logic changes (not splitting) | DORMANT: not a shard task |
| Discussing code organization concepts | DORMANT: do not activate |
| File is under 500 lines | DORMANT: not worth splitting |
Protocol
-
Identify the target file and count lines:
wc -l <file> -
Analyze structure:
- List all exports (functions, components, types, constants)
- Identify logical groupings
- Map internal dependencies (what calls what)
-
Propose the split: present to user BEFORE executing:
- Target: 100-300 lines per new file
- Group related functionality
- Keep types near consumers
- Shared utilities in separate file
-
Execute the refactor:
- Create new files with proper names
- Move code to appropriate files
- Add import/export statements
- Create index.ts barrel if needed for backwards compatibility
- Update all imports throughout the project
-
Verify build:
npm run build 2>&1 | tail -20 -
Present result: new file structure with line counts
Inputs
- File path to refactor
- Optional: preferred split strategy or target file count
Outputs
- Multiple smaller files replacing the original
- Updated imports throughout project
- Build verification
Example Usage
User: "shard infrastructure/page.tsx: it's 1100 lines"
💎 Shard: Refactoring large file...
infrastructure/page.tsx (1,110 lines) → 6 files:
page.tsx (~120 lines), Main page, tab switcher
RailwayTab.tsx (~200 lines), Railway monitoring
HetznerTab.tsx (~180 lines), Hetzner monitoring
HeadroomTab.tsx (~250 lines), Headroom + setup guide
types.ts (~80 lines), Shared interfaces
constants.ts (~60 lines): Status configs
Build check: ✓ passed
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.
- 3d ago Changed c8eadd7a09fd
- 3d ago First seen · 92 lines · 28 tokens per session scan A 9a191784d328
shard is a skill published in the GitHub repository cwinvestments/memstack (419 stars, last pushed today), licensed MIT. It adds 28 tokens to every session and 687 once invoked, about $0.0001 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-09-03.
Other skills, from other repositories
atomic-review
Compressed code review comments. Cuts noise from PR feedback while preserving the actionable signal. Each comment is one line: location, problem, fix. Use when user says "review this PR", "code review", "review the diff", or invokes /atomic-review. Auto-triggers when reviewing pull requests.
react-senior-code-review
Senior-level review of a React feature, by theSeniorDev — structure & boundaries, state & data flow, performance & rendering, types/forms/testability/a11y, and styling architecture & motion. Recommends design patterns by name when one fits. Produces prioritized findings (Critical → Nit) with file:line, why, and a…
stack-changes
Splits a large change into small, single-purpose units of review — PRs, diffs, or CLs — each making one argument (one diff, one thesis) and each buildable and testable on its own. Use when a change is too big to review, when a feature builds on existing code, when working in a large monorepo with stacked diffs, or…
code-review
Reviews code following team development standards. Use when reviewing code, checking PRs, or before merging.
sdd-tasks
Break an SDD change into implementation tasks. Trigger: orchestrator launches task planning for a change.
pre-landing-review
Pre-landing PR review. Analyzes diff against the base branch for SQL safety, LLM trust boundary violations, conditional side effects, and other structural issues. Use when explicitly asked for the specialized pre-landing workflow. Product /review requests are handled by OpenBitFun's unified Review mechanism instead.…