Learning to Build an SDK

I love to write code. I’m not a professional software engineer, but I appreciate the craft. Software is a rich domain for exploring ideas and the feedback loops are fast. I decided to build an SDK. My inexperience makes me paranoid, so I lean on Claude for implementation while driving the project direction. I’m going to make mistakes, but if I set the right example, I’ll get better help from AI and other humans. Here’s what I’m trying to keep in mind: ...

July 4, 2025 · 4 min · 671 words · davenpi

SDK Part 2: Simple and testable

I love to understand how things work. I especially love when I peel back the curtain and have that “aha” moment. When the core ideas become clear and the implementation lets them shine—that’s delightful. Client sessions in SDKs are like plumbing for most engineers—boring but essential. You just want to know it’s there when you need it, that the pipes go where they should, and that it’s reliable. You shouldn’t have to invest much energy in understanding what’s going on. ...

June 22, 2025 · 5 min · 1031 words · davenpi

SDK Part 1: Keeping it Pythonic

Model Context Protocol (MCP) is great. Usage has exploded since its release, and I jumped in—reading the spec and contributing to the growing open source ecosystem. Once I dug into the Python SDK, I struggled to map the spec’s clean concepts to the implementation. Take an InitializeRequest. The spec gives us this TypeScript: 1 2 3 4 5 6 7 8 export interface InitializeRequest extends Request { method: "initialize"; params: { protocolVersion: string; capabilities: ClientCapabilities; clientInfo: Implementation; }; } To understand the equivalent Python code, I had to trace through multiple abstraction layers: ...

June 9, 2025 · 2 min · 407 words · davenpi

Server-Side Agents: An emerging pattern

The problem Your AI assistant burns through multiple attempts on simple requests like “let’s discuss this PR.” First it tries to fetch the PR but forgets GitHub’s query syntax. Then it asks permission to retry. It gets the PR but needs another request for review comments—and fails again because it mixed up the API parameters. You’re watching it stumble through what should be one smooth conversation. The insight MCP currently follows a “smart host, dumb servers” pattern—one AI learns every API across all its server connections. Instead, flip to “orchestrating host, smart servers.” Put specialist agents inside MCP servers and let your host delegate through natural language. ...

May 28, 2025 · 2 min · 225 words · davenpi