When skills are installed in the Antigravity skills directory, the
TrajectoryChatConverter loads the full text of ALL installed skills
into a hidden system message on every session start. This causes
Gemini models to crash with a truncation error while Claude models
handle it fine due to their larger context handling.
Trajectory ID: ea4214e6-7f2c-4e7d
Steps to Reproduce:
- Install a large skills pack into the Antigravity skills directory
(e.g. via npx antigravity-awesome-skills --antigravity which
installs 900+ skills) - Open any project folder in Antigravity
- Set active model to any Gemini model (tested on Gemini 3.1 Pro
High, Gemini 3.1 Pro Low, Gemini 3 Flash) - Send any message — even a simple “hello”
Expected Behavior:
- Only skills explicitly referenced via @skill-name in the current
conversation should be loaded into context - OR only skill metadata (name + description) should be pre-loaded,
with full skill text loaded lazily on demand - Graceful truncation handling instead of a hard crash
Actual Behavior:
Agent immediately crashes with:
Error: agent executor error: could not convert a single message
before hitting truncation
Stack trace:
google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func1
third_party/jetski/cortex/cascade_manager.go:2088
google3/third_party/jetski/cortex/chatconverters/chatconverters.init
third_party/jetski/cortex/chatconverters/trajectory_chat_converter.go:44
Root Cause (user analysis):
The TrajectoryChatConverter appears to scoop up the full text of
every skill file in the skills directory and cram it into a hidden
system message before the conversation even starts. With 900+ skills
installed, this system message becomes massive and exceeds Gemini’s
single-message conversion limit, causing a hard crash.
Claude models (Sonnet 4.6, Opus 4.6) work fine in the same session
with the same project — confirming this is a Gemini-specific
conversion limit issue, not a project size issue.
Workaround:
Clearing the skills directory completely resolves the issue on
Gemini models. This confirms the skills directory bloat is the
direct cause.
Suggested Fix:
- Implement lazy loading — only load a skill’s full text when
explicitly invoked via @skill-name - Pre-load only lightweight metadata (name + description) for
all skills at session start - Add a graceful size check in TrajectoryChatConverter before
conversion — truncate with a warning instead of crashing - Add a per-model context budget check so skill loading respects
each model’s actual limits
Environment:
- OS: Windows 11
- Antigravity version: latest (March 2026)
- Models affected: Gemini 3.1 Pro (High), Gemini 3.1 Pro (Low),
Gemini 3 Flash - Models NOT affected: Claude Sonnet 4.6, Claude Opus 4.6,
- Skills installed: ~900+ via sickn33/antigravity-awesome-skills
- Account plan: Google AI Pro
Additional Notes:
The Trajectory ID ea4214e6-7f2c-4e7d- should
allow internal tracing of the exact failure. Happy to provide
additional logs or reproduce on demand.