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.
git clone --depth 1 https://github.com/peerjakobsen/smartspenderWrote 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/commands/peerjakobsen/smartspender/receipt-learn)<a href="https://agentmods.dev/commands/peerjakobsen/smartspender/receipt-learn"><img src="https://agentmods.dev/badge/commands/peerjakobsen/smartspender/receipt-learn/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.
<a href="https://agentmods.dev/commands/peerjakobsen/smartspender/receipt-learn"><img src="https://agentmods.dev/badge/commands/peerjakobsen/smartspender/receipt-learn.svg" alt="Reviewed on agentmods" width="80" 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.00012 | $0.01215 |
| Opus 5.5 | $0.00005 | $0.00486 |
| Sonnet 5.5 | $0.00002 | $0.00243 |
| Haiku 4.5 | $0.00001 | $0.00121 |
Grade A, and why
receipt-learn 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 3mo 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 — 119 lines — stays where its author put it; the contents beside it link to each section on GitHub.
/smartspender:receipt learn
Trigger
/smartspender:receipt learn- "Gem udtraeksregler"
- "Laer denne faktura"
Arguments
| Argument | Required | Values | Default |
|---|---|---|---|
| action | yes | learn | - |
Prerequisites
- A receipt or invoice has been processed in the current conversation
- User has verified and/or corrected the extraction results
- The processed receipt was a PDF invoice (not a grocery receipt or card slip)
Workflow
- Check if the current conversation contains a receipt/invoice processing session with extraction results. If not, respond: "Jeg kan ikke finde en behandlet faktura i denne samtale. Behandl venligst en faktura med /smartspender:receipt upload foerst."
- Identify the vendor from the conversation context:
- Use the extracted merchant name from the receipt processing
- Normalize to vendor-id (lowercase, no spaces, no A/S suffix)
- Analyze the conversation for corrections the user made:
- Changed merchant name
- Changed date or billing period
- Changed total amount
- Changed line item names, categories, or subcategories
- Added missing line items
- Removed incorrect line items
- Changed extraction approach (e.g., "the total is on page 2, not page 1")
- Summarize the learned rules and present to user for confirmation:
Jeg har identificeret foelgende regler for {Vendor Name} fakturaer: Leverandoer: {vendor name} (ID: {vendor-id}) Fakturetype: {type, e.g., Telecom, Forsyning} Udtraeksregler: - {rule 1, e.g., "Fakturadato findes efter 'Dato:' paa side 1"} - {rule 2, e.g., "Total findes efter 'I alt inkl. moms'"} - {rule 3, e.g., "Linjer kategoriseres som Abonnementer > Mobilabonnement"} Rettelser fra denne session: - {correction 1, e.g., "'Ekstra data' skal vaere Mobilabonnement, ikke Internet"} Skal jeg gemme disse regler? (ja/nej) - [USER ACTION]: User confirms or provides additional corrections
- If user says no: respond "Reglerne blev ikke gemt." and stop.
- Check if
invoice-knowledge/{vendor-id}/PARSER.mdalready exists:- EXISTS: Update the existing file:
- Add new entries to the Learned Corrections table with today's date
- Update extraction rules if the user's corrections change the approach
- Update Last Updated date
- DOES NOT EXIST: Create a new parser:
- Create directory
invoice-knowledge/{vendor-id}/ - Copy structure from
invoice-knowledge/_template.md - Fill in Vendor Info from conversation context
- Fill in Extraction Rules from the processed invoice structure
- Fill in Line Items from the extracted (and corrected) items
- Add any corrections to the Learned Corrections table
- Set Last Updated to today
- Create directory
- EXISTS: Update the existing file:
- Write the file to
invoice-knowledge/{vendor-id}/PARSER.md - Output confirmation:
Regler for {Vendor Name} er gemt i invoice-knowledge/{vendor-id}/PARSER.md. {If new}: Ny leverandoer-parser oprettet med {n} udtraeksregler. {If updated}: Eksisterende parser opdateret med {n} nye rettelser. Naeste gang du behandler en faktura fra {Vendor Name}, vil disse regler automatisk blive brugt til mere praecis udtraekning.
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.
- 3mo ago First seen · 119 lines · 12 tokens per session scan A dac97f75d5f3
receipt-learn is a command published in the GitHub repository peerjakobsen/smartspender (5 stars, last pushed 10mo ago), licensed MIT. It adds 12 tokens to every session and 1,215 once invoked, about $0.0000 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-08-31.
receipt-learn compared with commands from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| receipt-learnpeerjakobsen/smartspender | Command | 5 | 10mo ago | MIT | A | 12 | Claude Code |
| researchquant-sentiment-ai/claude-equity-research | Command | 773 | yesterday | MIT | A | 0 | Claude Code |
| better-auth:add-pluginsecondsky/claude-skills | Command | 257 | 2d ago | MIT | A | 25 | Claude Code |
| better-auth:setupsecondsky/claude-skills | Command | 257 | 2d ago | MIT | A | 26 | Claude Code |
| cloudflare-r2:presigned-urlsecondsky/claude-skills | Command | 257 | 2d ago | MIT | A | 20 | Claude Code |
| bun:migratesecondsky/claude-skills | Command | 257 | 2d ago | MIT | A | 13 | Claude Code |
| delegate-my-work:delegatesecondsky/claude-skills | Command | 257 | 2d ago | MIT | A | 25 | Claude Code |