machichdigital
RegelCursor RulesLizenz: CC0 1.0frei kopierbar

Google Adk

Cursor-Regel für Googles Agent Development Kit, sorgt für ADK-konforme Agenten- und Tool-Struktur.

⬇ Als Datei laden

× kopiert× heruntergeladenBewertung:

Cursor-Regel für Googles Agent Development Kit, sorgt für ADK-konforme Agenten- und Tool-Struktur.

Original-Beschreibung der Autoren: Google Agent Development Kit rules for agents, tools, sessions, memory, artifacts, evaluation, and deployment

Die Regel

---
description: Google Agent Development Kit rules for agents, tools, sessions, memory, artifacts, evaluation, and deployment
globs: ["**/*.py", "**/*.ts", "**/*.tsx", "**/*.go", "**/*.java", "pyproject.toml", "package.json"]
alwaysApply: false
---

# Google ADK Rules

## Agent Design

- Keep each agent focused on a clear goal, persona, and tool set.
- Use LLM agents for flexible reasoning and workflow agents for deterministic orchestration.
- Write instructions that define task boundaries, tool-use rules, and escalation behavior.
- Split multi-agent systems by responsibility rather than by implementation convenience.
- Keep model choices configurable.

## Tools

- Give tools narrow, typed inputs and outputs.
- Validate tool arguments before performing side effects.
- Keep secrets, credentials, and privileged APIs out of agent prompts.
- Handle tool errors explicitly and return actionable failure messages.
- Be aware of ADK tool limitations; some built-in tools cannot be combined with other tools on the same agent.

## Sessions, State, and Memory

- Use session state for current-conversation data.
- Use memory for cross-session recall and retrieval.
- Keep state small and serializable.
- Do not store large files or binary payloads in session state.
- Make state keys stable and documented.

## Artifacts

- Use artifacts for generated files, uploaded files, reports, images, audio, and other binary data.
- Configure an artifact service in the runner before relying on artifact operations.
- Version artifact filenames intentionally and avoid overwriting semantically different outputs.
- Store only references or summaries in state when full content belongs in artifacts.

## Evaluation and Deployment

- Add tests for tool behavior, agent routing, prompt regressions, and unsafe tool calls.
- Use trace or event logs to debug agent decisions.
- Keep local development, staging, and production configuration separate.
- Add observability for latency, tool failures, token use, and handoff failures.

## Common Mistakes

- Do not make one agent responsible for every workflow.
- Do not let tools accept arbitrary shell, SQL, or HTTP input without validation.
- Do not rely on prompt text for access control.
- Do not hide important side effects behind generic tool names.

So nutzt du sie

Die Regel kopieren (Button oben) oder als Datei herunterladen und im Projekt unter .cursor/rules/ ablegen — Cursor lädt sie beim nächsten Start automatisch. Ältere Cursor-Versionen lesen alternativ eine einzelne .cursorrules-Datei im Projektstamm; dort einfach den Regel-Text ohne den Kopfblock zwischen den ----Zeilen einfügen.

Der Regel-Text ist englisch — Cursor versteht ihn unabhängig von der Sprache, in der Sie mit dem Editor chatten.

Im Detail

Regel für Projekte, die mit Googles Agent Development Kit arbeiten — einem Framework zum Bauen von KI-Agenten, das eng mit Googles Modell- und Cloud-Ökosystem verzahnt ist. Sie gibt Cursor vor, wie Agenten, Tools und Orchestrierung im ADK-typischen Muster aussehen sollen, statt generischen oder falschen Agenten-Code zu erzeugen. Nützlich für Entwickler, die gezielt im Google-Stack bleiben wollen (z. B. wegen Vertex-AI-Integration); wer framework-agnostisch bauen will, ist mit einer allgemeinen Agent-Regel besser bedient.

Praxis-Tipp

Vor dem Prompten kurz festlegen, ob wirklich ADK und nicht ein anderes Agent-Framework zum Einsatz kommt — sonst erzeugt die Regel unpassende Strukturen.

Siehe auch

Lizenz & Quelle

Inhalt ansehen (google-adk.mdc)
Lade …

Erfahrungen & Kommentare.

Funktioniert der Regel bei Ihnen? Tipps, Stolperfallen, Varianten — teilen Sie es mit der Community.

Lade Kommentare …

Ihre IP-Adresse wird zum Schutz vor Missbrauch gespeichert und nach 14 Tagen automatisch entfernt (Datenschutz).

Passt dazu.