Skip to content

CLI Reference

An agent reference is file.py:agent_name; without :agent_name, run and chat use the first agent found in the file. --session / -s defaults to default.

Terminal window
astromesh-adk run agents.py:my_agent "What is CRISPR?"
astromesh-adk run agents.py:my_agent "query" --session lead-123
Terminal window
astromesh-adk chat agents.py:my_agent
astromesh-adk chat agents.py:my_agent --session s1
Terminal window
astromesh-adk list agents.py

Output:

┌──────────────┬──────────────┬─────────┬───────┐
│ Name │ Model │ Pattern │ Tools │
├──────────────┼──────────────┼─────────┼───────┤
│ assistant │ openai/gpt-4o│ react │ 2 │
└──────────────┴──────────────┴─────────┴───────┘
Terminal window
astromesh-adk check agents.py

Checks, per agent: the provider’s API-key env var is set, Tool classes declare a name, and an MCP toolset’s command is on PATH. Issues are printed; the exit code stays 0.

Terminal window
astromesh-adk dev agents.py --port 8000

--port / -p defaults to 8000. --reload / -r is accepted but the server does not start with it: the app is built in-process, and uvicorn only reloads an app given as an import string.

Starts a FastAPI server with:

  • GET /v1/health — Health check
  • GET /v1/agents — List agents
  • POST /v1/agents/{name}/run — Execute agent (body {query, session_id?, context?}, returns {answer, steps})