← Reddit

I built an AI photo culler for my self-hosted library using a three-model funnel (Haiku → Sonnet → Opus). Whole 25k library: ~$25. Here's the architecture.

Reddit · Professional-Job7799 · August 3, 2026
A developer built Winnow, an open-source photo culling tool for Immich that uses a three-tier Claude model funnel (Haiku, Sonnet, and Opus) to efficiently select standout photos and remove obvious rejects from personal libraries. The system employs structured outputs, batch processing, and Bradley-Terry ranking to minimize costs while maintaining quality judgments across multiple comparison rounds. Processing a 25,000-photo library cost approximately $25, substantially less than the estimated $150-200 required for manual curation.

Detailed Analysis

A developer building on top of Anthropic's Claude API has released Winnow, an open-source photo-culling tool for Immich, the self-hosted Google Photos alternative, that demonstrates a sophisticated approach to cost-efficient AI deployment at scale. The project's core insight is architectural: rather than applying a single expensive model uniformly across a 25,000-photo library, it routes work through a three-tier funnel of Claude models—Haiku 4.5, Sonnet, and Opus—each matched to a task of increasing judgment complexity and decreasing volume. Haiku triages every photo for roughly $0.0007 each, using structured outputs to assign category, verdict, and a technical score. Sonnet then ranks the surviving candidates using best-worst scaling batched into sets of eight, feeding a Bradley-Terry statistical model that extracts pairwise comparison data far more cheaply than exhaustive pairwise judging. Opus, the most capable and expensive tier, is reserved for final head-to-head comparisons among the best photos, with each pair judged twice in swapped order to detect and null out position bias. The result: the entire 25,000-photo library was culled for approximately $25.

This tiered-model approach reflects a broader pattern emerging among developers building production AI systems: treating model selection as a cost-optimization problem rather than defaulting to the most powerful (and expensive) model for every call. The photo-culling task is well-suited to this because it's fundamentally a "tail-selection problem"—most value comes from correctly identifying obvious rejects and obvious keepers, not from fine-grained distinctions in the middle of the distribution. By assigning cheap, fast Haiku to the high-volume triage work and reserving costly Opus for the small set of finalist comparisons where nuanced judgment matters most, the architecture mirrors how a human organization might delegate: junior reviewers handle bulk sorting, senior reviewers handle final calls. This kind of cascading or "funnel" architecture has become increasingly common in agentic and data-processing pipelines built on Claude, as developers discover that model capability and cost don't need to be uniform across a workflow.

Several technical details in the writeup underscore why this pattern is becoming viable at scale. Anthropic's Batch API, which offers a 50% cost discount for asynchronous processing, is well suited to unattended pipelines that don't require real-time results—the developer notes it functions as a "cheat code" for exactly this kind of workload. Structured outputs paired with Pydantic schemas eliminated JSON-parsing failures across thousands of calls, addressing a common pain point in production LLM pipelines where malformed or inconsistent model output breaks downstream processing. The developer also surfaces a subtler finding: measurable position bias in Opus's pairwise judgments, with roughly one in eight comparisons flipping when the order of images was swapped—a reminder that even frontier models carry systematic biases that need to be statistically corrected for rather than assumed away.

The project's comparison point—Amazon Mechanical Turk, which the developer estimated would have cost $150–200 for equivalent human judgment work—captures a significant economic shift underway in tasks that previously required distributed human labor. Subjective, judgment-heavy tasks like photo quality ranking, once the domain of crowdsourced human raters, are increasingly addressable by LLMs at a fraction of the cost and turnaround time, provided the pipeline is architected to route only the hardest decisions to the most capable (and costly) models. Notably, the developer also disclosed that the tool's codebase itself, including its test suite, was built in collaboration with Claude Code, reflecting the now-common pattern of using Claude both as the reasoning engine inside an application and as the coding assistant that builds the application itself. Released as an MIT-licensed, Docker-packaged open-source tool, Winnow adds to a growing ecosystem of self-hosted, privacy-conscious tools that pair local data stores like Immich with cloud-based frontier models for specific, well-bounded inference tasks.

Read original article →