Latest articles
- Designing Streaming Responses for AI Agents: Implementation Patterns for Handling Interruptions, Reconnections, and Partial Display During Generation
A streaming response looks simple until a user closes their laptop halfway through an answer. They reopen it 30 seconds later: the agent may still be working, b
- Designing Tool Definitions for AI Agents: Patterns for Naming, Descriptions, Argument Schemas, and Error Responses to Reduce Wrong Tool Selection and Argument Errors
In one six-month deployment of a multi-agent support platform, 34% of failed turns were attributed to wrong tool selection or argument mismatch rather than hall
- Designing Prompt Injection Defenses for AI Agents: Implementation Patterns for Separating Trust Boundaries and Handling External Content
I have stopped trying to sanitize prompts perfectly. Perfect sanitization is impossible: external content can be obfuscated, quoted, encoded, or phrased in ways
- Human-in-the-Loop for AI Agents: Implementation Patterns for Pausing Before Execution, Awaiting Approval or Rejection, and Resuming with State Preserved
The first time an agent tried to send an email on my behalf, I realized that autonomy is not a single feature. It is a spectrum, and one of its most useful cont
- Making AI Agent Plans Resilient: Implementation Patterns for Replanning Under Uncertain Tool Results
An agent plan is a bet. It bets that a search will return useful results, an API will respond with a success code, a file will exist and be available, a payment
- Sandboxing AI Agents with Least-Privilege Capabilities: Patterns for Restricting Tool Execution
Why This Matters More Than You Think AI agents are moving beyond conversation. They orchestrate workflows, retrieve documents, execute code, write files, call e
- Designing Observability for AI Agents — Tracing Tool Calls and Visualizing Failures with OpenTelemetry
Traditional applications usually fail at identifiable boundaries. An HTTP request returns 500 , a database query times out, or a worker crashes and emits an exc
- Contract Testing for AI Agent Pipelines: Validating Structure Over Content to Prevent Hallucination Drift
The 2 A.M. Call That Wasn’t a Bug At 2 a.m., an on-call engineer receives an alert: the final agent in a production workflow is rejecting input from the planner
- Designing Deterministic Tests for AI Agent Outputs — Automatically Detecting Hallucinations and Regressions with eval-gate
“Looks Good” Is Not a Test Traditional software gives us a reassuring property: for a known input, we can usually predict the output. add(2, 3) -> 5 AI agents b
- Designing Safe Retries for AI Agent Tool Calls: Idempotency, Timeouts, and Recovery from Partial Failures
Retries look simple until an AI agent starts touching the real world. If a model calls a weather API twice, the result is usually harmless. If it sends an email
- The Problem Nobody Talks About Until It Breaks Production
The Problem Nobody Talks About Until It Breaks Production You have shipped an AI agent that calls a dozen tools: search APIs, databases, email providers, paymen
- How to Implement Memory Compression for AI Agents: Merging Old Memories When the Count Exceeds 60
AI agents get forgetful in a very specific way. They do not forget like humans do. They run out of usable context. In my agent framework, Spark, the long-term m
- Needle 2, the 14MB Agentic Model — I Benchmarked It Against My Own AI Assistant
I run a resident AI assistant called Spark. I built it myself, and I use it every day. I talk to it, ask about the weather, play music, leave memos. When you li
- Homelab Security
When I built my homelab, security was an afterthought. I had a Proxmox host, a 24-port switch, and an itchy trigger finger for new containers. Six months later,
- Building an Autonomous AI Assistant with Persistent Memory and Self-improving Loops
I run a Tauri-based AI assistant called `spark` 24/7 on a Mac at home. It plans its own work, executes approved tasks, publishes blog posts, tracks revenue, and
- How to Securely Publish WordPress from Your Home Server
Introduction The appeal of running WordPress on a home server is that you can cut monthly costs without depending on rented servers or the cloud. On the other h