Repository navigation
track every agent request by the task it was made for - #119
Merged
Merged
Conversation
Agents start a task with a title and a goal before anything else, give its id with every call, and finish it when done, over MCP (start_task and finish_task) and through the agent pages. The activity log keeps each request's task and shows it, with a view of one task's requests. The seed fills a workspace with tasks, for any user given by SEED_EMAIL.
Replaces the heatmap with a lane per agent and its tasks as bars along the time up to now: blue with a shimmer while a task runs, gray once done, orange where a request was refused, each with the services it used and its title where it fits. The window is chosen above the lanes or zoomed with the wheel, its end staying at now. A new lanes endpoint answers the tasks under way since a time with what was done for each, and the day-count summary goes with the heatmap. The seed gives each active agent several tasks at once.
…rom refused tasks, drop the day filter - a task open a day after it started is abandoned: off the lanes and the task page, and refused - a refused task (unknown, finished or abandoned) sends the agent pages to /agent/task - the task bar follows a switch made in another tab; bad JSON in storage is no task - feedback keeps the task id as given instead of refusing it - the lanes' zoom listens whenever the timeline is there - the agent, task and connection reads run at once - drop the activity log's ?day= filter and the from/to it used, and the graph's leftovers
…-tracking # Conflicts: # packages/api/src/mcp/route.test.ts # packages/docs/content/agents/mcp.mdx # packages/utils/package.json # packages/web/src/components/activity-graph.tsx # packages/web/src/components/agent-shell.tsx # packages/web/src/lib/activity-graph.test.ts # packages/web/src/pages/home-page.tsx
The task the agent pages are on is now the first part of their path, /agent/<task>/<connection>/<collection>/<record>, instead of kept in local storage. /agent lists the tasks to open or start, a task's pages read it once from GET /api/agent/tasks/:taskId, and a task the api refuses sends the agent back to /agent saying which. Each tab is on its own task, and back, reload and links keep it.
…sk and told the tool list changed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Before an agent does anything with Personal Agent Proxy it now starts a task, with a title and a goal summarizing what the person asked for, gives the task's id with every call it makes, and finishes the task when it is done. Over MCP that is two new tools,
start_taskandfinish_task, withtaskrequired onlist_connections,list_tools,readandrun; the agent web pages carry the task in their address,/agent/<task>/<connection>/<collection>/<record>:/agentlists the tasks to open or start, a task bar under the header names the one the pages are on, and every run is sent for it. An agent can have any number of tasks under way at once, each tab on its own. A task never finished is taken as abandoned a day after it started, and refused from then on.Every activity log entry keeps the task it was made for, so the person can see which request was in pursuit of which task. The activity page shows each row's task, the entry dialog shows the task's title and goal, and a task filter shows one task's requests with its status and timing.
Storage: a new
AgentTasktable and a nullabletaskIdon audit entries and feedback (migrationv021_add_agent_tasks); entries from before tasks and the proxy's own actions have none. The seed groups the demo activity into tasks and takesSEED_EMAILto fill another user's workspace, such as the dev user's. The screen map's crawl starts a task for its agent, and the MCP docs describe the seven tools and the task flow.Open workspace in Conductor