Changelog
All notable changes to the zil-ai package are documented here.
Format follows Keep a Changelog . This project uses Semantic Versioning .
0.1.12 — 2026-05-15
Added
zil deploy --allow-unauthenticated— new flag to allow unauthenticated access to the Cloud Run service. Passes--allow-unauthenticatedtogcloud run deployvia the--separator. Works with both direct deploy and--fromartifact deploy.
0.1.11 — 2026-05-13
Added
-
Token-based cost tracking — new
spec.costmanifest section for declaring token budgets (max_tokens_per_request,max_tokens_per_session,alert_threshold_pct,track_by_model). The SDK tracks raw token counts; dollar pricing is purposefully left out of the SDK for flexibility. The vision is that there will be an external service (part of the runtime) that can convert token counts to dollar amounts. -
zil.costsingleton — module-level cost tracker:zil.cost.total_tokens,zil.cost.by_model,zil.cost.budget_remaining,zil.cost.reset(). -
CostTrackerclass — thread-safe token usage accumulator with per-request and per-session budget enforcement. -
CostCallback— ADK-compatible callback that extracts usage metadata from LLM responses (Gemini, OpenAI, Anthropic) and emits OTel span attributes. -
create_agent(enable_cost_tracking=True)— automatically initializes cost tracking fromspec.cost. -
zil validatecost checks — warns ifspec.costis absent, flags budget inconsistencies. -
zil inspectcost display — shows budget configuration from archived manifests. -
zil pack --sign— signs the.zilarchive using cosign (keyless/Sigstore OIDC by default). Produces a Sigstore.bundlefile. -
zil pack --sign --key <path>— key-based cosign signing for CI environments. -
zil inspect --verify— verifies the cosign signature of a.zilarchive. -
zil pushsignature attachment — automatically pushes the.bundlealongside the OCI artifact. -
45 new tests; 295 total tests.
0.1.10 — 2026-05-12
Added
zil auditcommand — agent-native security audit focused exclusively on LLM-specific attack surfaces. Produces a Rich-formatted report (or--format=jsonfor CI) with exit codes for pass/warn/critical.- Guardrail coverage scoring — scores coverage across 5 dimensions: injection detection, PII output, PII input, output constraints, denied topics.
- Injection resilience testing — runs 20 adversarial prompts through the
GuardrailEngineacross 6 attack categories (ignore instructions, DAN, system prompt extraction, tag injection, rule override, instruction forget). - Output leakage scan — checks if persona, instructions, or system prompt content could leak through output undetected by guardrail filters.
- Indirect injection surface analysis — AST-scans tool functions for external data ingestion (HTTP, DB, file reads, subprocesses) and flags tools whose return values bypass guardrail checks.
- Instruction consistency check — detects contradictions between permissive persona language and restrictive guardrails that create social-engineering gaps.
- Context window risk assessment — measures system prompt token usage as a percentage of model context window and warns if adversarial context stuffing is feasible.
- Identity hardening review — checks persona.md/instructions.md for anti-patterns (vague boundaries, generic assistant persona, missing refusal language).
--fixflag — appends actionable remediation suggestions to each finding.- Strengthened built-in injection patterns (10 patterns, up from 8): added instruction extraction and task override detection.
- 34 new tests (
test_audit.py); 250 total tests.
0.1.9 — 2026-05-12
Added
- Runtime Guardrail Engine — new
zil.sdk.guardrailsmodule withGuardrailEngineclass that enforces rules at runtime viacheck_input()andcheck_output()methods returning structuredGuardrailResultobjects. - Built-in prompt injection detection — 8 regex patterns detecting common jailbreak techniques (ignore instructions, DAN, system prompt extraction, XML/instruction tag injection, rule overrides).
- Built-in PII detection — blocks SSN and credit card patterns in agent output by default; optionally scans input too.
- Custom blocked patterns — define regex patterns in
guardrails.yamltargeting input, output, or both with configurable severity (block/warn/log). - Denied topics — keyword-based input blocking for restricted subject areas.
- Output constraints — configurable
max_response_lengthenforcement. - OTel guardrail spans —
GuardrailCallbackemitsguardrail.check.input/guardrail.check.outputspans with violation attributes when a tracer is available. zil validateguardrail checks — validatesguardrails.yamlstructure, counts enforceable rules, checks regex validity, and warns on missing output protections.zil create_agent(enable_guardrails=True)— guardrail engine auto-loads fromidentity/guardrails.yamland attaches to the agent asagent._zil_guardrails.- Updated
zil inittemplates — scaffoldedguardrails.yamlnow includes the runtime-enforceable format withdetection,blocked_patterns,denied_topics, andoutput_constraintssections. - 46 new tests (
test_guardrails.py); 216 total tests.
0.1.8 — 2026-05-11
Added
spec.envdeclarations — agents can declare required environment variables inmanifest.yamlwithname,description,required,default, andsecretfields.zil deploy --env-file— provide a dotenv file for automated deploys; falls back to interactive prompts (secrets masked) when no file is given.zil.configSDK object — dict-like runtime access to declared env vars from agent code (zil.config["VAR_NAME"]). Resolves fromos.environwith defaults; raisesMissingConfigErrorfor missing required vars.- Auto-load
.env.local—zil.configloads.envand.env.localfrom the project and module directories intoos.environat startup (never overrides existing values), so local dev works without manual env setup. - Pack env cross-check —
zil packscans.env/.env.localfiles againstspec.envdeclarations. Fails on undeclared vars (drift detection), warns on missing vars, and records coverage inBUILD_META.json. zil inspectenv coverage — shows declared env var count, secret count, and local resolution coverage from the archive.zil validateenv checks — reports declared env var count, warns ifspec.envis missing, and cross-references adapterenv_varreferences.zil initenv templates — scaffolded manifests includespec.envwith the LLM provider’s API key pre-declared.- 34 new tests (
test_env.py,test_pack.py::TestEnvCoverage); 170 total tests.
Changed
- Deploy env injection — environment variables are passed to Cloud Run via
gcloud--set-env-varsafter the--separator (fixes compatibility with ADK’s deploy command). load_projectwalks up — whenproject_dirpoints to a module subdirectory withoutmanifest.yaml, the SDK walks up to find the project root (fixeszil runin local dev).- Archive size display — uses KB for archives under 1 MB (previously showed
0.0 MB).
0.1.7 — 2026-05-08
Added
zil pack— real archive builder — validates the project, runs evals (gate), generates a CycloneDX 1.5 SBOM, and creates a.ziltar.gz archive with manifest, identity, adapters, evals, observability, code, SBOM, and eval results.zil inspect— archive inspector — reads.zilarchives and displays a rich summary with component table, SBOM dependency count, and eval scores. Supports--show(print specific file) and--json(machine-readable output).zil pushcommand — push.zilarchives to any OCI-compatible registry (Artifact Registry, GHCR, ECR, Docker Hub) using ORAS.zil deploy --from— deploy from a.zilarchive or OCI registry reference instead of a local project directory.- SBOM generation (
zil.packaging.sbom) — generates CycloneDX 1.5 SBOMs fromrequirements.txt. orasadded as a core dependency for registry operations.- 24 new packaging tests (
tests/test_pack.py); 135 total tests.
Changed
zil initoptions trimmed — removed--framework,--language,--target, and--eval-frameworkoptions (only supported values were used). Only--llmremains as a choice.- Eval runner uses persistent event loop — suppresses noisy Google GenAI async client cleanup errors during eval runs.
- CLI now has nine commands (added
push). - CLI docs updated with
push,deploy --from, and revisedinit/pack/inspectsections.
Removed
--no-signflag fromzil pack— cosign signing deferred to a future release.[registry]optional extra —orasis now a core dependency.
0.1.6 — 2026-05-07
Added
zil web --docker— build and run the agent in a Docker container with the ADK web UI for local testing.- Grafana OTEL-LGTM observability stack —
zil web --docker --tracestarts agrafana/otel-lgtmcontainer providing traces (Tempo), metrics (Mimir), and logs (Loki) with Grafana UI athttp://localhost:3000. - Module-level
requirements.txt—zil initnow generates arequirements.txtinside the agent module directory, required by ADK’s Cloud Run deployer.
Changed
- Eval gate blocks deployment —
zil deploynow exits with error when evals fail (previously warn-only). Use--skip-evalsto override. - Deploy copies project context —
manifest.yaml,identity/,adapters/, andobservability/are automatically included in Cloud Run deploys sozil.create_agent()works at runtime. create_agent()auto-detects project dir — falls back to caller’s file location instead of CWD whenproject_diris not specified.- Agent template uses explicit
project_dir—Path(__file__).parentensures Cloud Run compatibility without requiring the latest SDK version.
Removed
--localflag fromzil deploy— replaced byzil web --docker.- Jaeger integration — replaced by Grafana OTEL-LGTM which supports traces, metrics, and logs in a single container.
0.1.5 — 2026-05-06
Added
zil deploycommand — deploy agents locally (Docker) or to Google Cloud Run in one step.- Local deployment mode (
--local) — builds Docker image and runs the agent container locally with the ADK web UI. - Jaeger auto-start —
zil deploy --local --traceautomatically starts a Jaeger all-in-one container (UI at:16686, OTLP at:4318) and configures the agent to export spans. - Cloud Run deployment — wraps
adk deploy cloud_runwith project/region resolution from CLI flags, environment variables, orgcloud config. - Cloud Trace integration —
zil deploy --tracepasses--otel_to_cloudto Cloud Run for native GCP observability. - Pre-deploy eval gate — runs eval suite before deploying; warns on failure but does not block (use
--skip-evalsto skip entirely). - 15 new tests for deploy command (109 total tests).
Changed
- CLI now has eight commands (added
deploy). - Getting-started guide updated with deploy workflow (replaces
zil packsection). - DeepEval added to “composes with” across all documentation and website surfaces.
0.1.4 — 2026-05-05
Added
zil evalcommand group — refactored from a single command into four subcommands:run,add,record, andgenerate.zil eval add— interactively create eval cases by chatting with the agent; cases are saved to YAML and auto-registered in the suite.zil eval record— record a full chat session with the agent and convert selected turns into eval cases, with auto-detected keywords.zil eval generate— use the judge LLM to synthesize eval cases from agent identity files (persona, instructions, guardrails). Supports--count,--category, and--no-review.- Per-metric thresholds —
metric_thresholdsinevals/config.yamllets you set custom pass thresholds per DeepEval metric. - Execution controls —
execution.concurrency,execution.retries, andexecution.timeoutinevals/config.yamlfor parallel eval runs and retry logic. - Eval case writer (
zil.sdk.eval.writer) — programmatic API for appending cases to group files and auto-registering groups in suite YAML. - Eval case generator (
zil.sdk.eval.generator) — LLM-powered case synthesis with support for Gemini, OpenAI, and Anthropic judge providers. - Lazy judge model resolution — the DeepEval adapter now defers judge model initialization until LLM metrics are actually needed, avoiding import errors for deterministic-only evals.
- 14 new tests for writer, config enhancements, generator parsing, and keyword extraction (46 eval tests total).
Changed
zil evalis now a command group — usezil eval runinstead ofzil evalto run suites (no backward compatibility needed; the command was unused).- DeepEval adapter stores
_configfor lazy judge model creation; accepts_metric_thresholdsfrom engine config. - Eval runner uses
ThreadPoolExecutorfor concurrent case evaluation with configurable retries and timeout. - Eval docs page expanded with full documentation for all subcommands and new config fields.
- CLI reference docs updated to reflect the eval command group structure.
0.1.3 — 2026-05-05
Added
- OpenTelemetry tracing integration —
zil run --traceexports spans to any OTLP-compatible backend (Jaeger, Cloud Trace, Datadog, etc.);zil run --trace-consoleprints spans to stderr for local development. setup_telemetry()andsetup_console_telemetry()— new SDK functions for programmatic tracing control, exported fromzil.sdk.enable_telemetryparameter onzil.create_agent()— automatically configures OTel tracing fromobservability/config.yaml(default:True).- Observability config loading —
ProjectContextnow readsobservability/config.yamlwhen referenced in the manifest. agent.txt— agent-friendly documentation atgetzil.dev/agent.txtandgetzil.dev/docs/agent.txt.opentelemetry-exporter-otlp-proto-http>=1.20.0added to[adk]optional extra.- 10 new tests for telemetry setup and observability config loading.
Changed
- Observability config template — uses standard
OTEL_EXPORTER_OTLP_TRACES_ENDPOINTenv var (replacesOTEL_COLLECTOR_URL), addsresource_attributessection. .env.exampletemplate — referencesOTEL_EXPORTER_OTLP_TRACES_ENDPOINT(commented out by default).--trace-consoleruns in-process — uses ADK’srun_clidirectly so theConsoleSpanExporteris active during agent execution.- Observability docs page fully rewritten with dev/prod guide, SDK integration, and CLI flags.
- CLI reference docs updated with
--traceand--trace-consoleflags forzil runandzil web.
0.1.2 — 2026-05-04
Added
zil runcommand — runs the agent interactively by wrappingadk runwith automatic module detection frommanifest.yaml.zil webcommand — starts the ADK web UI for testing, wrappingadk webwith configurable port.- Gemini (AI Studio) provider — new default LLM provider using
GOOGLE_API_KEY, with link to API key generation in.env.example. - Gemini embedding adapter support (
text-embedding-004).
Changed
- Project scaffold restructured —
agent.pynow lives inside a Python package directory ({module_name}/agent.pywith__init__.py) for ADK compatibility. - Default LLM provider changed from
anthropictogeminifor easier onboarding. .env.examplemoved into the agent module directory (ADK loads.envfrom there).- Vertex AI
llm.yamltemplate now includesGOOGLE_CLOUD_PROJECTandGOOGLE_CLOUD_LOCATIONenv var references. - Dockerfile
CMDupdated to usepython -m {module_name}.agent. - README template updated with new project layout and
zil run/zil webcommands.
Fixed
- Agent naming error — kebab-case manifest names (e.g.,
qbo-bookkeeper) are now automatically converted to snake_case (qbo_bookkeeper) for ADK’sLlmAgent, fixingpydantic ValidationError. adk rundirectory error — agent code now lives in a proper Python package, fixingDirectory does not existerrors.
0.1.1 — 2026-05-02
Added
- SDK layer (
zil.create_agent()) — readsmanifest.yaml, identity files, and adapter config, then wires them into an ADKLlmAgentautomatically. - Auto-install dependencies —
zil initnow creates a.venvand installsrequirements.txtafter scaffolding. - Model resolution — maps adapter config (Anthropic, OpenAI, Vertex) to ADK-compatible model strings via LiteLLM prefix convention.
- Identity composition — persona, instructions, and guardrails are merged into a single structured instruction for the LLM.
- 20 new SDK tests (
tests/test_sdk.py). [adk]optional dependency extra inpyproject.toml.
Changed
agent.pytemplate now useszil.create_agent(tools=[])instead of a stub.requirements.txttemplate includeszil-ai[adk]instead of commented-out ADK.- Sdist excludes
artifacts/,docs/,website/,.windsurf/(85 MB → 17 KB).
Fixed
- Lint cleanup across
commands/,templates/,schema/(ruff UP037, E501, E402, F821).
0.1.0 — 2026-04-30
Added
- Initial release.
- CLI with four commands:
zil init,zil validate,zil pack(stub),zil inspect(stub). zil initscaffolds 18 files: manifest, identity, adapters, evals, observability, Dockerfile, CI pipeline, README.zil validatechecks manifest schema + file structure.- JSON Schema for Zil v1 manifest (
spec/v1/manifest.schema.json). - 15 CLI tests.