anomaly-fraud-scanner
Installation
Review the source and dependencies with a prompt. A package is available to download.
Install with an AI assistant
Copy the prompt so your assistant can review the pinned revision and dependencies first.
View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "anomaly-fraud-scanner" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-de840875e225c05b7e76727800c874b2de2bde74ae9739b974cc25244fd7101d. Verify the upstream source and version against https://github.com/lyndonkl/claude before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.
Source and setup
github.com
Setup guidance pending
See the original source for supported tools, dependencies, and permissions.
Installation test pending
Scan transactions for fraud and anomaly signals—e.g., duplicate charges within 48 hours, transaction amounts exceeding the merchant's historical mean by three standard deviations, first-time transactions with a merchant above a high-value threshold, and anomalous geographic location or time. Produce alerts with severity labels including transaction ID, evidence, and recommended actions (call bank, freeze card, dispute, monitor). Used for per-transaction vigilance scans, after unexplained large outflows, or when users mention fraud checks, suspicious charges, anomaly detection, or duplicate charges.
Introduction source: third_party · lyndonkl · 0.0.1 Reference
SkillPi interpretation
- Tasks
- Scans transactions for fraud and anomaly signals — duplicate charges within 48 hours, transactions more than 3 standard deviations above a merchant's historical average, first-ever transaction with a new merchant above a high-dollar threshold, and unusual geography or time. Produces severity-tagged alerts with the transaction id, evidence, and a recommended action (call bank, freeze card, dispute, monitor). Use for vigilance scans on every drop, after any large unexplained outflow, or when user mentions fraud check, suspicious charge, anomaly detection, or duplicate charge.
- Inputs and outputs
- The caller provides: `transactions_new` — transactions added by the most recent drop. `transactions_history` — last 12 months of confirmed transactions. `accounts` — for context (account type, owner, geography). `today` — ISO date. `thresholds` — optional overrides:
- Testing
- Not tested
Browse files
Frontmatter
name: anomaly-fraud-scanner
description: Scans transactions for fraud and anomaly signals — duplicate charges within 48 hours, transactions more than 3 standard deviations above a merchant's historical average, first-ever transaction with a new merchant above a high-dollar threshold, and unusual geography or time. Produces severity-tagged alerts with the transaction id, evidence, and a recommended action (call bank, freeze card, dispute, monitor). Use for vigilance scans on every drop, after any large unexplained outflow, or when user mentions fraud check, suspicious charge, anomaly detection, or duplicate charge.Anomaly Fraud Scanner
Table of Contents
Overview
Fraud detection on a household budget is a different problem from fraud detection at a bank. The bank already runs sophisticated rules; this skill exists to catch what the bank misses — small recurring fraud below their threshold, unfamiliar merchant patterns, and post-hoc audit of charges the user has not yet noticed.
It runs five complementary detectors, each producing severity-tagged alerts.
Input contract
The caller provides:
transactions_new— transactions added by the most recent drop.transactions_history— last 12 months of confirmed transactions.accounts— for context (account type, owner, geography).today— ISO date.thresholds— optional overrides:{ "duplicate_window_hours": 48, "anomaly_sigma": 3.0, "first_merchant_high_dollar_cents": 50000, "geo_radius_miles": 1000 }
Detection rules
Rule 1 — Duplicate within 48 hours
Two transactions on the same account_id with the same merchant and the same amount_cents posted within duplicate_window_hours of each other.
- Severity:
mediumfor amounts < $200,highfor amounts ≥ $200. - Common false positives: two coffees in a day, two gas-station fill-ups during a road trip — exclude
food.coffee,food.restaurants,transportation.gasfrom this rule when amount is below $30.
Rule 2 — Statistical anomaly
For each (merchant, account_id) pair with ≥ 6 historical occurrences, compute mean and stddev. Flag any new transaction where |amount − mean| > anomaly_sigma × stddev AND |amount − mean| ≥ $50.
- Severity:
mediumbaseline,highif> 5σor amount > 4× mean. - Common false positives: tip variations on restaurants, surge pricing on rideshare — bake a 25% leniency on
food.restaurantsandtransportation.rideshare.
Rule 3 — First merchant high dollar
A transaction with a merchant that has zero prior occurrences in transactions_history AND |amount| ≥ first_merchant_high_dollar_cents.
- Severity:
mediumfor $500–$2,000,highfor ≥ $2,000. - Common false positives: a planned major purchase (appliance, travel booking). Suppress when a recent
category_overrideor user-confirmed plan exists.
Rule 4 — Geography or time anomaly
If description_raw includes a location string (state code, country code) and the inferred location differs by more than geo_radius_miles from the household's home location AND no travel context is set, flag.
If a transaction posts at an unusual time (between 2am–5am local) AND the merchant category is unusual for that hour (not gas station, not 24-hour pharmacy), flag.
- Severity:
medium. - This rule is noisy — use only when a location/time signal is clearly present.
Rule 5 — Unexpected fee
Any transaction with category: financial.fees is captured. Tag with fee_type (overdraft, foreign-transaction, monthly-maintenance, ATM, late-payment).
- Severity:
lowfor fees < $10,mediumfor fees $10–$50,highfor overdraft fees and late-payment fees regardless of amount. - Always actionable: most fees are negotiable or avoidable.
Workflow
Anomaly Scan Progress:
- [ ] Step 1: Build merchant statistics from transactions_history
- [ ] Step 2: Run Rule 1 (duplicate within 48h)
- [ ] Step 3: Run Rule 2 (statistical anomaly)
- [ ] Step 4: Run Rule 3 (first-merchant high-dollar)
- [ ] Step 5: Run Rule 4 (geography/time)
- [ ] Step 6: Run Rule 5 (fees)
- [ ] Step 7: Deduplicate alerts (one tx may trigger multiple rules)
- [ ] Step 8: Rank by severity then dollar impact
- [ ] Step 9: Attach recommended actions
Deduplication
A single transaction may legitimately trigger multiple rules (e.g., a $5,000 charge at a brand-new merchant in another state — Rules 3 and 4). Combine into a single alert with triggered_rules: [...] and the highest severity.
Recommended actions
Each alert carries one of:
call_bank_fraud_line— forhighseverity charges that the user does not recognize.freeze_card— for confirmed fraud or before calling the bank if multiple charges fired within hours.dispute_charge— for known-merchant overcharges or duplicate post-and-pending issues.negotiate_fee— forfinancial.fees(overdraft, monthly maintenance) that have a known negotiation playbook.monitor— formedium/lowalerts where the user should confirm but no action is required if it's legitimate.
Always include a one-line evidence describing what triggered the rule, with concrete numbers.
Output contract
{
"scanned": {
"transactions_new": 142,
"transactions_history": 1820,
"merchants_with_stats": 218
},
"alerts": [
{
"id": "alert_20260424_001",
"severity": "high",
"triggered_rules": ["first_merchant_high_dollar"],
"tx_ids": ["tx_20260424_011"],
"merchant": "TECH-SHOP-ONLINE",
"amount_cents": -245000,
"account_id": "acc_cc_001",
"evidence": "First charge ever from TECH-SHOP-ONLINE; amount $2,450 exceeds new-merchant high-dollar threshold of $500.",
"suggested_action": "call_bank_fraud_line",
"expected_user_response": "Confirm whether this purchase is yours; if not, freeze card and dispute."
},
{
"id": "alert_20260424_002",
"severity": "medium",
"triggered_rules": ["statistical_anomaly"],
"tx_ids": ["tx_20260424_023"],
"merchant": "Whole Foods",
"amount_cents": -38420,
"evidence": "12-month avg $84.50, stddev $22.30; this charge ($384.20) is 13.4σ above mean.",
"suggested_action": "monitor",
"expected_user_response": "If you bought groceries for a party, ignore. Otherwise, check the receipt."
},
{
"id": "alert_20260424_003",
"severity": "high",
"triggered_rules": ["fee_overdraft"],
"tx_ids": ["tx_20260423_004"],
"merchant": "Bank Name",
"amount_cents": -3500,
"evidence": "Overdraft fee of $35 charged on 2026-04-23. Account balance was negative for 2 days.",
"suggested_action": "negotiate_fee",
"expected_user_response": "Call the bank's customer line; first overdraft fees are typically waived on request."
}
],
"summary": {
"alerts_total": 3,
"high_severity": 2,
"medium_severity": 1,
"low_severity": 0
}
}
Guardrails
- Never assert fraud. Use language like "unusual," "first-ever," "above threshold." The user confirms; this skill flags.
- Tune for false-positive cost. A medium-severity alert is read; a high-severity alert disrupts the user's day. Reserve
highfor truly unusual. - Cite the math. Every alert states the comparator (mean, stddev, occurrence count, threshold). The user must be able to evaluate the reasoning.
- Honor history-context. A "first-ever merchant" trigger should not fire when the merchant exists in history under a different rendered string. Use normalized merchant names from the categorizer.
- Do not action without consent. Suggested actions are for the user to take; the household-finance system never executes financial actions.
- Retain the alert log. All emitted alerts append to
reports/alerts/. False positives feed back into the threshold tuning.
Version history
-
0.1
GitHub ↗
Original release notes
## What's Changed * Improve writer skill navigation and structure by @lyndonkl in https://github.com/lyndonkl/claude/pull/1 * Consolidate stickiness content and reduce revision to 3 passes by @lyndonkl in https://github.com/lyndonkl/claude/pull/2 * Update README.md to reflect current writer skill structure by @lyndonkl in https://github.com/lyndonkl/claude/pull/3 * Add explicit instructions for AI agents to follow resource file workf… by @lyndonkl in https://github.com/lyndonkl/claude/pull/4 * Change analysis files from /tmp/ to project directory by @lyndonkl in https://github.com/lyndonkl/claude/pull/5 * Add five refined skills to production by @lyndonkl in https://github.com/lyndonkl/claude/pull/6 * Add causal-inference-root-cause skill and fix missing methodology files by @lyndonkl in https://github.com/lyndonkl/claude/pull/7 * Add workflow pattern to 6 completed skills by @lyndonkl in https://github.com/lyndonkl/claude/pull/8 * Add chain-estimation and roleplay-debate skills with optimizations by @lyndonkl in https://github.com/lyndonkl/claude/pull/9 * Add 3 new skills and update writer skill workflow pattern by @lyndonkl in https://github.com/lyndonkl/claude/pull/10 * Add skills #12-13: constraint-based-creativity and data-schema-knowle… by @lyndonkl in https://github.com/lyndonkl/claude/pull/11 * Add skills #14-16: decision-matrix, decomposition-reconstruction, deliberation-debate-red-teaming by @lyndonkl in https://github.com/lyndonkl/claude/pull/12 * Add skills #17-19: design-of-experiments, dialectical-mapping-steelmanning, discovery-interviews-surveys by @lyndonkl in https://github.com/lyndonkl/claude/pull/13 * Add chef-assistant skill and update README by @lyndonkl in https://github.com/lyndonkl/claude/pull/14 * Fix README: Remove links to gitignored scratchpad files by @lyndonkl in https://github.com/lyndonkl/claude/pull/15 * Add skills #14-22: 9 new production-ready skills by @lyndonkl in https://github.com/lyndonkl/claude/pull/16 * Add skills #20-24 and workflow pattern updates by @lyndonkl in https://github.com/lyndonkl/claude/pull/17 * Add skill #25: expected-value by @lyndonkl in https://github.com/lyndonkl/claude/pull/18 * Add skills #26-28: facilitation-patterns, financial-unit-economics, focus-timeboxing-8020 by @lyndonkl in https://github.com/lyndonkl/claude/pull/19 * Add skills #29-30: heuristics-and-checklists, hypotheticals-counterfactuals by @lyndonkl in https://github.com/lyndonkl/claude/pull/20 * Add skills #31-33: information-architecture, kill-criteria-exit-ramps, layered-reasoning by @lyndonkl in https://github.com/lyndonkl/claude/pull/21 * Add Claude Code plugin support by @lyndonkl in https://github.com/lyndonkl/claude/pull/22 * Fix plugin marketplace source path by @lyndonkl in https://github.com/lyndonkl/claude/pull/23 * Add skill #34: mapping-visualization-scaffolds by @lyndonkl in https://github.com/lyndonkl/claude/pull/24 * Skill refinement by @lyndonkl in https://github.com/lyndonkl/claude/pull/25 * Skill refinement by @lyndonkl in https://github.com/lyndonkl/claude/pull/26 * Skill refinement by @lyndonkl in https://github.com/lyndonkl/claude/pull/27 * Skill refinement by @lyndonkl in https://github.com/lyndonkl/claude/pull/28 * Skill refinement by @lyndonkl in https://github.com/lyndonkl/claude/pull/29 * Add skill #59: skill-extraction by @lyndonkl in https://github.com/lyndonkl/claude/pull/30 * Add skill-creator: Transform documents into actionable skills by @lyndonkl in https://github.com/lyndonkl/claude/pull/31 * Update skill count from 58 to 61 in README by @lyndonkl in https://github.com/lyndonkl/claude/pull/32 * Skill refinement by @lyndonkl in https://github.com/lyndonkl/claude/pull/33 * Add d3-visualization skill: comprehensive D3.js implementation guide by @lyndonkl in https://github.com/lyndonkl/claude/pull/34 * Add comprehensive Superforecasting Toolkit with 4 skills and orchestr… by @lyndonkl in https://github.com/lyndonkl/claude/pull/35 * Add "Run in Smithery" badge by @gurdasnijor in https://github.com/lyndonkl/claude/pull/36 * Add Scientific Writing Toolkit with 6 skills and orchestrating agent by @lyndonkl in https://github.com/lyndonkl/claude/pull/37 * Improve skill invocation rules and update README by @lyndonkl in https://github.com/lyndonkl/claude/pull/38 * Add Geometric Deep Learning skill suite and orchestrating agent by @lyndonkl in https://github.com/lyndonkl/claude/pull/39 * Decompose writer skill into 4 focused skills + orchestrating agent by @lyndonkl in https://github.com/lyndonkl/claude/pull/40 * Add GraphRAG skill suite with 5 skills + orchestrating agent by @lyndonkl in https://github.com/lyndonkl/claude/pull/41 * Decompose cognitive-design skill into 3 focused skills + orchestrating agent by @lyndonkl in https://github.com/lyndonkl/claude/pull/42 ## New Contributors * @lyndonkl made their first contribution in https://github.com/lyndonkl/claude/pull/1 * @gurdasnijor made their first contribution in https://github.com/lyndonkl/claude/pull/36 **Full Changelog**: https://github.com/lyndonkl/claude/commits/0.1
Current listing version
0.0.1
Safety and assessment details
Quality assessment
Out of 100 · Assessment report from SkillPi LAB.
Highlights
- 高价值/高频刚需,直接解决用户明确的核心任务痛点——个人交易欺诈与异常检测
- 显著提升日常高频场景的效率,具备广泛实用价值
Highlights
- 触发词精准完整,覆盖多种变体,边界清晰
- description 明确且位置正确
Highlights
- Phase/步骤清晰,有出口条件,含端到端示例
- frontmatter完整,单文件≤500行
Highlights
- 工具来源明确,参数正确,覆盖主要异常
- 不可逆操作有确认机制,可靠性良好
The arithmetic mean of the first four original scores, rounded to a whole number.
Static text checks
100 / 100 · skillpi-20261123-no-r3-v1
No current rules matched the text.
This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.
Permissions and checks before use
Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.
These common operations were not identified in the main document. This does not mean no permissions or risks exist.
Security rating and access scope
safe · Static evidence review; not a runtime safety guarantee.
Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.
User discussion
No verified reviews yet.