Theme: The Craft

Length: ~700 words

Hook: Analytical — expose the invisible cost everyone pays


Here's something every team building AI agents has experienced but few talk about: the glue code tax.

You start with a framework. LangChain, CrewAI, AutoGen — pick one. You write your first agent. It's 50 lines. It works. You're happy.

Then you add a second agent. They need to communicate. You write 100 lines of glue code to connect them.

Then you add tools. Each tool needs to be registered, typed, documented, and wired. Another 200 lines.

Then you add memory. The framework's memory module doesn't quite fit your use case, so you write a custom adapter. 150 lines.

Then you add RAG. The framework's RAG integration expects a specific vector store, but you're using a different one. Another 100 lines of adapter code.

Then you add governance. The framework doesn't have governance, so you import a separate tool and wire it in. 200 lines.

Then you add monitoring. Another library, another integration, another 100 lines.

You started with 50 lines of agent logic. You now have 800 lines of agent logic and 1,200 lines of glue code. The glue code is 70% of your codebase.

The tax compounds.

The glue code doesn't just exist — it has to be maintained. Every framework update might break an adapter. Every new tool requires new wiring. Every change to the agent flow requires touching 5 files across 3 libraries.

The tax shows up in ways that are hard to measure: