Skip to main content

lizard-adk

Lizard (lizard.build) connects ADK agents to Lizard Sandboxes. The plugin supplies four tools and releases each sandbox when its ADK invocation ends.

Install

Requires Python 3.11+, ADK 2.12+, a Lizard project, and a project API key.

pip install lizard-adk

Set LIZARD_API_KEY and LIZARD_PROJECT_ID. The agent example also needs GOOGLE_API_KEY for Gemini.

Use

from google.adk.agents import Agent
from google.adk.apps import App
from google.adk.runners import InMemoryRunner
from lizard_adk import LizardPlugin

plugin = LizardPlugin()
root_agent = Agent(
    name="sandbox_agent",
    model="gemini-flash-latest",
    tools=plugin.get_tools(),
)
runner = InMemoryRunner(
    app=App(name="sandbox_example", root_agent=root_agent, plugins=[plugin]),
    plugin_close_timeout=120,
)
# Run the agent, then always await runner.close() in a finally block.

Register the plugin in both places: get_tools() exposes the tools, and App.plugins runs cleanup. See the complete example for session creation, a prompt, and cleanup.

Tool Result
lizard_execute_command Shell stdout, stderr, and exit code
lizard_execute_code Python output, display results, and a structured error
lizard_read_file UTF-8 text, up to 1 MiB
lizard_write_file Write UTF-8 text, up to 1 MiB

Python variables and files persist across calls within one invocation. A later user message starts a new invocation and gets a fresh sandbox. The host keeps the Lizard API key; it does not put it in session state or tool results.

Options and limits

Pass project_id, api_key, api_url, size, lifetime_ms, or command_timeout_ms to LizardPlugin. Defaults are the small interpreter template, a 15-minute lifetime, and a 60-second command timeout. The maximum command timeout is 120 seconds. The command tool defaults to /home/user.

Shell output follows the Lizard SDK response limits. Use files for larger results. This plugin does not persist a sandbox between invocations or support custom Docker images. Always close the runner after errors or cancelled runs. If cleanup fails, retry plugin.close(); it retains the sandbox handle until deletion succeeds.

Checks

Unit tests cover schemas, invocation isolation, files, errors, cancellation, and cleanup retries. Cloud tests exercise each tool and a real ADK runner with a scripted model, so they do not call a paid model API.

pip install -e '.[dev]'
pytest tests -m 'not live' --disable-socket --allow-unix-socket
# With Lizard credentials:
LIZARD_LIVE_TESTS=1 pytest tests -m live

Metadata

Release files for lizard-adk 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for lizard-adk 0.1.1
File Size Uploaded
lizard_adk-0.1.1.tar.gz 11.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for lizard-adk 0.1.1
File Interpreter ABI Platform
lizard_adk-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 20.4 kB

Release files / lizard_adk-0.1.1.tar.gz

Download URL lizard_adk-0.1.1.tar.gz
Size 11.0 kB
Tags Source
SHA-256 checksum
How to use checksums
1c97121891c08cdda604b6a057c8caa5c164a11e73c324c272ef80244522a1fe
BLAKE2b-256 checksum
How to use checksums
f5439122ca7e81b01b89fd3505235c1c02abfe000f3989bf839dd989a4fa808d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / lizard_adk-0.1.1-py3-none-any.whl

Download URL lizard_adk-0.1.1-py3-none-any.whl
Size 9.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
7953e0fdb287fcce88c5f01252d44eb3f9d45e0f7bd3bcbf34e53b14f1b7f201
BLAKE2b-256 checksum
How to use checksums
8b24057cbcce4f5da9579150e9c542af09b88bb30be91485213d2fb8e3e0abc0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page