Skip to content

Actions Overview

Languages: English · 中文

Actions are Agently's request-time capability layer: the model can choose a registered function, MCP tool, sandbox executor, or other backend while answering one request.

This is not the orchestration layer. If you need branches, fan-out, approval, wait/resume, or durable execution, put TriggerFlow above the request and call the agent from a chunk.

Boundaries

TopicOwnsDoes not own
Action RuntimePlanning, action-call normalization, dispatch, action logsLong-running workflow lifecycle
Agent Component helpersBusiness-facing shortcuts such as enable_python, enable_shell, and exposing the current Workspace file area through enable_workspace_file_actionsProvider lifecycle internals
Tools compatibilitytool_func, use_tool, use_tools, extra.tool_logs aliasesNew extension design
MCPLoading remote or local MCP tools into the action surfaceA separate workflow engine
Sandbox actionsRunning code through an ActionExecutor backendGeneral container orchestration
TriggerFlowStages, branches, fan-out, pause/resume, persistenceTool schema registration

Current source-backed structure

Default plugin wiring lives in agently/_default_init.py:

  • ActionRuntime: AgentlyActionRuntime
  • ActionFlow: TriggerFlowActionFlow
  • ActionExecutor: local function, MCP, Search/Browse, Python/Bash sandbox, Node.js, SQLite, Docker
  • ExecutionEnvironmentProvider: MCP, Python, Bash, Node.js, Docker, Browser, SQLite

The public facade is agently/core/operation/Action/. Agent-level mounting lives in agently/builtins/agent_extensions/ActionExtension.py. The runnable examples are grouped under examples/action_runtime/README.md, with model-backed cookbook patterns under examples/cookbook/.

Reading choices

You needRead
New function actionsAction Runtime
Give an app agent Python, shell, or workspace accessAction Runtime
Build a backend that needs managed resourcesExecution Environment
Existing code still uses tool_funcTools Compatibility
Use a local or HTTP MCP serverMCP
Route many actions across stepsTriggerFlow Patterns
Expose the action-using agent over HTTPFastAPI Service Exposure

Source notes

The ToolManager plugin type still exists for legacy use, but new examples use the Action Runtime path. The examples in examples/action_runtime/ create a request-scoped turn, inspect agent.get_action_result(prompt=turn.prompt), then call turn.get_result() and read extra.action_logs.