workspace_sessions
Check active sessions and recent file writes in your workspace to detect concurrent edits before modifying files.
Instructions
Returns same-workspace session awareness: who else is actively connected to this project and what files they recently edited.
you — this session's name.
active_sessions — sessions on this workspace right now (name, client, how long since their last tool call). A single entry whose is_self field is true means you are the only active session — your view of the workspace is authoritative. Multiple entries mean concurrent agents are working here; treat any file a peer recently touched as potentially changed.
recent_writes — the last N mutating operations (write_file, edit_file, rename_file, git commit, …) by all sessions on this workspace. The file path (when available), session name, operation, and age are shown. A successful git commit is attributed in full: its line carries the session name, the commit's short SHA and subject, and the repository, so a peer's commit is traceable to the session that authored it. When [collab] peer_awareness is on and the topology index has the file, each entry is annotated with its enclosing package/symbol (best-effort, source=topology).
Use this before editing a file that another session may have recently modified: if it appears in recent_writes, re-read it first.
Parameters: recent_limit — max recent-write entries to return (default 10, max 50).
Workspace boundary: workspace_sessions is scoped to the caller's pinned workspace; it never reveals sessions from a different project.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| recent_limit | No | Maximum recent-write entries to return (1–50; default 10). |