cape.agent: Agentic interface to CAPE¶
The main interface for running the interactive cape agentic conversation
or a single cape agent turn, passing user responses to an external LLM,
and processing the results. Interactive sessions use the Textual interface
when available, with the traditional readline loop as a fallback. Most of the
actual capability is implemented by
cape.agent.agentcntl.AgentCntl.
- cape.agent.main(cls: type | None = None, tui: bool | None = None) AgentResult¶
Run an interactive CAPE-agent session
The Textual interface is selected automatically when Textual is installed and stdin/stdout are attached to a capable terminal. Pass
tui=Falseto force the traditional readline interface.
- cape.agent.run(user_message: str) AgentResult¶
Run one noninteractive CAPE agent turn
Interactive cape agentic sessions use the Textual interface when the
optional dependency and a capable terminal are available. Use
--no-agent-tui to force the traditional readline interface. The
single-turn cape agent <prompt> command remains noninteractive.
cape.agent.agentcntl: Controller class for CAPE agentcape.agent.agenttui: Textual interface for CAPE agentcape.agent.agentutils: Extra utilities for agentic interfacecape.agent.bgtasks: Background tasks for the CAPE agentcape.agent.options: Options for CAPE agenticcape.agent.tools: Tools exposed to the CAPE agentcape.agent.skills: Agent skills for the CAPE agent