Monday, May 18, 2026

Instruction-Based Data Analysis with Sparrow and Local LLM

In this video, I show how to use Sparrow instruction processing pipeline to analyze a bond portfolio JSON extracted from a financial document — all running locally, no external APIs.

I run three different analysis cases using Gemma 4 31B on Apple Silicon Mac Mini M4 Pro:

  • Risk classification — categorize each position into low, medium, or high risk based on loss percentage
  • Concentration risk — flag overweight positions above 20% portfolio weighting
  • Portfolio aggregation — total valuation, weighted average P&L, best and worst performer

All three cases use the same sparrow-instructor pipeline, demonstrating how different instruction types — classification, rule-based flagging, and aggregation — are handled by a single local LLM.

No comments: