Integrations & Tools
~9 min readUpdated: November 2026

Google DeepMind Mass Spec Skills for Antigravity: 97% MS/MS Accuracy & Agentic Skills Guide

DeepMind Mass Spec Skills for Google Antigravity diagram transforming MS/MS spectral peaks into a verified C20H21ClN6O urea structure using SKILL.md, matchms, SIRIUS, and RDKit

Mass Spec Skills for Google Antigravity is a suite of modular SKILL.md domain workflows built by Google DeepMind (google-deepmind/science-skills) that connects Gemini models with matchms, GNPS, MoNA, SIRIUS, MAGMa, MetFrag, and RDKit to raise tandem mass spectrometry (MS/MS) identification from under 4% to ~97% while cutting token consumption up to 4x.

Technical Review: Smoke Monkey Core Architecture Team
Tested on Node.js 18+ & BunTypeScript 5.x
Quick Answer & Executive Definition

Google DeepMind Mass Spec Skills for Antigravity: 97% MS/MS Accuracy & Agentic Skills Guide: Mass Spec Skills for Google Antigravity is a suite of modular SKILL.md domain workflows built by Google DeepMind (google-deepmind/science-skills) that connects Gemini models with matchms, GNPS, MoNA, SIRIUS, MAGMa, MetFrag, and RDKit to raise tandem mass spectrometry (MS/MS) identification from under 4% to ~97% while cutting token consumption up to 4x. Designed as a zero-dependency, open-source TypeScript architecture under the MIT License with native Model Context Protocol (MCP) support and deterministic phase state machines.

Key Architectural Takeaways
Quick Implementation Examplemass-spec-skills-agent.ts
mass-spec-skills-agent.tstypescript
import path from 'node:path';
import os from 'node:os';
import { createAgent } from '@smoke-monkey/harness';
// Load Google DeepMind science-skills (~/.gemini/config/skills) into Smoke Monkey Harness
const massSpecAgent = createAgent({
agentId: 'build',
provider: 'gemini',
model: 'gemini-3.8-flash',
workspacePath: process.cwd(),
skillsDir: path.join(os.homedir(), '.gemini/config/skills'),
tools: ['filesystem', 'terminal', 'search', 'agent'],
permission: 'ask-default',
});
// Auto-allow read-only inspection and local uv chemistry runs; gate destructive shell commands
massSpecAgent.on('permission.required', (event) => {
const { toolCallId, toolName, args } = event.data;
const cmd = String(args?.command ?? '');
const isSafeUvRun = toolName === 'run_command' && /^uv run /.test(cmd);
const isRead = ['read_file', 'glob', 'grep', 'list_skills', 'use_skill'].includes(toolName);
massSpecAgent.resolvePermission(toolCallId, isRead || isSafeUvRun ? 'allow' : 'deny');
});
async function identifySpectrum(mzmlPath: string) {
const result = await massSpecAgent.run(
`Use list_skills and use_skill to load the Mass Spec and PubChem skills. ` +
`Preprocess ${mzmlPath} with matchms (10 ppm tolerance), determine formula in SIRIUS, ` +
`rank PubChem isomers with MAGMa/MetFrag, validate in RDKit, and write an auditable Markdown report.`
);
console.log('Run status:', result.status, 'Loaded skills:', massSpecAgent.skills.count);
}
identifySpectrum('./samples/unknown-395.1387.mgf').catch(console.error);
Video Guides

Watch: Related Video Guides

Google Says Antigravity's Mass Spec Skills Hit 97% Accuracy in a Test on Known Molecules

Google Mass Spec Skills: From a Lab Signal to Molecular Evidence

What Are Mass Spec Skills for Google Antigravity?

Mass Spec Skills for Google Antigravity are modular SKILL.md domain packages built by Google DeepMind (distributed alongside google-deepmind/science-skills) that connect Gemini models with established mass spectrometry tools—matchms, GNPS, MoNA, SIRIUS, MAGMa, MetFrag, PubChem, and RDKit. Released on November 25, 2026, the skills lift automated MS/MS structure identification from under 4% to ~97%.

A single drop of blood, soil, or plant extract yields tens of thousands of tandem mass spectrometry (MS/MS) signals, yet reference spectral libraries annotate only ~5% of measured spectra overall and ~10% in human samples—the "dark matter" of mass spectrometry. Standalone language models cannot close that gap because matching fragment ions requires exact monoisotopic mass arithmetic, multi-million-compound database queries, and bond-cleavage simulations.

By packaging exact CLI invocations, instrument-tolerance guards, and uv-managed Python helper scripts inside SKILL.md folders, Antigravity replaces brittle ad-hoc LLM coding with deterministic tool orchestration that any chemist can steer in plain English.

The Agentic Skills Pattern: Gemini + Agent Loop + SKILL.md

Instead of cramming chemistry documentation into the system prompt, Google Antigravity and Smoke Monkey Harness load only skill summaries upfront and read the full SKILL.md + helper scripts on demand when a spectrum requires matchms, SIRIUS, or PubChem.

Enamine REAL MS/MS Benchmark: 97% Accuracy & 4x Token Savings

Google DeepMind benchmarked three models—lightweight Gemini 3.8 Flash and frontier Gemini 4 Argon and Gemini 4 Carbon—across 100 compounds sampled from the Enamine REAL MS/MS collection in MoNA (catalogued in PubChem), allowing three attempts per spectrum within a one-hour wall-clock budget.

ConfigurationGemini 3.8 Flash AccuracyGemini 4 Argon / Carbon AccuracyGenerated Tokens vs. Argon BaselinePrimary Failure Mode
Antigravity Alone (No Internet, No Skills)< 4%< 4%Highest token spendModel attempts to guess molecular structures directly from raw m/z peak lists
Internet Access Only (Ad-hoc Scripts)< 25% (> 75% missed)~67%–75% (25%–33% missed)1.0x baseline (Argon)Custom one-off API scripts break on precursor windows, adducts, and noisy peaks
Internet Access + Mass Spec Skills~97%~97%~0.25x (Flash, ~4x cut) · 0.5x (Argon) · ~0.8x (Carbon)Residual cases limited by structural isomers without retention time or NMR

Two engineering findings stand out from the benchmark. First, Gemini 3.8 Flash matches frontier Gemini 4 Argon and Carbon at ~97% exact-match accuracy once equipped with validated skills, proving that structured tool affordances matter more than raw parameter scale for deterministic scientific pipelines. Second, eliminating trial-and-error script debugging cuts generated tokens nearly 4x on Flash, by half on Argon, and by nearly a fifth on Carbon.

6-Stage Tandem Mass Spectrometry Pipeline (matchms to RDKit)

In Google DeepMind's reference elucidation trace, a single natural-language prompt drives the agent across six verifiable computational stages—transforming an unannotated [M−H]− spectrum (m/z 395.1387, neutral mass 396.1459 Da) into a ranked structural confirmation:

Pipeline StageCommunity Tool / DatabaseKey Computation & Verified OutputTrace Metric
1. Signal PreprocessingmatchmsConverts [M−H]− precursor to neutral mass 396.1459 Da and filters instrument noise1,761 raw peaks → 19 signal peaks
2. Spectral Library SearchGNPS & MoNACosine-similarity matching within instrument-specific ppm mass tolerancesChecks known reference spectra first
3. Formula DeterminationSIRIUSComputes fragmentation tree across 10 candidate elementsC20H21ClN6O (-1.5 ppm, score 37.86 vs 28.33)
4. Candidate RetrievalPubChemQueries catalogued isomers matching exact molecular formula845 candidate isomers retrieved
5. Fragment & Neutral-Loss ScoringMAGMa, MetFrag, & Pairwise Loss LookupMaps predicted substructures and sequential HCl / HNCO losses (m/z 232.0283 → 196.0511 / 189.0238 → 153.0453)14 of 19 peaks (97.7% summed intensity)
6. Isomer Tie-Breaking & ValidationRDKit + Cleavage ScoringEliminates CID 154638626 (no urea linkage; missing 377.1281 / 214.0178 water losses) and CID 55558151 (score 49.0)Confirms CID 137835447 (score 26.0)

Notice how the agent uses complementary evidence rather than a single black-box score: m/z 162.1037 ([C9H12N3]−) and m/z 232.0283 ([C11H7ClN3O]−) split the parent ion across a central urea linkage, while secondary fragments (m/z 206.0485, 126.0114, and 93.0463–119.0611) separate the true regioisomer (CID 137835447, bond-break score 26.0) from the piperidine-inverted amide isomer (CID 55558151, score 49.0).

Installing Science Skills in Google Antigravity and Smoke Monkey Harness

You can run Google DeepMind's scientific skills inside the Google Antigravity IDE, via the open npx skills CLI, or inside your own TypeScript runtime using @smoke-monkey/harness (skillsDir).

Option 1: Install via Antigravity UI or npx CLI

bash
# 1. Install the open-source DeepMind Science Skills bundle (Apache 2.0)
npx skills add google-deepmind/science-skills/

# 2. Optional: place custom or modified skills in your personal skills directory
# (Never edit inside the managed plugin cache, or updates will overwrite changes)
mkdir -p ~/.gemini/config/skills/custom-mass-spec

# 3. Pre-verify uv is available for isolated Python environments (matchms, rdkit)
uv --version || curl -LsSf https://astral.sh/uv/install.sh | sh

In the Google Antigravity desktop app, open Customizations → Build with Google → Science → Add (or install the Mass Spec plugin). Enterprise teams can sign in via Use Business Account with Google Cloud credentials, and eligible academic researchers can apply for Google DeepMind's 6-month free top-tier Antigravity access program (10,000 seats).

Option 2: Self-Hosted Execution with Smoke Monkey Harness

Because @smoke-monkey/harness natively parses SKILL.md frontmatter and exposes list_skills and use_skill to any provider (gemini, openai, anthropic, ollama, or vllm), you can execute the same Mass Spec workflow headlessly in CI/CD pipelines or inside Smoke Monkey Canvas multi-agent workflows with explicit permission.required gates around uv run commands.

Analytical Limits: Enantiomers, Retention Time & Novel Natural Products

Google DeepMind's research notes two physical limits of tandem mass spectrometry that agentic tooling cannot bypass on MS/MS peaks alone:

  1. Mirror-Image Enantiomers & Stereoisomers: Molecules with identical connectivity and nearly identical fragmentation pathways produce overlapping MS/MS spectra. Resolving them requires orthogonal measurements such as chromatographic retention time, ion mobility, or NMR spectroscopy.
  2. Unrecorded Novel Natural Products: Compounds absent from PubChem, GNPS, and MoNA cannot be confirmed as exact database hits automatically. In those cases, Mass Spec Skills output an auditable starting point—a SIRIUS molecular formula, ppm error bounds, and peak-by-peak substructure annotations—so an analytical chemist can prioritize isolation and NMR confirmation.

Human-in-the-Loop Verification

Always inspect the agent's ppm tolerance assumptions, adduct state ([M+H]+ vs [M-H]-), and fragment intensity coverage (e.g., 14/19 peaks at 97.7% intensity) before promoting a candidate CID to wet-lab validation.

Google Search Questions & Answers

Frequently Asked Questions

Q:How do I install Google DeepMind Mass Spec Skills in Google Antigravity?

Open Google Antigravity and go to Customizations > Build with Google > Science > Add (or install the Mass Spec plugin). You can also install the Apache-2.0 DeepMind skill bundle via CLI with `npx skills add google-deepmind/science-skills/` and ensure `uv` is installed to manage Python dependencies.

Q:Why did Gemini 3.8 Flash match Gemini 4 Argon and Carbon at 97% accuracy?

Without skills, lightweight Gemini 3.8 Flash missed over 75% of benchmark spectra even with internet access because ad-hoc scripts broke on precursor windows, adducts, and noise peaks. With Mass Spec Skills providing validated matchms, SIRIUS, MAGMa, MetFrag, and RDKit tool calls, Flash reached ~97% exact-match accuracy while cutting generated tokens nearly 4x.

Q:What software tools and chemical databases do Mass Spec Skills orchestrate?

The workflow chains matchms for spectral denoising and adduct conversion, GNPS and MoNA for reference library matching, SIRIUS for fragmentation-tree molecular formula assignment, PubChem for isomer retrieval, MAGMa and MetFrag for bond-cleavage scoring, and RDKit for chemical structure validation.

Q:Can I run Antigravity SKILL.md workflows inside Smoke Monkey Harness?

Yes. Pass `~/.gemini/config/skills` (or your project `.agents/skills` directory) to `skillsDir` in `@smoke-monkey/harness` `createAgent()`. The agent discovers skills via `list_skills`, loads full `SKILL.md` instructions via `use_skill`, and executes `uv` scripts under your `permission.required` policy.

Q:Can Mass Spec Skills distinguish mirror-image enantiomers or undiscovered molecules?

No. LC-MS/MS alone cannot reliably separate enantiomers or stereoisomers that fragment identically; those require retention time, ion mobility, or NMR. For genuinely novel molecules not in PubChem, the agent provides a predicted formula, ppm mass error, and peak annotation table for a chemist to review.

Related Alternatives & Comparisons

Related Architecture Guides

View all guides

Build with Smoke Monkey Harness

Zero dependencies. 24 built-in tools. Human-in-the-loop safety. 100% open source under the MIT License.

npm install smoke-monkey-harness