Portfolio

Data Engineering & Agentic AI

A lakehouse pipeline paired with a Claude agent that investigates royalty fraud across millions of streaming events, and a Neo4j graph that finds the bot farms behind it. The agent can propose withholding a payout, but it can never withhold one: every hold needs human approval, and the guardrails are enforced in code, not just requested in a prompt.
music man banner

Music Man – Agentic Royalty-Fraud Detection Lakehouse

PySpark • Delta Lake • MLflow • Neo4j • Claude Agent

See It In Action

metrics shot

The Graph Found the Real Bug

The model first appeared to score 67% precision, with “false positives” that looked like popular artists. A Neo4j graph proved otherwise: every one was the second day of a real bot attack that ran past midnight, and the data generator had labelled only the first day. With every attack day labelled, the model scores 100% precision and 100% recall. The model was right; the labels were wrong.

agent excerpt

Real Agent Reasoning, Not Scripted Output

Mid-investigation, the agent questioned its own evidence: “That uniformity could indicate a single coordinated operation across artists, or it could be an artifact of how the detector or the data is constructed.” It wasn’t told to check, and it was right: it had found a flaw in my data generator.

bots 1

A Bot Farm, Found by a Graph

50 accounts sharing 15 devices: a bot farm that per-artist statistics can’t see. Neo4j and Graph Data Science (connected components) find rings like this across 2.1M streaming events.

bots 2

One Ring, One Target

150 bot accounts, linked through 40 shared devices, all streaming the same artist on the same days. The agent’s find_fraud_ring tool shows this ring streamed 12 artists in total: one coordinated operator, not 12 separate incidents.

eval results

20 Graded Runs, Real Numbers

Five test scenarios, including a prompt injection hidden in an artist’s name and a popular artist built to look like fraud. Across 20 runs: 100% task completion, zero false holds, zero ungrounded rationales. Routing planning to a smaller model cut cost per run by 25%.

engine comparison

Hand-Written Loop vs. LangGraph

I rebuilt the agent in LangGraph and ran both versions through the same tests: 8 of 8 passes each, zero false holds, $0.072 vs. $0.074 per run. LangGraph adds pause-and-resume human review at no measured cost.

Core Capabilities

Millions of Events, Real Features

A bronze-to-gold PySpark and Delta Lake pipeline turns 2.1M streaming events into four bot-farm signals: burst velocity, device concentration, duration regularity, and geo-impossible travel.

Plans, Investigates, Reasons

A Claude agent plans its investigation, cross-checks raw signals instead of trusting a single anomaly score, and writes a rationale a human can actually evaluate before deciding.

Nothing Executes Automatically

The agent can only queue a hold. A human approves or rejects it in the review app, approved holds can be released later with a written reason, and every decision is logged.

Built to Fail Safely

Approvals that can’t apply twice, proposals that are safe to retry, a rollback path, dry-run mode, and an iteration budget, with the cost of every run recorded.

MCP, LangGraph & Webhooks

Every guardrail lives in one shared layer, used by an MCP server, a LangGraph agent with checkpointed human review, and a signed, idempotent webhook. No client can skip the rules.

Technology Stack

Music Man integrates lakehouse data engineering, machine learning, and agentic AI into one pipeline — built to run locally, portable to a real Databricks workspace.

Data Engineering

  • PySpark
  • Delta Lake
  • Pandas
  • PyArrow

Machine Learning

  • scikit-learn (Gradient Boosting)
  • MLflow

Agentic AI

  • Claude (Anthropic SDK)
  • Tool runner + structured outputs
  • Prompt caching
  • Model routing: Haiku → Opus
  • Pydantic
  • LangGraph (interrupt + checkpointing)
  • MCP server

MLOps & Architecture

  • Medallion architecture
  • Kaggle-seeded real data
  • Streamlit review UI
  • Docker + uv
  • pytest (41 tests)
  • FastAPI webhook (HMAC, idempotent)

Evaluation & Testing

  • LLM-as-judge (Sonnet 5)
  • Golden transcripts
  • Red-team scenarios
  • Engine & routing comparisons