Workspace and research management — dispatch analyses, monitor running agents, manage workspaces and threads.
Workflow patterns and operational details for the secretary tools. Basic tool signatures are in the tool descriptions — this covers what they don't.
These actions pause for user confirmation before executing:
manage_workspaces(action="create"|"delete"|"stop")ptc_agent(...) — always, before dispatchmanage_threads(action="delete")These run immediately (no approval):
manage_workspaces(action="list")manage_threads(action="list"|"get_output")agent_output(...)ptc_agent is asynchronous — it dispatches the question and returns immediately. The PTC agent runs in the background with full code execution, charts, and financial data tools.
Return: { success, workspace_id, thread_id, status: "dispatched", report_back }
workspace_id → auto-creates a new workspace (blocks ~8-10s for sandbox init)workspace_id → dispatches to existing workspace (new thread)thread_id → continues an existing conversation (overrides workspace_id)report_back=True (default) → when PTC completes, you'll automatically receive the results and should summarize them for the userreport_back=False → fire-and-forget; the user will check results in the workspace themselvesUse the returned thread_id with agent_output to check progress later (only needed when report_back=False).
Return: { text, status, thread_id, workspace_id }
status: "running" — analysis still in progress, text is partialstatus: "completed" — full output availablestatus: "error" — something went wrongWhen the user asks for a status overview, combine workspace and thread information:
manage_workspaces(action="list") to get workspace statesmanage_threads(action="list") to get recent thread activityptc_agent(question="...")agent_output(thread_id="...")When the user wants to follow up on a prior dispatch:
ptc_agent(question="...", thread_id="...") with the original thread_idWhen the user wants to tidy up:
manage_workspaces(action="list") to identify stale workspacesmanage_workspaces(action="stop", workspace_id="...")manage_workspaces(action="delete", workspace_id="...")