Back to Prompt Library
implementation

Implement Agentic Reasoning and Anomaly Detection

Inspect the original prompt language first, then copy or adapt it once you know how it fits your workflow.

Linked challenge: Real-time Crypto Fraud Alert Agent with Claude Agents SDK

Format
Code-aware
Lines
6
Sections
2
Linked challenge
Real-time Crypto Fraud Alert Agent with Claude Agents SDK

Prompt source

Original prompt text with formatting preserved for inspection.

6 lines
2 sections
No variables
4 checklist items
Enhance your Claude agent to perform multi-step reasoning. The agent should:
1.  Monitor a stream of incoming simulated transactions.
2.  For any large, outgoing transaction, use `get_transaction_details` to fetch more information.
3.  If the transaction involves a privacy coin (like XMR) or a known mixer address, or follows a large loss of other assets, use `search_crypto_news` to check for related scam reports.
4.  If a potential fraud pattern is detected, generate a detailed alert using a helper function `trigger_alert(alert_details: dict)`.

Demonstrate how the Claude agent uses its internal reasoning to decide when to call which tool and how to synthesize information for an alert. Include your Python `Agent` initialization and a simple `run` call with simulated input.

Adaptation plan

Keep the source stable, then change the prompt in a predictable order so the next run is easier to evaluate.

Keep stable

Hold the task contract and output shape stable so generated implementations remain comparable.

Tune next

Update libraries, interfaces, and environment assumptions to match the stack you actually run.

Verify after

Test failure handling, edge cases, and any code paths that depend on hidden context or secrets.