Berktug Berke Ates
Software Engineer
Blogs
Field notes on software architecture, AI products, cross-platform engineering, reliability, and technical leadership.
Observability for Streaming LLM ResponsesBatch LLM calls hide latency behind one completion event; streaming exposes partial failure users feel as freezes long before error rates move. Staff engineers trace each turn from client render through gateway and provider, measure time-to-first-token and inter-chunk gaps, correlate disconnects with billing, and attach lightweight quality signals on the same timeline as latency SLOs. · 20 min readPermission Models for Multi-Tenant AI CopilotsA copilot that inherits chat access but skips data ACLs will quote the wrong tenant with confidence. Staff engineers route every tool call through the same authorization path as REST handlers, partition retrieval by tenant, issue short-lived scoped credentials, and test cross-tenant denial continuously—not only in demos. · 21 min readCache Invalidation for Personalized AI UIsPersonalized AI UIs cache embeddings, completions, and UI fragments for speed—then serve the wrong tenant the wrong answer when keys ignore identity, entitlements, or prompt revision. Staff engineers treat invalidation as authorization: namespace every layer, bust on authz events, and prove isolation with canaries—not TTL hope. · 20 min readDesigning Human Escalation Queues for AgentsAgents that never escalate look autonomous until users hit silent dead-ends. Staff engineers define policy triggers, ship structured context packs, route by skill and authority, measure time-to-human SLAs, and close the loop so resolutions train the next automation path. · 19 min readCost Attribution for Shared LLM GatewaysA shared LLM gateway without attribution becomes a black hole: one provider invoice and no join key to product surfaces. Staff engineers require tenant, product, and caller tags on every call, emit normalized usage events, version price tables, roll agent fan-out with correlation ids, and wire budgets to policy—not slide-deck chargeback. · 19 min readOffline-First Sync Conflicts in Mobile AppsOffline-first UX promises continuity; sync promises eventual consistency. Without explicit conflict models, users see duplicated payments, lost edits, and tickets that reproduce only on airplanes. Staff engineers separate duplicate intents from true edits, enforce server merge rules, and measure queue health like payments. · 22 min readFeature Store vs Prompt Store TradeoffsFeature stores answer what signals were true at decision time with point-in-time correctness; prompt stores answer which instructions, tools, and policies the model saw with review and rollback. Conflating them creates duplicate truth, stale context, and the wrong on-call rotation when something breaks at 2 a.m. · 20 min readContract Testing for AI Tool CallingWhen models skip required fields or invent arguments, prompt unit tests are not enough. Staff engineers version tool schemas like product APIs, split adapter from executor contracts, gate CI on golden fixtures, and fail closed on irreversible tools when validation breaks. · 19 min readProgressive Delivery for Multi-Tenant SaaSAPIs outlive screens. Staff engineers model stable domain resources, ship additive changes with telemetry on deprecated fields, require idempotency on money-moving mutations, and enforce authorization on the server—so Expo clients and partner integrations upgrade on different calendars without surprise semantics. · 20 min readMeasuring Retrieval Quality Without Vanity MetricsCosine similarity and demo click-through do not prove retrieval helps users complete tasks. Staff engineers label query sets with must-find docs and hard negatives, gate releases on recall and abstention accuracy, and tie online metrics to job completion—not thumbs-up on fluent wrong answers. · 20 min read