You are prompt engineering a Claude-based system that extracts specific entities (dates, monetary amounts, party names) from legal contracts. Initial testing shows high precision but low recall — Claude reliably extracts entities it finds but consistently misses certain patterns (e.g., amounts written as words: 'fifty thousand dollars'). What is the most targeted remediation?
Select an answer to reveal the explanation.
Short Explanation
Here's the deal — you've got a precision/recall problem, not a capacity problem. Add targeted few-shot examples that show word-form amounts, plus a taxonomy of amount formats, so Claude learns the exact pattern it's missing.
Full Explanation
The correct remediation is the targeted few-shot example and taxonomy approach, because the precision/recall analysis pinpoints the exact failure mode: Claude recognizes numerically formatted amounts but misses word-form amounts. Few-shot examples specifically demonstrating this pattern, plus a comprehensive taxonomy of representation formats, directly address the gap in Claude's behavior for this task. This is targeted prompt engineering that fixes the specific failure case. The approach of increasing max_tokens to give Claude more output capacity is wrong because the problem is pattern recognition failure, not output truncation; max_tokens controls output length, and the symptom—consistent misses of a pattern type—is not consistent with truncation. The approach of switching to a higher-capability model is wrong because the failure is not a capability ceiling—it is a prompt coverage gap. Claude is capable of recognizing word-form amounts when properly prompted; switching models wastes cost without addressing the root cause. The approach of lowering temperature to 0.0 to make extractions more deterministic is wrong because temperature 0.0 increases determinism but does not improve recall for patterns the model has not been shown; the model will deterministically miss the same patterns it currently misses.