The biggest cost levers
Prompt caching is often the quickest win. Major providers such as Anthropic and OpenAI bill cached input tokens at a much lower rate, provided long, stable parts like the system prompt, tool definitions or reference documents sit at the start of the prompt. A response cache inside your own application can go further and answer identical requests without calling a model at all.
On model choice, classification, extraction and short summaries are usually handled reliably by small models. A router sends only complex requests to the large model. Capped output length, trimmed or summarized chat histories and targeted retrieval instead of whole documents cut token volume further.
Technical waste is easy to overlook: retries after timeouts, agent loops without a stop condition and test environments running on production keys. These leaks only show up once cost per feature is visible, and usually take a few lines of code to close.
Our four-step approach
We optimize based on measurements from your app, not gut feeling. Each measure is rolled out on its own and compared against the previous setup, so savings and quality stay transparent. Our AI code engineers implement the changes directly in your repository, together with your team if you like.
- We instrument your app so tokens, latency and cost are tracked per feature, model and user.
- Real, anonymized requests become an evaluation set that every change is tested against.
- We implement caching, model routing, prompt trimming and batch processing for work that is not time-critical.
- Rate limits, daily budgets and alerts keep cost spikes in check for the long run.
Platform versus custom build, and privacy
Not every AI feature needs to be run in-house. For knowledge assistants and document AI in companies and public authorities, kalAIDoCreate can be the better foundation, because hosting and model integration are already taken care of.
Cost and privacy go hand in hand: the less context you send to a model, the cheaper and more data-minimal the call. Textwash Pro automatically removes personal data before text is handed to a language model, supporting GDPR-compliant processes.
Frequently asked questions
Will answer quality suffer with smaller models?
Not necessarily. An evaluation set built from real requests shows you before switching whether quality holds up. A router still sends difficult cases to the more capable model.
How quickly does prompt caching pay off?
As soon as prompts are structured with the stable parts first, every following request within the cache lifetime benefits. Depending on the provider, caching is controlled through markers in the request or applies automatically to sufficiently long prompts.
Can you switch us to open-weight models?
Yes, if the numbers work. Self-hosted models come with infrastructure and operations costs that we weigh against API spend. A mix of both is often the most economical setup.