diff --git a/src/google/adk/cli/cli_tools_click.py b/src/google/adk/cli/cli_tools_click.py index ee59b5f..540f532 100644 --- a/src/google/adk/cli/cli_tools_click.py +++ b/src/google/adk/cli/cli_tools_click.py @@ -352,6 +352,11 @@ def cli_eval( default=False, help="Optional. Whether to enable cloud trace for telemetry.", ) +@click.option( + "--reload/--no-reload", + default=True, + help="Optional. Whether to enable auto reload for server.", +) @click.argument( "agents_dir", type=click.Path( @@ -367,6 +372,7 @@ def cli_web( allow_origins: Optional[list[str]] = None, port: int = 8000, trace_to_cloud: bool = False, + reload: bool = True, ): """Starts a FastAPI server with Web UI for agents. @@ -418,7 +424,7 @@ def cli_web( app, host="0.0.0.0", port=port, - reload=True, + reload=reload, ) server = uvicorn.Server(config) @@ -474,6 +480,11 @@ def cli_web( default=False, help="Optional. Whether to enable cloud trace for telemetry.", ) +@click.option( + "--reload/--no-reload", + default=True, + help="Optional. Whether to enable auto reload for server.", +) # The directory of agents, where each sub-directory is a single agent. # By default, it is the current working directory @click.argument( @@ -491,6 +502,7 @@ def cli_api_server( allow_origins: Optional[list[str]] = None, port: int = 8000, trace_to_cloud: bool = False, + reload: bool = True, ): """Starts a FastAPI server for agents. @@ -518,7 +530,7 @@ def cli_api_server( ), host="0.0.0.0", port=port, - reload=True, + reload=reload, ) server = uvicorn.Server(config) server.run()