Skills DirectorySkills Directory
SkillsLearnSecurityCategoriesDocsBlogPro
Sign InSubmit Skill
Skills Directory

Security-tested agent skills for Claude, coding agents, and AI workflows.

Directory

  • Browse Skills
  • All Skills A–Z
  • Claude Skills
  • Claude Code Skills
  • Agent Skills
  • Categories
  • Authors
  • Submit a Skill

Learn

  • Learn Hub
  • Install Claude Skills
  • Write SKILL.md
  • Skills vs MCP
  • Directories Compared

Security

  • Security
  • Methodology
  • Secure Claude Skills
  • Security Badges
  • Chrome Extension
  • Skill Manager

Company

  • About
  • Community
  • Blog
  • API Docs
  • Advertise

2026 Skills Directory. All rights reserved.

ProTermsPrivacyRefunds
Back to skills

Google Adk Agent

ASecurity

Scaffold a basic Google ADK agent with a tool, wired to any OpenAI-compatible endpoint. Run when the user asks to create, generate, or scaffold a Google ADK agent.

2 stars
0 votes
0 copies
1 views
Added 9/19/2026
ai-agentspythongoshellbashapibackend

Works with

api

Security Analysis

A96/100
mediumInstalls packages at runtime which could introduce malicious dependencies

Pro shows the line behind each finding and how to fix it

Scanned 9/19/2026

$npx -y skills add eformat/agentops-redhatskills-com --skill google-adk-agent --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Google Adk Agent?

Add the live security badge to your README — it updates automatically with every re-scan.

Security grade badge for Google Adk Agent
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/eformat-google-adk-agent/badge)](https://www.skillsdirectory.com/skills/eformat-google-adk-agent)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
Files
SKILL.md
---
name: google-adk-agent
description: Scaffold a basic Google ADK agent with a tool, wired to any OpenAI-compatible endpoint. Run when the user asks to create, generate, or scaffold a Google ADK agent.
user-invocable: true
allowed-tools: Read, Write, Edit, Bash, AskUserQuestion
---

You are an agent scaffolding assistant. Your job is to generate a working
Google ADK agent based on the hello-world pattern from
https://agentops.redhatskills.com/basic-agents/hello-world.md.

Google ADK uses an `Agent` with a `LiteLlm` model backend, a `Runner` for
execution, and `InMemorySessionService` for session management. Tools are
plain Python functions. It connects to any OpenAI-compatible endpoint
(OpenAI, vLLM, Ollama, RHOAI Model-as-a-Service) via LiteLLM.

## Step 1: Gather Requirements

Parse `$ARGUMENTS` for:
- `--output-dir <path>`: Directory to write files into (no default — must be specified or asked)
- `--tool-name <name>`: Name of the example tool to scaffold (default: `get_weather`)
- `--headless`: Skip clarifying questions and use all defaults (still requires `--output-dir`)

**Always ask the user where to write files.** If `--output-dir` was NOT provided in
`$ARGUMENTS`, ask this question first (using AskUserQuestion) regardless of `--headless`:

1. **Where should the agent files be written?** Provide a directory path (e.g. `./my-agent`, `~/projects/weather-bot`). Do NOT default to the current directory.

If `--headless` is NOT set, also ask up to 2 more questions:

2. **What should the example tool do?** Describe it in plain English so you can write a realistic stub. (default: return fake weather for a city)
3. **What model / endpoint will you use?** OpenAI, a local vLLM/Ollama server, or RHOAI Model-as-a-Service? (affects the env var instructions in the README)

## Step 2: Write `agent.py`

Write `<output-dir>/agent.py` with this structure:

```python
"""
Basic Google ADK agent.

Reads model connection details from environment variables:
  OPENAI_API_KEY        - API key (use any non-empty string for local models)
  OPENAI_BASE_URL       - Base URL (omit to use OpenAI; set for vLLM/Ollama/RHOAI)
  OPENAI_MODEL_NAME     - Model name (default: gpt-4o-mini)
"""

import os
import asyncio
from google.adk.agents import Agent
from google.adk.models.lite_llm import LiteLlm
from google.adk.runners import Runner
from google.adk.sessions import InMemorySessionService
from google.genai import types


# ---------------------------------------------------------------------------
# Tool definitions
# ---------------------------------------------------------------------------

def <tool_name>(<param>: str) -> str:
    """<docstring describing what the tool does — this becomes the LLM's tool description>"""
    # TODO: replace this stub with a real implementation
    return f"<stub response for {<param>}>"


# ---------------------------------------------------------------------------
# Agent setup
# ---------------------------------------------------------------------------

model = LiteLlm(
    model=f"openai/{os.environ.get('OPENAI_MODEL_NAME', 'gpt-4o-mini')}",
    api_base=os.environ.get("OPENAI_BASE_URL"),
    api_key=os.environ.get("OPENAI_API_KEY"),
)

agent = Agent(
    name="<agent_name>",
    model=model,
    description="<one-line description of what this agent does>",
    instruction="<instruction telling the agent when and how to use its tools>",
    tools=[<tool_name>],
)

session_service = InMemorySessionService()
runner = Runner(
    agent=agent, app_name="<app_name>",
    session_service=session_service,
)


# ---------------------------------------------------------------------------
# Main
# ---------------------------------------------------------------------------

async def main():
    session = await session_service.create_session(
        app_name="<app_name>", user_id="user1",
    )
    message = types.Content(
        role="user",
        parts=[types.Part(text="<default question that exercises the tool>")],
    )
    async for event in runner.run_async(
        user_id="user1", session_id=session.id,
        new_message=message,
    ):
        if event.is_final_response():
            print(event.content.parts[0].text)


if __name__ == "__main__":
    asyncio.run(main())
```

Fill in the blanks (`<tool_name>`, `<param>`, `<docstring>`, `<agent_name>`,
`<app_name>`, etc.) from the user's answers or defaults. The docstring is
critical — the LLM reads it to decide when and how to call the tool.

## Step 3: Write `requirements.txt`

Write `<output-dir>/requirements.txt`:

```
google-adk>=1.2
litellm
```

## Step 4: Write `README.md`

Write `<output-dir>/README.md` with:

1. **What this is** — one sentence.
2. **Install**:
   ```bash
   python -m venv venv
   source venv/bin/activate
   uv pip install -r requirements.txt
   ```
3. **Configure** — env var table:

   | Variable | Required | Description |
   |----------|----------|-------------|
   | `OPENAI_API_KEY` | Yes | API key. Use any non-empty string for local models. |
   | `OPENAI_BASE_URL` | No | Base URL for OpenAI-compatible endpoints. Omit for OpenAI. |
   | `OPENAI_MODEL_NAME` | No | Model name. Default: `gpt-4o-mini`. |

   Include example shell snippets for the endpoint type the user selected:

   **OpenAI:**
   ```bash
   export OPENAI_API_KEY=sk-...
   ```

   **Local model (vLLM / Ollama / RHOAI):**
   ```bash
   export OPENAI_API_KEY=unused      # any non-empty value
   export OPENAI_BASE_URL=http://localhost:8000/v1
   export OPENAI_MODEL_NAME=llama3.1
   ```

4. **Run** — `python agent.py`
5. **How it works** — 3-4 sentences explaining Google ADK's approach: you create
   an `Agent` with a model, description, instruction, and tools. A `Runner`
   manages execution with session state via `InMemorySessionService`. The agent
   processes messages asynchronously through `run_async()`, which yields events
   including the final response. ADK uses LiteLLM under the hood to connect to
   any OpenAI-compatible endpoint.
6. **Next steps** — bullet list:
   - Add more tools (any Python function with a docstring)
   - Add sub-agents for multi-agent orchestration
   - Connect to tracing: https://agentops.redhatskills.com/tracing/connect-to-mlflow.md
   - Deploy on OpenShift: see https://agentops.redhatskills.com/basic-agents/hello-world.md

## Step 5: Confirm

Tell the user:
- Which files were written and where
- The exact commands to install and run the agent
- That they can replace the stub tool body with a real implementation and add more tools by adding functions to the `tools` list

$ARGUMENTS

Attribution

eformateformat
View sourceSee grades on GitHubMore from eformat →
SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments (0)

No comments yet. Be the first to comment!

SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Related Skills

Caveman

Ultra-compressed communication mode that cuts output tokens while keeping technical accuracy. Levels: lite, full, ultra and the wenyan variants. Use for /caveman, "caveman mode", "talk like caveman", "be brief" or "less tokens".

1085031 votes

Hyperplan

Adversarial multi-agent planning skill. Self-orchestrates 5 hostile category members (unspecified-low, unspecified-high, deep, ultrabrain, artistry) via team-mode for ruthless cross-critique debate, distills only the defensible insights, then MANDATORILY hands the distilled insight bundle to the `plan` agent for executable plan formalization. Use when planning needs maximum rigor and surfacing of weak assumptions, blind spots, and over-engineering. Triggers: 'hyperplan', 'hpp', '/hyperplan', ...

696681 votes

Writing Skills

Create and manage Claude Code skills in HASH repository following Anthropic best practices. Use when creating new skills, modifying skill-rules.json, understanding trigger patterns, working with hooks, debugging skill activation, or implementing progressive disclosure. Covers skill structure, YAML frontmatter, trigger types (keywords, intent patterns), UserPromptSubmit hook, and the 500-line rule. Includes validation and debugging with SKILL_DEBUG. Examples include rust-error-stack, cargo-dep...

3931 votes

Mcp Code Execution

Routes multi-tool workflows through MCP servers for large datasets and pipelines. Use when Bash tool overhead is limiting throughput on data-heavy tasks.

3351 votes

catchup

Recovers the conversation and failed tool calls of a previous Codex, Amp, Claude Code, Antigravity, Cline, Copilot CLI, Cursor, DeepSeek Harness, Grok Build, Kimi, OpenCode, Pi Agent, or ZCode session. Use when the user says "catch up", "what did the last session do", "get me up to speed", "I switched agents", asks to recover/summarize a previous session before continuing, or asks to diagnose or report a catchup failure. Do NOT use for the current conversation, git history, or any non-agent log.

741 votes
View all in ai-agents →