AI TrackerGet the app
← All news

Gemini API lets developers change system instructions and tools mid-conversation without breaking the prompt cache

Google released mid-conversation system instruction and tool changes in preview in the Gemini API, through the Interactions API. It says agents can adopt new rules and tools mid-session without the model re-reading the whole conversation, which would add cost and latency.

Developers send a system_input step directly before user_input on any turn, with the previous turn's ID in previous_interaction_id. Google says it carries the same authority as the top-level system instruction and takes precedence over user messages, while earlier turns stay cached. Each system_input stays active for the rest of the session. When a newer one conflicts with an earlier instruction, the model favors the most recent. Retrieved interactions show each system_input step in order, which Google says makes agent traces easier to audit.

For tools, Google recommends keeping the same top-level tools list on every turn and using added_tools and removed_tools in a system_input step; removals are processed before additions, so a tool definition can be replaced in place. Only function tools are supported, not MCP server tools. Google warns that these steer model behavior and are not access controls: applications should still authorize every function call on the backend and keep untrusted content out of system_input.

There is no separate fee: system_input tokens are billed at the model's standard input rate, and earlier turns remain eligible for cached-token rates. The feature is in public preview on all Gemini 4 models through the v1beta endpoint of the Interactions API. Google says support for Gemini Enterprise Agent Platform is coming soon.

Get news like this as a push.

AI Tracker alerts you when something changes for the tools you use.

Get the app