It's tax time, which means a folder full of W-2s, 1099s, and IRS publications I'd rather not grep through manually. So I whipped up a tax doc assistant with our new Ragie skill — a CLI that answers questions from my actual tax documents with cited sources.
The stack:
- Claude Code for the coding
-
The Ragie skill for RAG patterns (install with
npx skills add ragieai/skills) - Ragie for document ingestion, retrieval, and metadata filtering
- Claude Sonnet 4.6 for answer generation
What the Ragie skill gives you: context on the SDK. Ingestion patterns, retrieval methods, metadata filtering, rerank config. When I asked Claude Code to ""write an ingestion script that tags PDFs with type and year,"" it produced correct code on the first try because the skill had already loaded the relevant SDK knowledge.
The key patterns
Metadata tagging at ingestion. Each document gets classified at upload:
- W-2s →
type: "w2" - 1099s →
type: "1099" - IRS pubs →
type: "irs-publication" - Receipts →
type: "receipt" - Plus
taxYear: 2025on all of them
Type-scoped retrieval. Questions about freelance income only search 1099s. Questions about deduction eligibility only search IRS publications. The metadata filter narrows the search space before hybrid search and rerank run, which is a big quality win over ""search everything.""
Rerank on. Small latency cost, noticeable quality improvement.
Citations in generation. Every answer references the source document name, so you can verify anything the assistant tells you.
Read the full walkthrough
All the code, prompts I used with Claude Code, and sample queries are in the original post on the Ragie blog:
Full source code: ragieai/examples/tax-assistant

Top comments (0)