Skip to content

CLI

aigise.cli.aigise_cli

logger = logging.getLogger(__name__) module-attribute

AigiseInMemorySessionService

Bases: BaseSessionService

In-memory SessionService without deepcopy and without app/user state.

Differences vs google.adk.sessions.in_memory_session_service.InMemorySessionService: - No deepcopy on reads; callers receive and mutate the live Session object. - No app_state/user_state accumulation or merging; only per-session state. - GetSessionConfig is ignored (we do not slice events on get). - One live Session object instance per (app_name, user_id, session_id).

AigiseWebServer

Single-agent FastAPI server reusing provided agent and services.

  • Binds to a single app_name and prebuilt root_agent
  • Does not reload agent or auto-discover agents
  • Uses provided services (session/artifact/memory/credentials)
  • Exposes rich endpoints: run, SSE, live, session CRUD, artifacts, dev-UI

_load_mk_agent_from_dir(agent_dir: str)

Load mk_agent callable from an agent folder.

_prepare_environment_async(config_path: str, agent_dir: str) -> str async

Prepare AIgiSE environment: create session and initialize sandboxes.

Returns:

Type Description
str

The created AIgiSE session_id (used to bind agent state).

_verify_agent_module(agent_dir: str) -> None

Best-effort precheck to load agent module early.

This surfaces import errors before starting the server.

cli_dependency_check()

Check AIgiSE external dependencies.

Checks for manually installed dependencies: - CodeQL: Required for CodeQL static analysis features - Docker: Required for native Docker sandbox backend - kubectl: Required for Kubernetes sandbox backend

All dependencies are optional unless you plan to use the corresponding features.

cli_web(config_path: str, agent_dir: str, host: str, port: int, reload: bool, log_level: str, neo4j_logging: bool)

Starts an AIgiSE-flavored Web UI: prepare environment then serve agents.

collect_sandbox_dependencies(agent) -> set[str]

Collect all sandbox dependencies from an agent and its tools.

This function performs static analysis on an agent's tools to determine which sandboxes are required. It checks for __sandbox_requirements__ metadata on: - Direct tool functions (decorated with @requires_sandbox) - Toolset instances (including MCP toolsets, returned by get_toolset() functions decorated with @requires_sandbox) - AgentTools (agents wrapped as tools, recursively) - Sub-agents (recursively)

Parameters:

Name Type Description Default
agent

An agent instance (LlmAgent, SequentialAgent, AigiseAgent, etc.)

required

Returns:

Type Description
set[str]

A set of sandbox type names required by the agent and all its sub-agents and mcp toolsets.

get_aigise_session(aigise_session_id: str, config_path: Optional[str] = None) -> AigiseSession

Get or create an AigiseSession for the given session ID.

load_plugins(enabled: Iterable[str] | None) -> List[BasePlugin]

Instantiate plugins in the order provided by enabled.

main()

AIgiSE CLI tools.

verify_codeql() -> VerificationResult

Verify CodeQL installation.

Returns:

Type Description
VerificationResult

VerificationResult indicating if CodeQL is ready.

verify_docker() -> VerificationResult

Verify Docker installation and daemon availability.

Returns:

Type Description
VerificationResult

VerificationResult indicating if Docker is available.

verify_kubectl() -> VerificationResult

Verify kubectl installation and Kubernetes cluster connectivity.

Returns:

Type Description
VerificationResult

VerificationResult indicating if kubectl is available.

aigise.cli.aigise_web_app

logger = logging.getLogger('aigise.' + __name__) module-attribute

AigiseWebServer

Single-agent FastAPI server reusing provided agent and services.

  • Binds to a single app_name and prebuilt root_agent
  • Does not reload agent or auto-discover agents
  • Uses provided services (session/artifact/memory/credentials)
  • Exposes rich endpoints: run, SSE, live, session CRUD, artifacts, dev-UI

_InMemoryExporter

Bases: SpanExporter