ai

ai is a command for Claude Code from terrene-foundation/metis. It costs 0 tokens per session (553 once invoked), scanned A, a copy of ai, Apache-2.0.

A guide for building AI agents with the Kailash Kaizen framework, a software library for creating and coordinating such agents. It covers agent setup, signature-based programming, and multi-agent work.

In plain words
What is it for?
Use it to look up Kaizen agent APIs, create agents, define typed task interfaces, coordinate multiple agents, and follow the framework's execution patterns.
Why use it?
It provides project-specific patterns for teams already using Kaizen and warns when the project does not appear to use that library.

Command for Claude Code

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/terrene-foundation/metis/ai
Clone the repo
git clone --depth 1 https://github.com/terrene-foundation/metis

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for ai

README.md
[![agentmods](https://agentmods.dev/badge/commands/terrene-foundation/metis/ai.svg)](https://agentmods.dev/commands/terrene-foundation/metis/ai)
Your own site
<a href="https://agentmods.dev/commands/terrene-foundation/metis/ai"><img src="https://agentmods.dev/badge/commands/terrene-foundation/metis/ai.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 553 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin 100% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.00553
Opus 5 $0.00000 $0.00277
Sonnet 5 $0.00000 $0.00111
Haiku 4.5 $0.00000 $0.00055

Measured 5d ago against content hash c7833cf0c93e, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

ai scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

100% identical to ai — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

.claude/commands/ai.md · 80 lines

How it starts

The opening of the file, as written. The whole thing — 80 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/ai - Kaizen Quick Reference

Purpose

Load the Kaizen skill for production-ready AI agent implementation with signature-based programming and multi-agent coordination.

Step 0: Verify Project Uses Kailash Kaizen

Before loading Kaizen patterns, check that this project uses Kailash Kaizen:

  • Look for kailash-kaizen or kaizen in requirements.txt, pyproject.toml
  • Look for from kaizen / import kaizen in source files

If not found, inform the user: "This project doesn't appear to use Kailash Kaizen. These patterns may not apply. Continue anyway?"

Quick Reference

Command Action
/ai Load Kaizen patterns and agent basics
/ai agent Show Agent API patterns
/ai signature Show signature-based programming
/ai multi Show multi-agent coordination

What You Get

  • Unified Agent API (v1.0.0)
  • Signature-based programming
  • Multi-agent coordination
  • BaseAgent architecture
  • Autonomous execution modes

Quick Pattern

import os
from kaizen.api import Agent

# 2-line quickstart — model from .env, NEVER hardcoded
agent = Agent(model=os.environ["KAIZEN_MODEL"])
result = await agent.run("What is IRP?")

# Autonomous mode with memory
agent = Agent(
    model=os.environ["KAIZEN_MODEL"],
    execution_mode="autonomous",  # TAOD loop
    memory="session",
    tool_access="constrained",
)

Key Concepts

Concept Description
Signatures Define input/output contracts
Execution Modes supervised, autonomous, hybrid
BaseAgent Inherit for custom agents
AgentRegistry Scale to 100+ agents
TAOD Loop Think, Act, Observe, Decide

Agent Teams

When working with Kaizen, deploy:

  • kaizen-specialist — Signatures, multi-agent coordination, BaseAgent architecture
  • testing-specialist — Agent testing patterns (NO MOCKING)

Read the full file on GitHub · 80 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 80 lines · 0 tokens per session scan A c7833cf0c93e

Subscribe to this mod's changes

ai is a command published in the GitHub repository terrene-foundation/metis (2 stars, last pushed 4mo ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 553 tokens. A static security scan graded it A with 0 findings. It is 100% identical to ai, differing in 0 lines, and is treated as a copy.