Skip navigation
We just rolled out mid-conversation system instructions in the Gemini API 🚀 We added a new…
0:00 / 0:59

We just rolled out mid-conversation system instructions in the Gemini API 🚀 We added a new…

Philipp Schmid

@_philschmid135K followers

Visit on X
168 likesDownloadOriginal post

13,781 views

We just rolled out mid-conversation system instructions in the Gemini API 🚀 We added a new system_input step that allows you to change instructions or add/remove tools at any turn, while earlier turns stay cached. You can now - Steer agents mid-session with SI authority (plan → build) - Add tools on demand, like newly added MCP servers. - Add and Unlock tools after a user signs in, e.g. write email - Remove a tool during an outage, then adding it back - Apply limits found mid-session Preview on Gemini 4 Carbon, Neon & Hydrogen.

11 Comments

Comments from the original post on X (Twitter)

  • Philipp Schmid's profile picture

    @_philschmid

    Learn more in the docs:

    7 likes

  • JrCrypt 🀄️'s profile picture

    @JHorlanrewaju

    so you can just change the rules mid way and it keeps up? i wish people did that too haha

    2 likes

  • Tom's profile picture

    @_Tomhuy

    this seems especially useful for AI tutors. you could gradually remove instructions and hints as the student becomes more comfortable with a topic

    1 like

  • Dmitry Golovach's profile picture

    @dagolovach

    Good for caching. On Claude, tools and the system prompt sit at the start of the cached prefix, so changing them mid-session breaks the cache. A new step keeps earlier turns cached. When you remove a tool, what happens to old calls to it in the history?

  • Stefano Rifici's profile picture

    @SedyBenoitPeace

    Nice one. In my harness, tool definitions were the hidden bill: Copilot sent 102–146k tokens of them per call until I moved to deferred loading (max 13.5k). Swapping tools per phase, plan → build, without losing the cache is exactly the piece I was missing 😁

  • Jess's profile picture

    @atomicbyte_

    so only the app can send system_input right, a tool result cant sneak one in?

  • Alessandro Moretti's profile picture

    @Moretti_ale90

    Good. Client briefs always change on day three.

  • Rishit Jain's profile picture

    @RishiJain2205

    can you swap the model mid session too or just the instructions and tools

  • Maanas Tyagi's profile picture

    @maanas_tyagi

    editing the tools list between turns invalidates the prompt cache system_input lets you add or remove a tool and keep the earlier turns cached

  • Sanskar Shukla's profile picture

    @sanskar0627

    mid session tool changes help the hard part is still knowing which limits to apply before the agent burns the budget on the next noisy turn

  • Om Londhe's profile picture

    @theomlondhe

    removing a tool during an outage and adding it back is the one I'd use most. right now I either restart the session or let the agent keep calling something that's down