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 agentmods add skills/techygarg/lattice/knowledge-priming-refinernpx skills add techygarg/lattice --skill knowledge-priming-refinergit clone --depth 1 https://github.com/techygarg/latticeWrote 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/techygarg/lattice/knowledge-priming-refiner)<a href="https://agentmods.dev/skills/techygarg/lattice/knowledge-priming-refiner"><img src="https://agentmods.dev/badge/skills/techygarg/lattice/knowledge-priming-refiner.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.00084 | $0.01672 |
| Opus 5 | $0.00042 | $0.00836 |
| Sonnet 5 | $0.00017 | $0.00334 |
| Haiku 4.5 | $0.00008 | $0.00167 |
Grade A, and why
knowledge-priming-refiner 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 6d 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 — 118 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Knowledge Priming Refiner
Purpose
This refiner facilitates a structured conversation to create a project-specific knowledge base document. The document captures the project's identity -- its tech stack, architecture, directory layout, and the trusted sources that shaped how the team works. Think of it as answering one question: "What does AI need to know about this project to avoid defaulting to generic internet patterns?"
This is not about how to write good code -- that is handled by the clean-code atom (coding principles), architecture atom (structural rules), and domain-driven-design atom (domain modeling). Knowledge priming covers what those skills cannot know: which framework, which version, which docs to trust, and how the repo is organized.
What This Produces
- Output:
.lattice/standards/knowledge-base.md(or custom path from.lattice/config.yaml->paths.knowledge_base) - Mode: Override is the standard approach -- every project's knowledge base is unique, so there are no generic defaults to overlay on. Overlay mode is available for selective revisions of an existing document.
- Config key:
paths.knowledge_basein.lattice/config.yaml - Template: Read
./assets/template.mdfor the full document structure and interview guidance comments - Consumed by: The
knowledge-primingatom loads this document via config resolution and provides it as ambient project context to all skills and molecules
Scope Boundary
Knowledge priming captures project identity and technical context. It deliberately excludes concerns covered by other skills:
| Concern | Where It Belongs | Not In Knowledge Priming |
|---|---|---|
| Language idioms (error handling, type system, naming, testing patterns, DI) | language-idioms document |
No language-level patterns or idioms |
| Coding style, naming principles, function design | clean-code atom |
No code examples, no naming rules |
| Architectural layers, dependency direction | architecture atom |
No structural rules |
| Domain modeling, aggregate design | domain-driven-design atom |
No DDD patterns |
| Code-level anti-patterns (god functions, deep nesting) | clean-code atom |
No coding anti-patterns |
What ships with it
1 file 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.
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.
- 6d ago First seen · 118 lines · 84 tokens per session scan A 75d2ef848df6
knowledge-priming-refiner is a skill published in the GitHub repository techygarg/lattice (185 stars, last pushed yesterday), licensed MIT. It adds 84 tokens to every session and 1,672 once invoked, about $0.0004 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.
Other skills, from other repositories
learn-from-fix
Capture Elixir/Ecto/LiveView lessons and Hex API rules. Use after corrections or when asked to document learning, record a lesson, prevent a fixed mistake, or remember package guidance with --library.
compound
Capture solved problems as searchable solution docs. Use after fixing bugs, when "that worked", or after successful /phx:review or /phx:investigate.
recall
Recall prior work from past sessions — how a bug was fixed, what was decided, where a pattern lives. Use when asked 'have we done this before' or 'how did I fix X' in Elixir/Phoenix work. ccrider MCP when available, else git + solution docs.
assigns-audit
Inspect LiveView socket assigns for memory bloat — missing temporaryassigns, unused assigns, unbounded lists needing streams, memory estimates. Use when LiveView memory grows or you need to add temporaryassigns.
compound-docs
Searchable Elixir/Phoenix/Ecto solution documentation system with YAML frontmatter. Builds institutional knowledge from solved problems. Use when consulting past solutions before investigating new issues.
name-your-business
Generate, refine, compare, and when needed validate distinctive names for startups, AI products, developer tools, protocols, open-source projects, apps, product families, local businesses, services, companies, nonprofits, and other organizations. Use when asked to name or rename a business, brand, product, venture…