Google Cloud Tech — notes

Five Skill Patterns

Drawn from Google Cloud's "5 Agent Skill Design Patterns Every ADK Developer Should Know"

Why patterns at all?

It is easy to assume that getting the YAML in SKILL.md right is the job. That part is only the shell. The real work is designing what goes inside: how do you stop an agent skipping steps, guessing, or returning something shaped differently every time? These five patterns are the answer to that.

01

The five at a glance

# Pattern In one line
01 Tool Wrapper Load the expert knowledge only when it is needed
02 Generator A template guarantees the shape of the output
03 Reviewer A checklist stands between the work and done
04 Inversion Ask enough questions before starting
05 Pipeline A strict multi-step pipeline

02 — Tool wrapper

Tool Wrapper

Domain expertise, loaded on demand

The problem

Put every framework document — FastAPI conventions, React rules, the SQL style guide — into the system prompt and you pay for all of it on every turn, while the model's attention spreads across things this task does not need.

The pattern

In SKILL.md declare a trigger. When the agent notices the user mention a framework, it pulls the matching conventions from references/ at that moment, and not before.

SKILL.md → Tool Wrapper pattern
# trigger
when: user mentions "FastAPI" or "API endpoint"
load: references/fastapi-conventions.md

# behaviour
then: develop against the conventions just loaded
       tokens spent only when relevant

Why it works

The context window stays clean. Specialist knowledge arrives when it is relevant, so nothing irrelevant is competing for the model's attention.

03 — Generator

Generator

A template for consistent output

The problem

Ask a model to write a report freehand and the shape changes every time — a table of contents on Tuesday, none on Wednesday; three sections once, thirty the next.

The pattern

Write the template up front (in assets/) and have the agent fill it in rather than construct a document from nothing.

assets/report-template.md
# {{title}}

## Executive Summary
{{summary: two or three sentences}}

## Key Findings
{{findings: bulleted, three to five}}

## Risk Assessment
| Risk | Severity | Action |
|---|---|---|
{{risks: fill the table}}

## Next Steps
{{actions: in priority order}}

Why it works

Format and content come apart. The model spends its effort on what is worth saying; the template guarantees the shape.

04 — Reviewer

Reviewer

A checklist stands between the work and done

The problem

What comes back looks right and has a hole in it — an unhandled edge case, a missing security check, a team convention nobody wrote down.

The pattern

A separate reviewer skill that loads its own checklist from references/, verifies against it item by item, and reports findings grouped by severity.

Critical

Security holes, data exposure

Warning

Performance, maintainability

Info

Style, best practice

Why it works

Checking is separated from producing. One agent does the work, another inspects it — the same reason code review is not done by the author.

05 — Inversion

Inversion

Ask before you build

The problem

"Build me a website" arrives, and the agent starts writing React. What comes out bears little relation to what was wanted, because the default instinct is to act rather than to find out.

The pattern

Invert the behaviour: make it an interviewer before it is an implementer. Non-negotiable gates: no work starts until every parameter it needs has been collected.

Inversion, step by step
✕ Default agent
  User: "build me a website"
  Agent  -> starts a React project...

✓ Inversion
  User: "build me a website"
  Agent  → Phase 1: interview
           "What kind of site is this?"
           "Who is it for?"
           "Is there a design to work from?"
         → Phase 2: confirm
           "Here is what I have. Is this right?"
         → Phase 3: build
           start development

Why it works

Asking first is what stops the model filling gaps with invention. The more complete the context, the less there is to invent.

06 — Pipeline

Pipeline

A strict multi-step pipeline

The problem

A complex task has stages, and a model will skip one, merge two, or lose the important middle step — most often when the context is already long.

The pattern

Design the skill as a strict pipeline: named phases, with a gate between each. The agent finishes the current phase and gets a human confirmation before the next one opens.

Phase 1
Research

Gate

Phase 2
Plan

Gate

Phase 3
Execute
Done
Verify

Why it works

Unpredictable text generation becomes a state machine — controllable, repeatable, and auditable after the fact.

07

Three things to hold on to

Progressive disclosure

ADK's SkillToolset loads instructions and context at the moment they are needed — cheaper, and more focused.

Format apart from content

SKILL.md gives you a standard shell; these patterns are what decides how the agent thinks and acts inside it.

They compose

Mix them. Put a reviewer at the end of a pipeline; put inversion in front of a generator to collect its parameters first.

08

Further reading