Notes from the foundry
Engineering essays on generative AI, retrieval systems, and what it takes to ship intelligent software to production.

Your Agent's Real Unit Cost Is Per Completed Task, and You Are Probably Not Measuring It
Per-token pricing tells you almost nothing about what an agent costs, because failed attempts bill the same as successful ones and context re-sending dominates the bill. Here is the cost model that actually predicts your invoice, with the four terms most teams leave out.

How to Read a 2026 Model Announcement Without Being Sold To
Frontier-Bench, GDPval-AA, SWE-bench Pro, and Arena Elo measure four different things, and a launch post will quote whichever one flatters the model. Here is what each archetype actually tells you, why a 43% score can be state of the art, and how to build the fifty-task eval that decides it for you.

Provider SDK or Independent Framework: Pick by Where Your Control Flow Lives
The 2026 agent framework landscape splits into provider-native SDKs and independent frameworks, and feature comparisons will not separate them. The question that does is whether your loop's control flow lives in the model, in a graph you declare, or in ordinary code you wrote.

Million Token Windows Did Not Kill Retrieval. They Changed What It Is For.
Context windows crossed a million tokens and the argument that retrieval is obsolete came back. It is wrong for a reason that has nothing to do with whether the model can find the needle: in an agent loop you re-send the window every turn, and retrieval is now a cost and latency control rather than a workaround.

CIMD Makes Your Authorization Server an HTTP Client. Plan For That.
The 2026-07-28 MCP spec deprecates Dynamic Client Registration in favour of Client ID Metadata Documents, where the client_id is a URL your server fetches. It fixes real problems with DCR and hands you an outbound request to an attacker-influenced URL, which is a threat model worth writing down before you ship it.

Long-Horizon Agents Are Batch Jobs. Build Them Like It.
Every 2026 model launch claims long-horizon capability, and teams keep shipping agents that lose two hours of work to one failed API call. The fix is not a better model, it is thirty years of batch processing practice: checkpoints, idempotent steps, and resume from the last good state.

Native Multimodal Models Beat Your OCR Pipeline, Then Take Away the Thing You Needed Most
Frontier models now post better than 90% on document understanding benchmarks and read a PDF page directly. That collapses a four-stage pipeline into one call, and it removes provenance, confidence, and loud failure. Here is how to get the accuracy without giving up the audit trail.

Why Trusting AI Generated Code Is the Wrong Goal
Trusting AI generated code was never the right goal, and the 4 percent of developers who say they fully trust it prove nothing is broken: the fix is an AI code review process that makes verification cheap instead of asking how much to trust the output.

Five AI Agents, One Bug: When Missing Data Looks Like a Clean Result
We built and shipped five open-source vertical AI agents. Every single one had the same class of defect: absent or unreadable input rendered as a confident, clean answer. Here is what that bug looks like, why tests miss it, and what actually catches it.

Best Open Weight LLMs for Agents in 2026
A practical look at the best open weight LLMs for agents in 2026, organized by which constraint, cost, latency, or data residency, should actually decide the pick.

Self-Hosted LLM Observability: Tracing Agents in Production with Langfuse
A practical guide to self-hosted LLM observability with Langfuse, from Docker Compose setup and TypeScript instrumentation to RAGAS evaluation and what to alert on.

We Open-Sourced the AI Agent We Use to Scope Work and Watch Retainers
agent-for-agencies is an open-source AI copilot that prices scope, drafts SOWs, and catches an underwater retainer before the quarter's numbers do. Here's the arithmetic underneath it, verified against the code.

When Not to Build a Multi-Agent System
A multi-agent system buys you exactly one thing, context isolation, and most teams reach for one long before that trade-off is worth making.

Slopsquatting: How AI Hallucinated Packages Become a Supply Chain Attack
Slopsquatting is when an attacker registers the package name an AI coding tool keeps hallucinating, then waits for someone to install it. Here's how it works and how to defend against it.

AI Agent Security After the First Sandbox Escape
A documented AI agent sandbox escape in July 2026 is forcing a hard question in AI agent security: what does your agent actually have the power to reach?

MCP Went Stateless: Migrating Your Server
The 2026-07-28 MCP revision drops sessions, the initialize handshake, and server-initiated requests. What breaks, and how to migrate.

Stacked Pull Requests on GitHub: A Guide
GitHub's native stacked PRs, in practice: how the gh stack workflow works, how to size a stack, and when stacking is the wrong tool.

We Open-Sourced an AI Agent for Coverage Citations: And Broke It Twice
agent-for-insurance is an open-source drafting aid that will not state a coverage conclusion without citing your policy's own text. Here's how it works, and the two parsing bugs that taught us why that rule has to be enforced in code, not prose.

AI Agent Memory: Mem0 vs Zep vs Letta
A practical comparison of AI agent memory frameworks Mem0, Zep, and Letta, covering the LongMemEval benchmark and which one actually fits your constraints.

The AI Coding Tools Stack: Why Teams Run Cursor, Claude Code, and Copilot Together
Why an AI coding tools stack beats a single tool: what job Cursor, Claude Code, and GitHub Copilot each do, and how to decide which one gets a given task.