AI Trends

Google DeepMind Engineer Shares Five Adjustments to the Gemini 4 Neon Coding Workflow

QbitAIUpdated Nov 29 00:12

AI summary

Google DeepMind engineer Philipp Schmid shared five adjustments he made when coding with Gemini 4 Neon, including removing conflicting legacy rules, centrally defining tool interfaces, loading Skills on demand, validating results with images and videos, and starting new sessions with handoff files. He recommends keeping GEMINI.md concise, specifying tool parameter constraints in JSON Schema, and recording objectives, finalized decisions, and file paths at the end of each phase to reduce contextual redundancy and information loss caused by compression.

Why read this

SelectedAI score 76

This approach combines streamlined rules, on-demand skill loading, and session handoffs into a workflow that can reduce contextual redundancy and instruction conflicts for coding agents.

Topics

Tags

Body · AI translation

Google’s Tibo Personally Reveals the Internal Way to Unlock Gemini 4 Neon! Step One: Delete All the Old Rules

Just now, Google’s version of Tibo, **Philipp Schmid**, posted on X to share the **internal way to unlock** Gemini 4 Neon, which has received widespread praise over the past few days, offering a hands-on tutorial!

He said that everyone using Neon should carefully review their old configurations and clean up outdated and duplicate rules.

His own GEMINI.md can now fit on a single screen.

Philipp believes outdated rules not only conflict with current instructions, forcing the model to fight itself and consume extra tokens.

Even worse, the model will still most likely follow the incorrect old rules, affecting its output.

Going further, Philipp offered several recommendations in the article that users can adopt directly, covering the degradation caused by long-context compression and how to write and invoke tool rules:

For example, to reduce the “intelligence loss” caused by compressing long conversations, he suggested having the model record the objective, key decisions, and file paths at the end of each phase, then opening a new session to continue the work.

For tool calls, examples can be removed so that the model operates directly according to the interface rules, reducing errors caused by mechanically copying examples.

…

Philipp is currently a Staff Engineer at Google DeepMind, responsible for developer experience and relations. His role is similar to Tibo’s at Google, helping developers use models such as Gemini and Gemma.

Before joining Google in 2025, he served as a technical lead at Hugging Face.

Below is an edited version of the original article. If you use Gemini 4 Neon, you can give this tutorial directly to the model!

Five Habits I Changed After Using Gemini 4 Neon

When using a coding agent, the prompt entered by the user occupies only a small portion of the context. The rest consists of system instructions, tool definitions, Skills, and the preceding conversation history.

Many of these rules remain in effect for subsequent requests, even when they are no longer suitable for the current task.

Over the past few weeks, I have used Gemini 4 Neon every day to write code and run evaluations. I found that rules originally added to compensate for older models’ weaknesses now interfere with the new model’s judgment instead.

In some cases, the model could have handled the task on its own, but adding these constraints actually made errors more likely.

After switching to the new model, I also reviewed my configuration and made the following five adjustments.

1. Start by deleting conflicting rules

Previously, whenever I encountered a problem, I added another rule.

If the model tended to write useless comments, I restricted its use of comments. If I worried that it might change code it should not touch, I added another rule limiting the scope of its changes.

Over time, user-level instructions, project-level instructions, and the current task began to conflict with one another.

For example, a global rule might prohibit adding comments, while my current request is to add documentation to a public function, effectively giving the model two opposing instructions at once.

In tests, Gemini 4 Neon would spend additional reasoning tokens deciding which instruction to follow, yet sometimes still obey the old rule in the end and fail to complete the current task.

So I deleted those overly strict coding-style constraints and instead told the model to refer to the existing code’s style, naming conventions, and comment density, then decide for itself based on the project’s actual circumstances.

After this adjustment, the model spent fewer tokens resolving rule conflicts, and task accuracy improved as well.

My user-level GEMINI.md can now fit on a single screen.

It retains only requirements that apply to every session: which operations require confirmation first, how to verify information, how to report progress on long-running tasks, and preferences for the language and format of responses.

Here is one excerpt:

This content cannot currently be displayed outside a Feishu document

Processes related to specific tasks go into Skills and are read only when needed.

I also found that a long list of prohibitions did not make older models merely inspect the code without taking action when debugging. Instead, it added instruction conflicts and consumed more reasoning tokens.

After switching to Gemini 4 Neon and simplifying the rules, it can still keep changes within the required scope.

2. For tool rules, stating them once in a clear interface is enough

When using previous generations of models, I often had to write tool rules twice: once in the tool definition and again in the system instructions. Sometimes I also had to add few-shot examples showing how to fill in the parameters.

For example, the old configuration below repeated the rules for making code changes and updating plans in two different places:

This content cannot currently be displayed outside a Feishu document

After switching to Gemini 4 Neon, I removed the duplicated tool rules from the system instructions as well as the few-shot examples.

Examples are useful for common tasks, but they can also constrain the model’s approach to unusual situations. When the task changes, the model may continue using the fields and parameter structure from the examples, adding unnecessary fields or using an unsuitable format, causing the call to fail.

Now, tool rules are defined centrally in the interface and stated only once. When building an agent with the Gemini API, parameter types, allowed values, and required fields can be defined directly in the tool’s JSON Schema.

For example, the task-list tool below requires every step to have a title and status. The status must be selected from four possible values, and no additional fields are allowed. The tool description also specifies that only one step may be in progress at any given time:

This content cannot currently be displayed outside a Feishu document

If you use coding agents in your daily work, you can apply the same principles when designing helper scripts and command-line tools in your repository: define parameters clearly, restrict the available values, and provide explicit error messages. Compared with lengthy usage examples, these design choices do more to help the model call tools correctly.

When a command produces a huge volume of logs, save them to a file first and read the relevant sections when needed instead of stuffing all the output into the context.

In my experience, as long as the interface is clearly defined, Gemini 4 Neon can follow rules written only once in the tool interface, even in a long session.

After I removed the repeated explanations from the system instructions, the context contained less redundancy, while tool calls were unaffected.

3. Load skills only when needed

I deleted most of the project-level AGENTS.md and GEMINI.md files.

Much of their content merely repeated descriptions of the directory structure, information the model can obtain by inspecting the repository itself. Some files also kept accumulating new material while rarely being cleaned up, gradually amassing a large amount of outdated guidance.

Now, I keep only a brief project introduction in the project instructions, along with special conventions that the model cannot discover simply by reading the code.

For example, the project may require a nonstandard command to run tests, or all shared types may have to be placed in a particular file. This information needs to be stated in advance.

For specific workflows such as long-form editing, UI guidelines, API reviews, and CLI usage guides, I put each one in a separate Skill and leave a one-line description in the index so the model can find it based on the task.

The Skills themselves should also be lightweight. Clearly state team conventions and the checks that must be performed; there is no need to prescribe steps for every possible situation.

If there is a lot of content, split it into several interlinked files and let the agent read each section only when it reaches the corresponding step.

This approach is especially effective for frequently updated CLI tools, SDKs, and internal APIs.

Having the model read the latest guide before using them reduces cases where it supplies the wrong parameters or calls deprecated interfaces.

Reading a Skill also consumes tokens, but in my tests it reduced repeated trial and error later, resulting in lower total token usage.

Gemini 4 Neon is also more reliable at finding and loading Skills and lazily loading tools, and it can usually locate the guidance needed for the current task. There is therefore no need to put every file and tool definition into the context at the start of a session.

4. Use images and videos to provide guidance and verify results

For routine backend code changes, a few short lines of written requirements are entirely sufficient. But whenever UI layouts, architecture diagrams, or motion effects are involved, text alone leaves too much room for misunderstanding.

With Gemini 4 Neon, I am increasingly using images and videos both as “reference examples” and as “acceptance criteria.”

Instead of laboring over two paragraphs of CSS rules to describe a page layout or chart style, it is better to provide a reference screenshot or a recording of just over ten seconds. The desired look, feel, and spacing are all visible there.

When the task is complete, I also ask the agent to actually render the page, chart, or video frame, open the resulting PNG or video clip, inspect it, and only then report completion.

Truncated text, labels wrapping unexpectedly, or misaligned elements can be spotted at a glance in the rendered image, but not from text logs alone.

5. Hand off context instead of constantly compacting it

Even with a context window of one million tokens, a coding session that runs for too long will still become increasingly cluttered and slow to respond, eventually requiring compaction.

But compaction loses information. When an agent generates a summary in the middle of a task, it not only disrupts the Prompt Cache but may also omit specific code details. Over the next few conversational turns, the model then has to reread files it has already seen.

So now I prefer to divide the work proactively into stages rather than letting a single session drag on indefinitely.

When the task moves into its next stage, I ask the agent to write a short handoff file recording the current objective, the decisions already finalized, and the exact paths of the relevant files. I then start a new session with that file and continue the work.

If I want to make progress on something else at the same time, I fork a new session from the current point. Each task proceeds independently instead of waiting in a queue within the same session.

For example, after running an evaluation and reviewing the failure logs, I first ask the agent to generate a handoff file and then start a new session to write the analysis report. At the same time, I fork the original evaluation session to generate charts from the results it has already read and then verify that the charts are correct.

If you are developing your own agent, automatic compaction can remain as a fallback, but do not let it trigger too early.

In my experience, triggering it at around 500,000 tokens works well. Retaining a longer context reduces the trouble caused by prematurely resetting the cache and rereading files.

When generating a summary, retain the paths of files currently being worked on and the decisions already finalized so the model has the key information it needs to continue.

Putting these settings together

If you are preparing to adjust your Gemini 4 Neon workflow, review the contents of the context item by item and remove anything unnecessary.

User-level rules: Keep the global GEMINI.md brief, retaining only general safety requirements and response preferences. For code style, use fewer rigid prohibitions and provide more decision criteria, such as following the project’s existing conventions.

Tool and script interfaces: If you are building your own agent, put tool rules in JSON Schema, clearly specify parameter types and allowed values, and remove few-shot examples and repeated system instructions. When using a coding agent in daily work, design command-line parameters and helper scripts to the same standard.

Project files and skills: Clean up lengthy project-level AGENTS.md and GEMINI.md files, retaining only matters that require special explanation within the codebase. Put task-specific workflows into concise Skills; if there is a lot of content, split it into interlinked files.

Visual references and checks: For tasks involving visual results, provide a reference screenshot or short screen recording directly. Before delivery, have the agent open and inspect the actual rendered result.

Session handoffs: Avoid compacting the context in the middle of a task whenever possible. At the end of each stage, use a short handoff file to start a new session; if there are parallel tasks, fork them from the current session.

Remove conflicting instructions and repeated tool descriptions so Gemini 4 Neon can spend more reasoning tokens on the task at hand.

Thanks for reading!

Source

QbitAI