mirror of
https://github.com/microsoft/autogen.git
synced 2026-02-16 23:25:55 -05:00
v1 of AutoGen Studio on AgentChat (#4097)
* add skeleton worflow manager * add test notebook * update test nb * add sample team spec * refactor requirements to agentchat and ext * add base provider to return agentchat agents from json spec * initial api refactor, update dbmanager * api refactor * refactor tests * ags api tutorial update * ui refactor * general refactor * minor refactor updates * backend api refaactor * ui refactor and update * implement v1 for streaming connection with ui updates * backend refactor * ui refactor * minor ui tweak * minor refactor and tweaks * general refactor * update tests * sync uv.lock with main * uv lock update
This commit is contained in:
@@ -15,10 +15,11 @@ def ui(
|
||||
host: str = "127.0.0.1",
|
||||
port: int = 8081,
|
||||
workers: int = 1,
|
||||
reload: Annotated[bool, typer.Option("--reload")] = False,
|
||||
reload: Annotated[bool, typer.Option("--reload")] = True,
|
||||
docs: bool = True,
|
||||
appdir: str = None,
|
||||
database_uri: Optional[str] = None,
|
||||
upgrade_database: bool = False,
|
||||
):
|
||||
"""
|
||||
Run the AutoGen Studio UI.
|
||||
@@ -30,7 +31,7 @@ def ui(
|
||||
reload (bool, optional): Whether to reload the UI on code changes. Defaults to False.
|
||||
docs (bool, optional): Whether to generate API docs. Defaults to False.
|
||||
appdir (str, optional): Path to the AutoGen Studio app directory. Defaults to None.
|
||||
database-uri (str, optional): Database URI to connect to. Defaults to None. Examples include sqlite:///autogenstudio.db, postgresql://user:password@localhost/autogenstudio.
|
||||
database-uri (str, optional): Database URI to connect to. Defaults to None.
|
||||
"""
|
||||
|
||||
os.environ["AUTOGENSTUDIO_API_DOCS"] = str(docs)
|
||||
@@ -38,6 +39,8 @@ def ui(
|
||||
os.environ["AUTOGENSTUDIO_APPDIR"] = appdir
|
||||
if database_uri:
|
||||
os.environ["AUTOGENSTUDIO_DATABASE_URI"] = database_uri
|
||||
if upgrade_database:
|
||||
os.environ["AUTOGENSTUDIO_UPGRADE_DATABASE"] = "1"
|
||||
|
||||
uvicorn.run(
|
||||
"autogenstudio.web.app:app",
|
||||
@@ -45,6 +48,11 @@ def ui(
|
||||
port=port,
|
||||
workers=workers,
|
||||
reload=reload,
|
||||
reload_excludes=[
|
||||
"**/alembic/*",
|
||||
"**/alembic.ini",
|
||||
"**/versions/*"
|
||||
] if reload else None
|
||||
)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user