Observed since 20 Oct, 19:37 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
Utilities for building Agent Development Kit (ADK) applications
A collection of utilities and patterns for building agents with Google's Agent Development Kit (ADK).
pip install adktools
@adk_tool decorator: Standardize your ADK tools with consistent error handling and response formattingfrom adktools import adk_tool
from pydantic import BaseModel
class WeatherResult(BaseModel):
location: str
temperature: float
conditions: str
@adk_tool
def get_weather(location: str) -> WeatherResult:
"""Get current weather for a location."""
# Your implementation here
return WeatherResult(
location=location,
temperature=72.5,
conditions="Sunny"
)
from adktools import adk_tool
from adktools.models import DomainError
from typing import Literal, Union
from pydantic import BaseModel
class TimeResult(BaseModel):
timezone: str
datetime: str
is_dst: bool
class InvalidTimezoneError(DomainError):
timezone: str
error_type: Literal["invalid_timezone"] = "invalid_timezone"
@adk_tool(
name="get_time",
description="Get the current time in a specified timezone."
)
def get_current_time(timezone: str) -> Union[TimeResult, InvalidTimezoneError]:
try:
# Implementation...
if timezone == "invalid":
return InvalidTimezoneError(
timezone=timezone,
error_message=f"Unknown timezone: {timezone}"
)
return TimeResult(
timezone=timezone,
datetime="2025-04-12T12:34:56",
is_dst=True
)
except Exception as e:
# The decorator will catch and format any exceptions
raise RuntimeError(f"Error getting time: {str(e)}")
from adktools import discover_adk_tools
from google.adk.agents import Agent
# Import your modules containing tools
import myagent.weather_tools
import myagent.time_tools
# Create an agent with auto-discovered tools
agent = Agent(
name="my_assistant",
description="A helpful assistant",
tools=discover_adk_tools(myagent.weather_tools)
)
# Or discover tools across multiple modules
all_tools = discover_adk_tools_in_modules([
myagent.weather_tools,
myagent.time_tools
])
@adk_tool DecoratorThe decorator standardizes ADK tool responses and provides additional metadata for tools:
@adk_tool # Simple usage
def simple_tool(param: str):
# Implementation...
@adk_tool(
name="custom_name", # Override function name
description="Custom description", # Override docstring
detailed_errors=True # Include stack traces in errors
)
def custom_tool(param: str):
# Implementation...
ADK Tools provides standardized response models:
from adktools.models import ErrorResponse, SuccessResponse, DomainError
# Success response
success = SuccessResponse(result={"key": "value"})
# Or without data
empty_success = SuccessResponse() # result is optional
# Error response
error = ErrorResponse(error_message="Something went wrong")
# Domain-specific error base class
class MyCustomError(DomainError):
error_type: Literal["custom_error"] = "custom_error"
error_message: str # Matches ErrorResponse field name
additional_field: str
from adktools import success_response, error_response
# Create success response dictionary
response = success_response({"data": "value"})
# {"status": "success", "result": {"data": "value"}}
# Create success response without data
empty_response = success_response()
# {"status": "success"}
# Create error response dictionary
response = error_response("Something went wrong")
# {"status": "error", "error_message": "Something went wrong"}
By default, ADK Tools uses the following standardized response formats:
{
"status": "success",
"result": { ... } // Optional result data
}
{
"status": "error",
"error_message": "Description of what went wrong"
}
This consistent response format makes it easy for agents to handle tool responses predictably.
Contributions are welcome! Please feel free to submit a Pull Request.
git checkout -b feature/amazing-feature)git commit -m 'Add some amazing feature')git push origin feature/amazing-feature)Distributed under the MIT License. See LICENSE for more information.
pypistats · 69 observations shown. Missing days are unknown. Source category: overall: without mirrors.
| Date / source period | Value | Observed at |
|---|---|---|
| 2026-10-20 – 2026-10-20 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-17 – 2026-10-17 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-16 – 2026-10-16 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-15 – 2026-10-15 | 14 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-14 – 2026-10-14 | 3 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-13 – 2026-10-13 | 3 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-12 – 2026-10-12 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-11 – 2026-10-11 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-10 – 2026-10-10 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-09 – 2026-10-09 | 5 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-08 – 2026-10-08 | 4 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-07 – 2026-10-07 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-06 – 2026-10-06 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-05 – 2026-10-05 | 4 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-03 – 2026-10-03 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-10-01 – 2026-10-01 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-30 – 2026-09-30 | 8 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-29 – 2026-09-29 | 4 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-28 – 2026-09-28 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-27 – 2026-09-27 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-26 – 2026-09-26 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-25 – 2026-09-25 | 6 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-24 – 2026-09-24 | 5 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-23 – 2026-09-23 | 5 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-22 – 2026-09-22 | 3 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-21 – 2026-09-21 | 4 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-17 – 2026-09-17 | 3 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-16 – 2026-09-16 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-15 – 2026-09-15 | 8 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-12 – 2026-09-12 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-11 – 2026-09-11 | 3 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-10 – 2026-09-10 | 7 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-09 – 2026-09-09 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-08 – 2026-09-08 | 3 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-07 – 2026-09-07 | 5 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-05 – 2026-09-05 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-03 – 2026-09-03 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-09-01 – 2026-09-01 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-31 – 2026-08-31 | 3 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-30 – 2026-08-30 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-28 – 2026-08-28 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-26 – 2026-08-26 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-25 – 2026-08-25 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-24 – 2026-08-24 | 18 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-23 – 2026-08-23 | 3 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-21 – 2026-08-21 | 10 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-20 – 2026-08-20 | 11 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-18 – 2026-08-18 | 15 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-17 – 2026-08-17 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-16 – 2026-08-16 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-14 – 2026-08-14 | 10 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-13 – 2026-08-13 | 4 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-10 – 2026-08-10 | 18 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-09 – 2026-08-09 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-08 – 2026-08-08 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-07 – 2026-08-07 | 10 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-06 – 2026-08-06 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-05 – 2026-08-05 | 24 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-04 – 2026-08-04 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-03 – 2026-08-03 | 4 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-02 – 2026-08-02 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-08-01 – 2026-08-01 | 1 | 2026-10-21T10:21:14.8928397Z |
| 2026-07-31 – 2026-07-31 | 4 | 2026-10-21T10:21:14.8928397Z |
| 2026-07-30 – 2026-07-30 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-07-29 – 2026-07-29 | 8 | 2026-10-21T10:21:14.8928397Z |
| 2026-07-28 – 2026-07-28 | 8 | 2026-10-21T10:21:14.8928397Z |
| 2026-07-27 – 2026-07-27 | 2 | 2026-10-21T10:21:14.8928397Z |
| 2026-07-24 – 2026-07-24 | 15 | 2026-10-21T10:21:14.8928397Z |
| 2026-07-23 – 2026-07-23 | 2 | 2026-10-21T10:21:14.8928397Z |
| Version | Published | Direct dependencies | Open version |
|---|---|---|---|
| 0.1.2 | 12 Apr 2025 | 3 |
This describes our collected data; it is not a security assessment.
Observed since 20 Oct, 19:37 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
package:281664aca93632ced001a1be4d98713bc64a965524d4b7fbb9d5088a42cef772