CLI Reference#
Installing MS-Agent registers the ms-agent console command. Use it to run an
agent, launch the Web/terminal UI, manage scheduled jobs, manage agent files and
plugins, and start A2A / ACP protocol services.
Invocation format:
ms-agent <command> [<args>]
List all commands:
ms-agent --help
Command overview:
Command |
Description |
|---|---|
|
Run an agent (single query or interactive mode) |
|
Launch the terminal interactive UI (TUI) |
|
Launch the Web UI server |
|
Launch a Gradio app (DeepResearch / FinResearch) |
|
Scheduled-job orchestration (daemon + job management) |
|
Manage agent workspace files (upload/download/sync/convert/backup, etc.) |
|
Install and manage plugins |
|
Start an A2A (Agent-to-Agent) protocol HTTP server |
|
Generate an A2A Agent Card ( |
|
Start an ACP (Agent Client Protocol) server (stdio, or HTTP) |
|
Start an ACP proxy that routes to multiple backend agents |
|
Generate an ACP |
Notes: an empty βDefaultβ cell means there is no default value; arguments marked required must be provided. Flag arguments (
action=store_true) take no value β their presence meanstrue.
run β Run an Agent#
Run an agent from a config or a query. Without --query, it enters interactive
mode.
ms-agent run --config path/to/agent.yaml --query "Hello"
Argument |
Description |
Default |
|---|---|---|
|
Directory or ModelScope repo id of the config file |
|
|
Query/prompt to send to the LLM; if unset, enters interactive mode |
|
|
Directory for agent outputs, histories and artifacts; overrides |
|
|
Use a built-in project (choices come from the built-in project list) |
|
|
Path to a |
|
|
Trust external code referenced by the config file |
|
|
Load previous step histories from cache (useful when retrying a failed query) |
|
|
Extra MCP server config |
|
|
Extra MCP server file |
|
|
API key for an OpenAI-compatible service |
|
|
API key for ModelScope api-inference services |
|
|
Animation mode for the video-generation project: |
|
|
Comma-separated list of paths for knowledge search |
|
tui β Terminal UI#
Launch an interactive UI in the terminal.
ms-agent tui --config path/to/agent.yaml
Argument |
Description |
Default |
|---|---|---|
|
Path to an |
built-in |
|
Working/project directory (== |
current directory |
|
Path to a |
|
|
Permission mode for tool calls: |
|
|
Allow loading external code referenced by the config (flag) |
|
|
Path to an MCP servers JSON file |
|
|
Also append every structured AgentEvent as JSON lines to this file |
|
ui β Web UI Server#
Launch the Web UI server.
ms-agent ui --host 0.0.0.0 --port 7860
Argument |
Description |
Default |
|---|---|---|
|
The server host to bind to |
|
|
The server port to bind to |
|
|
Enable auto-reload for development (flag) |
|
|
Run in production mode (serve built frontend, flag) |
|
|
Do not automatically open the browser (flag) |
|
app β Gradio App#
Launch a Gradio application UI.
ms-agent app --app_type doc_research
Argument |
Description |
Default |
|---|---|---|
|
App type: |
|
|
Gradio server name to bind to |
|
|
Gradio server port to bind to |
|
|
Share the Gradio app publicly (flag) |
|
cron β Scheduled Jobs#
Manage the cron daemon and jobs. Format: ms-agent cron <action> [<args>].
ms-agent cron start --foreground
ms-agent cron create "0 9 * * *" "Generate daily report" --name daily-report
ms-agent cron list --all
Subcommand |
Arguments |
Description |
|---|---|---|
|
|
Start the cron daemon; |
|
none |
Stop the cron daemon |
|
none |
Show scheduler status |
|
|
Run a single scheduler tick |
|
|
List cron jobs |
|
|
Create a cron job; |
|
|
Pause a job |
|
|
Resume a paused job |
|
|
Run a job immediately |
|
|
Remove a job |
|
|
Show job run history |
|
|
Show job output |
|
none |
Import jobs from |
agent β Agent Hub File Management#
Manage agent files between the local workspace and remote repositories: upload,
download, background sync, list remote repositories, cross-framework conversion,
local status, backups and restore. Format: ms-agent agent <action> [<args>].
Supported frameworks: qoder, qwenpaw, openclaw, hermes, nanobot, openhuman, ms-agent.
Shared credential options (common to the network subcommands upload / download / watch / list):
Argument |
Description |
Default |
|---|---|---|
|
API token; falls back to |
|
|
API endpoint; falls back to |
|
ms-agent agent upload -f qwenpaw -r user/my-agent
ms-agent agent download -f qwenpaw -r user/my-agent
ms-agent agent watch -f qwenpaw -r user/my-agent --pull
ms-agent agent convert --from-framework qoder --target-framework qwenpaw
upload β Upload local agent files to a remote repository#
Argument |
Description |
Default |
|---|---|---|
|
Agent framework (required) |
|
|
Remote repo identifier, supports |
|
|
Local agent name; auto-selected if only one exists, errors if multiple |
|
|
Override local workspace root (default: framework standard path) |
|
|
Visibility of the remote repo when created: |
|
|
List files that would be uploaded without uploading (flag) |
|
|
See shared credential options above |
|
download β Download agent files from a remote repository#
Argument |
Description |
Default |
|---|---|---|
|
Agent framework (required) |
|
|
Remote repo identifier, supports |
|
|
Local agent name to write as (default |
|
|
Override local workspace root (default: framework standard path) |
|
|
Convert to a different framework on download |
|
|
List files that would be written without writing (flag) |
|
|
See shared credential options above |
|
watch β Background sync#
Launch a background daemon that watches local changes and pushes to remote; with
--pull, also pulls remote changes to local (bidirectional sync).
Argument |
Description |
Default |
|---|---|---|
|
Agent framework (required) |
|
|
Remote repo identifier, supports |
|
|
Agent name to sync (default: ALL agents in the workspace) |
|
|
Override local workspace root (default: framework standard path) |
|
|
Enable bidirectional sync; pull remote changes to local (default: push-only, flag) |
|
|
See shared credential options above |
|
list β List remote agent repositories#
Query and display remote agent repositories with pagination.
Argument |
Description |
Default |
|---|---|---|
|
Filter by owner username or organization name |
|
|
Page number for pagination |
|
|
Number of items per page |
|
|
See shared credential options above |
|
status β Show local agent status#
Argument |
Description |
Default |
|---|---|---|
|
Agent framework (required) |
|
|
Override local workspace root (default: framework standard path) |
|
backups β List available backups#
Backups are named {framework}_{name}_{date}_{time}.zip.
Argument |
Description |
Default |
|---|---|---|
|
Filter backups by framework name prefix |
|
|
Filter backups by agent name (matches |
|
|
Override local workspace root |
|
restore β Restore from a backup#
Restore the workspace from a backup zip; the current state is backed up first.
Argument |
Description |
Default |
|---|---|---|
|
|
|
|
Filter backup candidates by framework (used with |
|
|
Filter backup candidates by agent name (used with |
|
|
Override the restore target directory |
|
convert β Local cross-framework conversion (offline)#
Convert agent workspace files from one framework format to another. Skips default template files with no custom content, and automatically backs up existing target files before writing.
Argument |
Description |
Default |
|---|---|---|
|
Source framework (required) |
|
|
Target framework (required) |
|
|
Source agent name to read (default |
|
|
Target agent name to write as (default: same as |
|
|
Source workspace root to read from (default: source framework path) |
|
|
Destination directory to write to (default: target framework path) |
|
|
Show what would be written without writing (flag) |
|
stop β Stop background sync#
No arguments. Gracefully stop the background watch daemon (cross-platform:
stop-file + SIGTERM).
ms-agent agent stop
plugin β Plugin Management#
Install and manage plugins. Format: ms-agent plugin <action> [<args>].
ms-agent plugin install ./my-plugin
ms-agent plugin install github://org/repo@main#subdir
ms-agent plugin list --json
install β Install a plugin#
Supports local paths, github://, modelscope://, and marketplace aliases.
Argument |
Description |
Default |
|---|---|---|
|
Plugin source (required, positional), e.g. |
|
|
Install scope: |
|
|
Project path for project-scoped install |
|
|
Symlink local plugin sources instead of copying (flag) |
|
|
Replace an existing managed plugin copy (flag) |
|
|
Install but keep the plugin disabled (flag) |
|
list β List installed plugins#
Argument |
Description |
Default |
|---|---|---|
|
Project path for merged plugin listing |
|
|
Print machine-readable JSON (flag) |
|
toggle β Enable/disable a plugin#
Argument |
Description |
Default |
|---|---|---|
|
Plugin id (required, positional) |
|
|
Enable the plugin (default action, flag) |
|
|
Disable the plugin (flag) |
|
|
Scope: |
|
|
Project path |
|
uninstall β Remove a plugin#
Argument |
Description |
Default |
|---|---|---|
|
Plugin id (required, positional) |
|
|
Scope: |
|
|
Delete managed plugin files (flag) |
|
|
Project path |
|
a2a β A2A Protocol Server#
Start an A2A (Agent-to-Agent) protocol HTTP server.
ms-agent a2a --config researcher.yaml --host 0.0.0.0 --port 5000
Argument |
Description |
Default |
|---|---|---|
|
Path to the agent config YAML (required) |
|
|
Path to a |
|
|
Trust external code referenced by the config |
|
|
Host to bind the A2A server |
|
|
Port to bind the A2A server |
|
|
Maximum concurrent A2A tasks |
|
|
Task inactivity timeout in seconds |
|
|
Write logs to this file instead of stderr |
|
a2a-registry β Generate an A2A Agent Card#
Generate an Agent Card JSON for agent discovery.
ms-agent a2a-registry --config researcher.yaml --output agent-card.json
Argument |
Description |
Default |
|---|---|---|
|
Path to agent config YAML (used for metadata extraction) |
|
|
Output path for the agent card |
|
|
Host the agent will be served on |
|
|
Port the agent will be served on |
|
|
Agent display title in the card |
|
acp β ACP Protocol Server#
Start an ACP (Agent Client Protocol) server, over stdio by default; with
--serve-http it starts a non-standard HTTP/SSE service API instead.
ms-agent acp --config researcher.yaml
ms-agent acp --config researcher.yaml --serve-http --host 0.0.0.0 --port 8080
Argument |
Description |
Default |
|---|---|---|
|
Path to the agent config YAML (required) |
|
|
Path to a |
|
|
Trust external code referenced by the config |
|
|
Maximum concurrent ACP sessions |
|
|
Session inactivity timeout in seconds |
|
|
Write logs to this file instead of stderr |
|
|
Start a non-standard HTTP/SSE service API instead of stdio (flag) |
|
|
HTTP host to bind (only with |
|
|
HTTP port to bind (only with |
|
|
API key for HTTP authentication (or set |
|
acp-proxy β ACP Proxy#
Start an ACP proxy that routes requests to multiple backend agents.
ms-agent acp-proxy --config proxy.yaml
Argument |
Description |
Default |
|---|---|---|
|
Path to the proxy config YAML (defines backends, required) |
|
|
Write logs to this file instead of stderr |
|
acp-registry β Generate an ACP Manifest#
Generate an agent.json manifest for the ACP Agent Registry.
ms-agent acp-registry --config researcher.yaml --output agent.json
Argument |
Description |
Default |
|---|---|---|
|
Path to agent config YAML (baked into manifest transport args) |
|
|
Output path for the manifest |
|
|
Agent display title in the manifest |
|