Designing functions for AI isn't the same as designing them for humans 🔧 MindRoom developer and blogger nijho.lt redesigned all 155 built-in toolkits after deleting the Agno AI framework underneath, cutting 729 default functions to 298 and shrinking total tool schemas by 50%, while the fixed per-turn prefix of MindRoom's representative agent fixture dropped 57%. The redesign consolidates per-endpoint functions into action-parameterized tools, such as a single email(action, to, message_id, subject, ...) call replacing separate read_email, write_email, save_draft, star_email and archive_email functions that each repeated shared arguments on every turn. The author argues that converting a REST API one-tool-per-endpoint into an MCP server is the least token-efficient way to give an AI tools, and that dedicated tool schemas still matter for permissions and authentication even when a shell tool suffices for pure coding tasks. A lot of people connect AI agents to their services by converting an existing REST API straight into an MCP server, one tool per endpoint. That’s probably the least token-efficient way to give an AI tools. Designing functions for an AI isn’t the same as designing them for a human programmer. I learned how much difference that makes this week while redesigning all 155 built-in toolkits https://docs.mindroom.chat/tools/ in MindRoom https://www.nijho.lt/post/mindroom/ GitHub https://github.com/mindroom-ai/mindroom , docs https://docs.mindroom.chat/ , after deleting the AI framework underneath it. Across the whole catalog, I cut 729 default functions down to 298 and shrank total tool schemas by 50%. The redesigned tools support more options, and the fixed per-turn prefix of MindRoom’s representative agent fixture dropped by 57%. For a lot of people, AI harnesses feel like magic. Really, all the magic is in the models. Every request an agent sends to an AI API is mostly freeform natural language text, plus a block of structured data. That structured data is a list of tool schemas describing every tool the model is allowed to call, from basics like reading a file read file path or running a shell command bash command to integrations like GitHub or email. When the model wants to use one, it replies with the tool name and arguments for example bash with ls data/ , and the harness runs the code on your own machine and sends the result back. Any AI harness is just that loop: hand the model a prompt and tool schemas, run the tools it asks for, and repeat. Because those schemas travel along with the conversation on every turn, their shape has a direct cost. If you define tools the way you’d write normal Python functions or wrap a REST API into MCP, you end up very verbose. For email alone, you might expose separate functions like read email , write email , save draft , star email , and archive email . Every one of those functions repeats shared arguments like to , message id , or subject , burning tokens on every turn. Instead, you can describe the same capability as one email action, to, message id, subject, ... tool where action is read , write , draft , star , or archive , and pay for the shared arguments once. A common reaction here is that once you give an agent a shell tool, you have all the harness you really need. For pure coding tasks, that’s often true, and in my tests on native harness tools https://www.nijho.lt/post/native-harness-tools/ a single-shell minimal agent used far fewer tokens than a full toolset. It stops being enough as soon as you care about permissions and authentication. Once you hand an agent a shell, it’s very hard to say “you can read my email, but you need my approval before sending an email.” You can try to enforce that with narrow API scopes, which gets messy fast across dozens of services. Authentication is also painful from a shell: you can share a raw API token with your AI, though that’s not as nice or as safe as signing in once with SSO and letting the harness hold the credentials while gating individual tools. That’s why dedicated tool schemas still matter, and why their design matters. When I started building MindRoom nearly a year and a half ago, I picked Agno https://github.com/agno-agi/agno mostly for its built-in library of 87 integrations like GitHub, Gmail, Slack, and Docker. By late October I’d already replaced Agno’s runtime after adding 126 workarounds which I wrote about in Roll your own, fork the rest https://www.nijho.lt/post/roll-your-own-fork-the-rest/ , and this week I deleted the rest of it in about 21 hours using my parallel orchestrator setup https://www.nijho.lt/post/orchestrating-orchestrators/ . 1 fn:1 With today’s models, writing thin API wrappers yourself is straightforward because popular APIs show up all over the training data. Owning all 155 toolkits also meant I was no longer stuck with Agno’s one-function-per-endpoint layout. In those same native-harness tests, frontier models didn’t care much whether tool names matched what they were trained on, while fixed per-request tokens mattered a lot. Once MindRoom owned the files, I could redesign the whole catalog around that lesson. Before the rewrite, MindRoom’s toolkits looked just like auto-converted REST APIs, with services like GitHub, Gmail, and Docker exposing twenty to forty separate functions each. Grouping related verbs under an action= parameter cut default functions across all 155 toolkits from 729 down to 298 and halved total schema size, keeping operations like all 39 GitHub actions intact.