{% extends "dashboard/base.html" %} {% from "partials/_macros.html" import status_pill, relative_time, pill, empty_state, info_toggle %} {% from "partials/_list_chrome.html" import list_controls, list_pagination %} {% block page %} {% call info_toggle(key='workspaces', title="What is a workspace?") %}

A workspace is a repository (or a working-tree path) brains has registered. Sessions, tasks, decisions, handoffs, and patterns are all scoped to a workspace, so the dashboard's filters and the agent's memory stay focused on what's actually relevant.

Layer-2 memberships control who can see which workspace; pytest-fixture workspaces are hidden by default. Click a workspace name to see its full session history, open tasks, and pattern catalog.

{% endcall %} {{ list_controls( '/dashboard/workspaces', search_value=search_value, search_placeholder='Search slug or path…', filters=[ {'name': 'status', 'label': 'Status', 'value': status_filter, 'options': [('', 'All statuses'), ('active', 'active'), ('archived', 'archived'), ('retired', 'retired')]}, {'name': 'hide_test', 'label': 'Hide tests', 'value': '1' if hide_test else '0', 'options': [('1', 'Yes (hide pytest)'), ('0', 'No (show all)')]}, ], per_page=per_page, ) }}
{% if workspaces %} {% for w in workspaces %} {% endfor %}
SlugPathStatusLast touched
{{ icon('database') }} {{ w.slug }} {{ w.path }} {{ status_pill(w.status) }} {{ relative_time(w.last_touched_at) }}
{% else %} {{ empty_state( 'No workspaces match the current filter', body='Adjust the search term or status filter, or run `brains workspaces adopt ` to register a repo.', icon_name='database' ) }} {% endif %}
{{ list_pagination( '/dashboard/workspaces', page=page, per_page=per_page, total=total, search_value=search_value, filters=[ {'name': 'status', 'value': status_filter}, {'name': 'hide_test', 'value': '1' if hide_test else '0'}, ], shown=workspaces|length, ) }}
{{ icon('info') }}
Polluted by old test runs? Run brains workspaces prune --slug-prefix test- --slug-prefix adopt- --path-contains pytest --apply to clean up. Existing tests now write to a tmp DB so this won't recur.
{% endblock %}