The ultimate harness for coding agents and beyond. All your agents. All your machines. One command center. Start with code, then follow your curiosity and build across disciplines: CAD, circuits, robots, games and music.
TypeScript 3d-modelingagent-frameworkagent-harnessai-agentscadclaude-codecodexcoding-agentsdeveloper-toolsesp32game-developmentmcp-servermulti-agentopen-hardwareopencodeopenharnesspcbroboticsterminaltmux
Simplify first use across every empty swarm
deee122b6318e6a
diff --git a/desktop/lib/screens/swarm_screen.dart b/desktop/lib/screens/swarm_screen.dartindex 71315eb5a..15f9e40a3 100644--- a/desktop/lib/screens/swarm_screen.dart+++ b/desktop/lib/screens/swarm_screen.dart@@ -35,6 +35,7 @@ import '../widgets/new_agent_dialog.dart';import '../widgets/pane_grid.dart';import '../widgets/shortcuts_sheet.dart';import '../widgets/swarm_dialogs.dart';+import '../widgets/clone_repository_dialog.dart';import '../widgets/swarm_inline_search.dart';import '../widgets/swarm_navigator.dart';import '../widgets/swarm_search_input.dart';@@ -508,10 +509,14 @@ class _SwarmScreenState extends State<SwarmScreen> {String? swarmId,PaneSplitRequest? split,bool chooseFolderFirst = false,+ bool cloneRepositoryFirst = false,}) => _dialog(() async {final focused = app.focusedPane;final inherit =- machineId == null && !chooseFolderFirst && focused?.agentId != null;+ machineId == null &&+ !chooseFolderFirst &&+ !cloneRepositoryFirst &&+ focused?.agentId != null;final focusedMachine = inherit? app.machineStates[focused!.machineId]: null;@@ -519,7 +524,12 @@ class _SwarmScreenState extends State<SwarmScreen> {.where((agent) => agent.id == focused?.agentId).firstOrNull;final local = app.machineStates.values- .where((m) => m.isLocalMachine)+ .where(+ (m) =>+ m.isLocalMachine &&+ (!(chooseFolderFirst || cloneRepositoryFirst) ||+ (!m.needsLink && m.nodeOnline != false)),+ ).firstOrNull;final id =machineId ??@@ -532,24 +542,42 @@ class _SwarmScreenState extends State<SwarmScreen> {}final targetId = swarmId ?? app.activeSwarmId;final machine = app.machineStates[id];+ if ((chooseFolderFirst || cloneRepositoryFirst) &&+ (machine == null ||+ !machine.isLocalMachine ||+ machine.needsLink ||+ machine.nodeOnline == false)) {+ ScaffoldMessenger.of(context).showSnackBar(+ const SnackBar(+ content: Text(+ 'This computer is unavailable. Reconnect and try again.',+ ),+ ),+ );+ return;+ }var selectedFolder =folder ??(focusedAgent == null? null: focusedMachine?.projectOf(focusedAgent)?.cwd);Future<void>? initialEngineProbe;- if (chooseFolderFirst && machine != null && machine.isLocalMachine) {+ if ((chooseFolderFirst || cloneRepositoryFirst) &&+ machine != null &&+ machine.isLocalMachine) {// Read availability while the user chooses a folder, so the form can// prefer an installed agent without adding a second probe or wait.initialEngineProbe = app.probeEngines(id, force: true);try {- selectedFolder = await getDirectoryPath(- confirmButtonText: 'Use folder',- );+ selectedFolder = cloneRepositoryFirst+ ? await showCloneRepositoryDialog(context)+ : await getDirectoryPath(confirmButtonText: 'Use folder');} catch (error) {if (mounted) {ScaffoldMessenger.of(context).showSnackBar(- SnackBar(content: Text('Could not open the folder picker: $error')),+ SnackBar(+ content: Text('Could not choose a working folder: $error'),+ ),);}return;@@ -568,7 +596,11 @@ class _SwarmScreenState extends State<SwarmScreen> {context,app,id,- source: chooseFolderFirst ? 'first_folder' : 'swarm',+ source: cloneRepositoryFirst+ ? 'first_clone'+ : chooseFolderFirst+ ? 'first_folder'+ : 'swarm',initialFolder: selectedFolder,initialEngineProbe: initialEngineProbe,swarmId: targetId,@@ -1229,6 +1261,8 @@ class _SwarmScreenState extends State<SwarmScreen> {onNewAgent: _newAgent,onChooseFirstFolder: () =>_newAgent(chooseFolderFirst: true),+ onCloneRepository: () =>+ _newAgent(cloneRepositoryFirst: true),onAgent: (entry) => _activateSearch(SwarmSearchSelection(SwarmDestination(diff --git a/desktop/lib/widgets/new_agent_dialog.dart b/desktop/lib/widgets/new_agent_dialog.dartindex 37fbd846a..5f501f139 100644--- a/desktop/lib/widgets/new_agent_dialog.dart+++ b/desktop/lib/widgets/new_agent_dialog.dart@@ -55,7 +55,6 @@ Future<void> showNewAgentDialog(context: context,transitionDuration: Duration.zero,veilBlur: 0,- veilTint: const Color(0x66000000),builder: (context) => _NewAgentDialog(notifier: notifier,machineId: machineId,@@ -527,37 +526,42 @@ class _NewAgentDialogState extends State<_NewAgentDialog> {mainAxisSize: MainAxisSize.min,crossAxisAlignment: CrossAxisAlignment.start,children: [- const FieldLabel('Machine'),- AppSelectField<String>(- key: const Key('new-agent-machine-field'),- value: _machineId,- options: [- for (final machine in widget.notifier.machineStates.values)- SelectOption(- value: machine.machine.machineId,- label: machine.isLocalMachine- ? 'This computer'- : machine.machine.displayName,- note: machine.nodeOnline == false- ? 'Offline'- : machine.needsLink- ? 'Link required'- : null,- ),- ],- onChanged: (id) {- setState(() {- _machineRevision++;- _machineId = id;- _folder = null;- _codexProfile = null;- _codexProfilesBusy = true;- _error = null;- });- unawaited(_probeEngines());- },- ),- const SizedBox(height: _gapField),+ if (widget.notifier.machineStates.length != 1 ||+ !_machineIsThisComputer ||+ widget.notifier.machineStates[_machineId]?.nodeOnline == false ||+ widget.notifier.machineStates[_machineId]?.needsLink == true) ...[+ const FieldLabel('Machine'),+ AppSelectField<String>(+ key: const Key('new-agent-machine-field'),+ value: _machineId,+ options: [+ for (final machine in widget.notifier.machineStates.values)+ SelectOption(+ value: machine.machine.machineId,+ label: machine.isLocalMachine+ ? 'This computer'+ : machine.machine.displayName,+ note: machine.nodeOnline == false+ ? 'Offline'+ : machine.needsLink+ ? 'Link required'+ : null,+ ),+ ],+ onChanged: (id) {+ setState(() {+ _machineRevision++;+ _machineId = id;+ _folder = null;+ _codexProfile = null;+ _codexProfilesBusy = true;+ _error = null;+ });+ unawaited(_probeEngines());+ },+ ),+ const SizedBox(height: _gapField),+ ],Row(children: [const Expanded(child: FieldLabel('Working folder')),diff --git a/desktop/lib/widgets/swarm_welcome.dart b/desktop/lib/widgets/swarm_welcome.dartindex df6e19b8b..3e1e68dc7 100644--- a/desktop/lib/widgets/swarm_welcome.dart+++ b/desktop/lib/widgets/swarm_welcome.dart@@ -1,5 +1,3 @@-import 'dart:ui' show ImageFilter;-import 'package:flutter/material.dart';import 'package:flutter/services.dart';@@ -9,8 +7,9 @@ import '../state/app_state.dart';import '../state/swarm_catalog.dart';import 'engine_identity.dart';import 'swarm_icon.dart';+import 'welcome_workspace_preview.dart';-class SwarmWelcome extends StatelessWidget {+class SwarmWelcome extends StatefulWidget {const SwarmWelcome({super.key,required this.notifier,@@ -22,49 +21,65 @@ class SwarmWelcome extends StatelessWidget {required this.onMachine,required this.onProject,this.onChooseFirstFolder,+ this.onCloneRepository,this.onAgent,this.onProjectAgents,});+final AppNotifier notifier;final List<SavedSwarmProject> projects;- final VoidCallback onNewAgent;- final VoidCallback? onChooseFirstFolder;+ final VoidCallback onNewAgent, onAddProject, onLinkMachine;+ final VoidCallback? onChooseFirstFolder, onCloneRepository;final Widget searchField;- final VoidCallback onAddProject;- final VoidCallback onLinkMachine;final ValueChanged<MachineState> onMachine;final ValueChanged<SwarmProjectGroup> onProject;final ValueChanged<SwarmAgentRef>? onAgent;final ValueChanged<SwarmProjectGroup>? onProjectAgents;++ @override+ State<SwarmWelcome> createState() => _SwarmWelcomeState();+}++/// Every empty swarm uses this start surface. Available work, not whether the+/// user has visited another tab, determines the useful next action.+class _SwarmWelcomeState extends State<SwarmWelcome> {+ bool _catalogOpen = false;+ bool _reconnecting = false;++ Future<void> _reconnect() async {+ if (_reconnecting) return;+ setState(() => _reconnecting = true);+ try {+ await widget.notifier.retryMachines();+ } finally {+ if (mounted) setState(() => _reconnecting = false);+ }+ }+@overrideWidget build(BuildContext context) {grid.AppTheme.watch(context);- final app = notifier;- final groups = swarmProjects(app, projects);- // Every empty swarm offers the same actions. Available inventory can change- // its guidance; whether another swarm was used must not change the product.- final agents = swarmAgents(app);- final noAgents =- !app.machinesLoading &&- agents.isEmpty &&- groups.isEmpty &&- app.machineStates.length == 1 &&- app.machineStates.values.first.isLocalMachine &&- app.machineStates.values.first.agentLoadStatus ==- AgentLoadStatus.loaded &&- app.machineStates.values.first.nodeOnline != false &&- !app.machineStates.values.first.needsLink;- final chooseFirstFolder = noAgents && onChooseFirstFolder != null;- final readyAgents =- agents+ final textScale = MediaQuery.textScalerOf(context).scale(14) / 14;+ final app = widget.notifier;+ final groups = swarmProjects(app, widget.projects);+ bool ready(MachineState machine) =>+ !machine.needsLink && machine.nodeOnline != false;+ final retained = {+ for (final pane in app.allPanes)+ if (pane.agentId != null) (pane.machineId, pane.agentId!),+ };+ final agents =+ swarmAgents(app).where((entry) =>- !entry.machine.needsLink &&- entry.machine.nodeOnline != false &&- entry.agent.terminalAvailable,+ entry.agent.terminalAvailable ||+ retained.contains((entry.machineId, entry.agent.id)),).toList()..sort((a, b) {+ final available =+ (ready(b.machine) ? 1 : 0) - (ready(a.machine) ? 1 : 0);+ if (available != 0) return available;if (a.machine.isLocalMachine != b.machine.isLocalMachine) {return a.machine.isLocalMachine ? -1 : 1;}@@ -72,225 +87,386 @@ class SwarmWelcome extends StatelessWidget {b.agent.name.toLowerCase(),);});- return Stack(- fit: StackFit.expand,+ final existing =+ (agents.isNotEmpty || retained.isNotEmpty) && widget.onAgent != null;+ final local = app.machineStates.values+ .where((machine) => machine.isLocalMachine && ready(machine))+ .firstOrNull;+ final canCreate = app.machineStates.values.any(ready);+ final finding =+ _reconnecting ||+ app.machinesLoading ||+ app.machineStates.values.any(+ (machine) =>+ ready(machine) &&+ (machine.agentLoadStatus == AgentLoadStatus.idle ||+ machine.agentLoadStatus == AgentLoadStatus.loading),+ );+ final needsLink =+ app.machineStates.isEmpty ||+ app.machineStates.values.every((machine) => machine.needsLink);+ final chooseFolder =+ !existing && local != null && widget.onChooseFirstFolder != null;+ final saved = groups.where((group) => group.saved != null).toList();+ final waiting = !canCreate && finding;++ final primary = KeyedSubtree(+ // Discovery can finish after the first autofocus attempt. Give the+ // newly enabled action its first attempt in the welcome's own scope;+ // an explicit focus elsewhere in that scope still takes precedence.+ key: ValueKey(waiting),+ child: FilledButton.icon(+ key: const ValueKey('swarm-start-primary'),+ autofocus: !existing && !waiting,+ onPressed: chooseFolder+ ? widget.onChooseFirstFolder+ : canCreate+ ? widget.onNewAgent+ : finding+ ? null+ : needsLink+ ? widget.onLinkMachine+ : _reconnect,+ icon: Icon(+ chooseFolder+ ? Icons.folder_open_outlined+ : canCreate+ ? Icons.add+ : Icons.computer_outlined,+ size: 18,+ ),+ label: Text(+ chooseFolder+ ? 'Choose folder…'+ : canCreate+ ? 'New agent'+ : finding+ ? 'Finding your computers…'+ : needsLink+ ? 'Link a machine'+ : 'Reconnect',+ ),+ style: FilledButton.styleFrom(+ minimumSize: const Size(140, 44),+ backgroundColor: grid.AppPalette.swarmAccent,+ foregroundColor: grid.AppPalette.swarmTabBar,+ ),+ ),+ );++ Widget intro() => Column(+ crossAxisAlignment: CrossAxisAlignment.start,children: [- LayoutBuilder(- builder: (context, constraints) => SingleChildScrollView(- child: ConstrainedBox(- constraints: BoxConstraints(minHeight: constraints.maxHeight),- child: Center(- child: Container(- constraints: const BoxConstraints(maxWidth: 1000),- padding: const EdgeInsets.fromLTRB(56, 40, 56, 62),- child: Column(- mainAxisSize: MainAxisSize.min,- crossAxisAlignment: CrossAxisAlignment.start,- children: [- Text(- noAgents ? 'Start with one agent' : 'Start a swarm',- style: const TextStyle(- fontSize: 32,- fontWeight: FontWeight.w500,- letterSpacing: -0.7,- color: Colors.white,- shadows: [- Shadow(blurRadius: 16, color: Colors.black54),- ],- ),- ),- const SizedBox(height: 10),- Text(- noAgents- ? 'Choose a project folder and an agent. Add more whenever you want to work side by side.'- : 'Bring existing agents together, or start a new one. Work with them side by side in this tab.',- style: const TextStyle(- fontSize: 13,- color: Color(0xffe0dce3),- ),- ),- const SizedBox(height: 28),- Row(- children: [- Expanded(child: searchField),- const SizedBox(width: 12),- FilledButton.icon(- onPressed: chooseFirstFolder- ? onChooseFirstFolder- : onNewAgent,- icon: Icon(- chooseFirstFolder- ? Icons.folder_open_outlined- : Icons.add,- size: 17,- ),- label: Text(- chooseFirstFolder- ? 'Choose folder…'- : 'New agent',- ),- style: FilledButton.styleFrom(- minimumSize: const Size(126, 44),- backgroundColor: grid.AppPalette.swarmAccent,- foregroundColor: grid.AppPalette.swarmTabBar,- ),- ),- ],+ Text(+ existing ? 'Start a swarm' : 'Start with one agent',+ style: const TextStyle(+ fontSize: 32,+ height: 1.15,+ fontWeight: FontWeight.w600,+ letterSpacing: -.7,+ color: Colors.white,+ ),+ ),+ const SizedBox(height: 12),+ Text(+ existing+ ? 'Add existing agents or start a new one. Keep their work side by side in this tab.'+ : 'Work with Codex, Claude Code, and other agents side by side. Start in a folder you already use.',+ style: const TextStyle(+ fontSize: 14,+ height: 1.55,+ color: Colors.white70,+ ),+ ),+ if (!existing) ...[+ const SizedBox(height: 24),+ Wrap(+ spacing: 12,+ runSpacing: 8,+ crossAxisAlignment: WrapCrossAlignment.center,+ children: [+ primary,+ if (local != null && widget.onCloneRepository != null)+ TextButton(+ key: const ValueKey('swarm-start-clone'),+ onPressed: widget.onCloneRepository,+ style: TextButton.styleFrom(foregroundColor: Colors.white70),+ child: const Text('Clone repository…'),+ ),+ ],+ ),+ const SizedBox(height: 12),+ Text(+ canCreate+ ? 'Choose a folder → Pick an agent → Give it a task'+ : finding+ ? 'Looking for your computers and existing agents…'+ : needsLink+ ? 'Connect a computer to start or bring in existing work.'+ : 'Your computers are offline. Reconnect to load your agents.',+ style: const TextStyle(+ fontSize: 12,+ height: 1.5,+ color: Colors.white60,+ ),+ ),+ ],+ ],+ );++ const example = Column(+ crossAxisAlignment: CrossAxisAlignment.start,+ children: [+ Text(+ 'Work side by side · Example',+ style: TextStyle(+ fontSize: 12,+ fontWeight: FontWeight.w600,+ color: Colors.white70,+ ),+ ),+ SizedBox(height: 10),+ WelcomeWorkspacePreview(),+ SizedBox(height: 10),+ Text(+ 'A swarm is a tab of agents. Use + to add another when you’re ready.',+ style: TextStyle(fontSize: 12, height: 1.5, color: Colors.white60),+ ),+ ],+ );++ return FocusScope(+ child: LayoutBuilder(+ builder: (context, constraints) => SingleChildScrollView(+ child: ConstrainedBox(+ constraints: BoxConstraints(minHeight: constraints.maxHeight),+ child: Center(+ child: Container(+ constraints: const BoxConstraints(maxWidth: 1040),+ padding: EdgeInsets.fromLTRB(+ constraints.maxWidth < 700 ? 24 : 48,+ 36,+ constraints.maxWidth < 700 ? 24 : 48,+ 70,+ ),+ child: Column(+ mainAxisSize: MainAxisSize.min,+ crossAxisAlignment: CrossAxisAlignment.start,+ children: [+ if (existing) ...[+ intro(),+ const SizedBox(height: 24),+ LayoutBuilder(+ builder: (context, size) =>+ size.maxWidth < 620 * textScale+ ? Column(+ crossAxisAlignment: CrossAxisAlignment.start,+ children: [+ widget.searchField,+ const SizedBox(height: 12),+ primary,+ ],+ )+ : Row(+ children: [+ Expanded(child: widget.searchField),+ const SizedBox(width: 12),+ primary,+ ],+ ),),- const SizedBox(height: 34),- if (noAgents)- _Glass(- child: _FirstAgentGuide(onLinkMachine: onLinkMachine),- )- else ...[- if (onAgent != null && readyAgents.isNotEmpty) ...[- _Glass(- child: Column(- crossAxisAlignment: CrossAxisAlignment.start,- children: [- const Text(+ const SizedBox(height: 18),+ if (agents.isNotEmpty)+ _Surface(+ child: Column(+ crossAxisAlignment: CrossAxisAlignment.start,+ children: [+ const Padding(+ padding: EdgeInsets.fromLTRB(12, 8, 12, 4),+ child: Text('Add an existing agent',style: TextStyle(fontSize: 13,fontWeight: FontWeight.w600,),),- const SizedBox(height: 8),- for (final entry in readyAgents.take(3))- ListTile(- key: ValueKey(- 'welcome-agent:${entry.machineId}:${entry.agent.id}',- ),- contentPadding: const EdgeInsets.symmetric(- horizontal: 4,- ),- leading: EngineMark(- engine: entry.agent.engine,- size: 22,- ),- title: Text(- entry.agent.name,- maxLines: 1,- overflow: TextOverflow.ellipsis,- style: const TextStyle(fontSize: 13),- ),- subtitle: Text(- [- entry.machine.machine.displayName,- entry.project?.name,- ].whereType<String>().join(' · '),- maxLines: 1,- overflow: TextOverflow.ellipsis,- style: const TextStyle(- fontSize: 12,- color: Colors.white70,- ),+ ),+ for (final entry in agents.take(3))+ ListTile(+ key: ValueKey(+ 'welcome-agent:${entry.machineId}:${entry.agent.id}',+ ),+ leading: EngineMark(+ engine: entry.agent.engine,+ size: 22,+ ),+ title: Text(+ entry.agent.name,+ maxLines: 1,+ overflow: TextOverflow.ellipsis,+ style: const TextStyle(fontSize: 14),+ ),+ subtitle: Text(+ [+ entry.machine.machine.displayName,+ entry.project?.name,+ if (!ready(entry.machine))+ entry.machine.needsLink+ ? 'Link required'+ : 'Offline',+ ].whereType<String>().join(' · '),+ maxLines: 1,+ overflow: TextOverflow.ellipsis,+ style: const TextStyle(+ fontSize: 12,+ color: Colors.white60,),- onTap: () => onAgent!(entry),),- ],- ),+ trailing: const Icon(+ Icons.add,+ size: 17,+ color: Colors.white60,+ ),+ onTap: () => widget.onAgent!(entry),+ ),+ ],),- const SizedBox(height: 18),- ],- _Glass(- child: LayoutBuilder(- builder: (context, size) {- final machines = _section(- 'Machines',- 'Link machine',- onLinkMachine,- [- if (app.machinesLoading &&- app.machineStates.isEmpty)- const SkeletonList(rows: 3),- for (final machine- in app.machineStates.values)- _StarterRow(- name: machine.machine.displayName,- note: machine.needsLink- ? 'Link required'- : machine.nodeOnline == false- ? 'Offline'- : machine.isLocalMachine- ? 'Local'- : null,- count: machine.agents.length,- onTap: () => onMachine(machine),- ),- if (!app.machinesLoading &&- app.machineStates.isEmpty)- const Padding(- padding: EdgeInsets.symmetric(- vertical: 18,- ),- child: Text(- 'Link a machine to find its agents.',- ),- ),+ ),+ ] else+ LayoutBuilder(+ builder: (context, size) =>+ size.maxWidth >= 720 * textScale+ ? Row(+ children: [+ Expanded(flex: 6, child: intro()),+ const SizedBox(width: 40),+ const Expanded(flex: 5, child: example),],- );- final projects = _section(- 'Projects',- 'Add project',- onAddProject,- [- for (final group in groups)- _StarterRow(- name: group.name,- count: group.agents.length,- onTap: () => onProject(group),- onManage: onProjectAgents == null- ? null- : () => onProjectAgents!(group),- ),- if (groups.isEmpty)- const Padding(- padding: EdgeInsets.symmetric(- vertical: 18,- ),- child: Text(- 'Add a working folder to start a project.',- style: TextStyle(- color: Color(0xffc5bece),- fontSize: 12,- ),- ),- ),+ )+ : Column(+ crossAxisAlignment: CrossAxisAlignment.start,+ children: [+ intro(),+ const SizedBox(height: 24),+ example,],- );- return size.maxWidth < 570- ? Column(- children: [- machines,- const SizedBox(height: 24),- projects,- ],- )- : Row(- crossAxisAlignment:- CrossAxisAlignment.start,- children: [- Expanded(child: machines),- const SizedBox(width: 36),- Expanded(child: projects),- ],- );- },- ),+ ),+ ),+ if (saved.isNotEmpty && !_catalogOpen) ...[+ const SizedBox(height: 24),+ _Surface(+ child: _section(+ 'Projects',+ 'Add project',+ widget.onAddProject,+ [for (final group in saved) _project(group)],),- ],+ ),],- ),+ const SizedBox(height: 20),+ Semantics(+ expanded: _catalogOpen,+ child: TextButton.icon(+ key: const ValueKey('swarm-start-browse'),+ onPressed: () =>+ setState(() => _catalogOpen = !_catalogOpen),+ icon: Icon(+ _catalogOpen ? Icons.expand_less : Icons.expand_more,+ size: 18,+ ),+ label: const Text('Browse machines and projects'),+ style: TextButton.styleFrom(+ foregroundColor: Colors.white70,+ ),+ ),+ ),+ if (_catalogOpen) ...[+ const SizedBox(height: 12),+ _catalog(app, groups),+ ],+ ],),),),),),- ],+ ),);}+ Widget _project(SwarmProjectGroup group) => _StarterRow(+ name: group.name,+ count: group.agents.length,+ onTap: () => widget.onProject(group),+ onManage: widget.onProjectAgents == null+ ? null+ : () => widget.onProjectAgents!(group),+ );++ Widget _catalog(AppNotifier app, List<SwarmProjectGroup> groups) => _Surface(+ child: LayoutBuilder(+ builder: (context, size) {+ final machines = _section(+ 'Machines',+ 'Link machine',+ widget.onLinkMachine,+ [+ if (app.machinesLoading && app.machineStates.isEmpty)+ const SkeletonList(rows: 3),+ for (final machine in app.machineStates.values)+ _StarterRow(+ name: machine.machine.displayName,+ note: machine.needsLink+ ? 'Link required'+ : machine.nodeOnline == false+ ? 'Offline'+ : machine.isLocalMachine+ ? 'This computer'+ : null,+ count: machine.agents.length,+ onTap: () => widget.onMachine(machine),+ ),+ if (!app.machinesLoading && app.machineStates.isEmpty)+ const Padding(+ padding: EdgeInsets.all(12),+ child: Text(+ 'Link a computer to find its agents.',+ style: TextStyle(fontSize: 12, color: Colors.white60),+ ),+ ),+ ],+ );+ final projects = _section(+ 'Projects',+ 'Add project',+ widget.onAddProject,+ [+ for (final group in groups) _project(group),+ if (groups.isEmpty)+ const Padding(+ padding: EdgeInsets.all(12),+ child: Text(+ 'Save a working folder for quick access.',+ style: TextStyle(fontSize: 12, color: Colors.white60),+ ),+ ),+ ],+ );+ final textScale = MediaQuery.textScalerOf(context).scale(14) / 14;+ return size.maxWidth < 570 * textScale+ ? Column(children: [machines, const SizedBox(height: 24), projects])+ : Row(+ crossAxisAlignment: CrossAxisAlignment.start,+ children: [+ Expanded(child: machines),+ const SizedBox(width: 28),+ Expanded(child: projects),+ ],+ );+ },+ ),+ );+Widget _section(String title,String action,@@ -299,98 +475,30 @@ class SwarmWelcome extends StatelessWidget {) => Column(crossAxisAlignment: CrossAxisAlignment.start,children: [- Row(- children: [- Text(- title,- style: const TextStyle(fontSize: 13, fontWeight: FontWeight.w600),- ),- const Spacer(),- TextButton(- onPressed: onAction,- style: TextButton.styleFrom(foregroundColor: Colors.white70),- child: Text(action, style: const TextStyle(fontSize: 11)),- ),- ],- ),- const SizedBox(height: 8),- ...children,- ],- );-}--class _FirstAgentGuide extends StatelessWidget {- const _FirstAgentGuide({required this.onLinkMachine});- final VoidCallback onLinkMachine;-- @override- Widget build(BuildContext context) => Column(- crossAxisAlignment: CrossAxisAlignment.start,- children: [- const Text(- 'Your first workspace',- style: TextStyle(fontSize: 14, fontWeight: FontWeight.w500),- ),- const SizedBox(height: 16),- for (final (number, title, detail) in const [- ('1', 'Choose a folder', 'Use a project you already work on.'),- ('2', 'Pick your agent', 'Claude Code, Codex, or another agent.'),- (- '3',- 'Start working',- 'Your agent opens here. Sign in if needed, then give it a task.',- ),- ])- Padding(- padding: const EdgeInsets.only(bottom: 14),- child: Row(- children: [- Container(- width: 28,- height: 28,- alignment: Alignment.center,- decoration: const BoxDecoration(- color: Colors.white10,- shape: BoxShape.circle,- ),- child: Text(- number,- style: const TextStyle(fontSize: 12, color: Colors.white70),- ),- ),- const SizedBox(width: 12),- Expanded(- child: Column(- crossAxisAlignment: CrossAxisAlignment.start,- children: [- Text(- title,- style: const TextStyle(- fontSize: 13,- fontWeight: FontWeight.w500,- ),- ),- const SizedBox(height: 2),- Text(- detail,- style: const TextStyle(- fontSize: 12,- color: Colors.white70,- ),- ),- ],+ Padding(+ padding: const EdgeInsets.symmetric(horizontal: 12),+ child: Row(+ children: [+ Expanded(+ child: Text(+ title,+ maxLines: 1,+ overflow: TextOverflow.ellipsis,+ style: const TextStyle(+ fontSize: 13,+ fontWeight: FontWeight.w600,),),- ],- ),- ),- TextButton(- onPressed: onLinkMachine,- child: const Text(- 'Link another machine',- style: TextStyle(color: Colors.white70),+ ),+ TextButton(+ onPressed: onAction,+ style: TextButton.styleFrom(foregroundColor: Colors.white70),+ child: Text(action, style: const TextStyle(fontSize: 12)),+ ),+ ],),),+ ...children,],);}@@ -576,23 +684,17 @@ class _StarterRow extends StatelessWidget {);}-class _Glass extends StatelessWidget {- const _Glass({required this.child});+class _Surface extends StatelessWidget {+ const _Surface({required this.child});final Widget child;@override- Widget build(BuildContext context) => ClipRRect(- borderRadius: BorderRadius.circular(14),- child: BackdropFilter(- filter: ImageFilter.blur(sigmaX: 18, sigmaY: 18),- child: Container(- padding: const EdgeInsets.all(24),- decoration: BoxDecoration(- color: const Color(0x80111522),- border: Border.all(color: Colors.white12),- borderRadius: BorderRadius.circular(14),- ),- child: Material(type: MaterialType.transparency, child: child),- ),+ Widget build(BuildContext context) => Container(+ padding: const EdgeInsets.all(8),+ decoration: BoxDecoration(+ color: grid.AppPalette.swarmSearchSurface.withValues(alpha: .94),+ borderRadius: BorderRadius.circular(12),+ border: Border.all(color: Colors.white12),),+ child: Material(type: MaterialType.transparency, child: child),);}diff --git a/desktop/test/boot_flow_widget_test.dart b/desktop/test/boot_flow_widget_test.dartindex e9a8c62b7..2b57832d5 100644--- a/desktop/test/boot_flow_widget_test.dart+++ b/desktop/test/boot_flow_widget_test.dart@@ -829,10 +829,10 @@ void main() {),);await tester.pumpAndSettle();- expect(find.text('Start a swarm'), findsOneWidget);- expect(find.text('New agent'), findsOneWidget);- expect(find.text('Add project'), findsOneWidget);- await tester.tap(find.text('Link machine'));+ expect(find.text('Start with one agent'), findsOneWidget);+ expect(find.text('New agent'), findsNothing);+ expect(find.text('Add project'), findsNothing);+ await tester.tap(find.text('Link a machine'));await tester.pumpAndSettle();expect(find.text('harness login\nharness start'), findsOneWidget);await tester.tap(find.text('Done'));@@ -1080,6 +1080,9 @@ void main() {await tester.pump();expect(find.text('Link this machine'), findsNothing);+ await tester.tap(find.byKey(const ValueKey('swarm-start-browse')));+ await tester.pump();+ await tester.ensureVisible(find.text('link-mac'));await tester.tap(find.text('link-mac'));// Same popup-transition reasoning as above.await tester.pumpAndSettle();@@ -1157,6 +1160,9 @@ void main() {await tester.pump();expect(find.text('Link this machine'), findsNothing);+ await tester.tap(find.byKey(const ValueKey('swarm-start-browse')));+ await tester.pump();+ await tester.ensureVisible(find.text('link-mac'));await tester.tap(find.text('link-mac'));await tester.pumpAndSettle();diff --git a/desktop/test/first_workspace_test.dart b/desktop/test/first_workspace_test.dartindex fe98367b0..2ed4fae9b 100644--- a/desktop/test/first_workspace_test.dart+++ b/desktop/test/first_workspace_test.dart@@ -11,7 +11,9 @@ import 'package:harness/core/models.dart';import 'package:harness/shared/widgets/app_select_field.dart';import 'package:harness/state/app_state.dart';import 'package:harness/state/pane_arrangement.dart';+import 'package:harness/state/swarm_catalog.dart';import 'package:harness/terminal/terminal_binary.dart';+import 'package:harness/widgets/clone_repository_dialog.dart';import 'package:xterm/xterm.dart';import 'swarm_screen_test.dart' show mount, terminal;@@ -41,11 +43,19 @@ class _FirstUseApp extends AppNotifier {Completer<void>? probe;var probes = 0;+ Completer<void>? reconnect;+ var reconnects = 0;Completer<String?>? creation;final launches =<({String machine, String engine, String folder, bool bypass})>[];final input = <TerminalBinaryFrame>[];+ @override+ Future<void> retryMachines() async {+ reconnects++;+ await reconnect?.future;+ }+@overrideFuture<void> probeEngines(String machineId, {bool force = false}) async {probes++;@@ -93,6 +103,178 @@ class _FolderPicker extends FileSelectorPlatform {}void main() {+ testWidgets('a saved empty project stays visible and starts in its folder', (+ tester,+ ) async {+ final app = _FirstUseApp();+ final projects = SwarmProjectStore();+ await projects.add(+ const SavedSwarmProject(+ machineId: 'm',+ path: '/work/saved-project',+ name: 'Saved project',+ ),+ );+ await mount(tester, app, projects: projects);+ expect(find.text('Machines'), findsNothing);+ expect(find.text('Saved project'), findsOneWidget);+ await tester.tap(find.text('Saved project'));+ await tester.pump();+ expect(find.byType(AlertDialog), findsOneWidget);+ expect(find.text('/work/saved-project'), findsOneWidget);+ expect(app.launches, isEmpty);+ await tester.tap(find.text('Cancel'));+ await tester.pump();+ app.newSwarm();+ await tester.pump();+ expect(find.text('Saved project'), findsOneWidget);+ expect(find.text('Machines'), findsNothing);+ await tester.pumpWidget(const SizedBox());+ projects.dispose();+ app.dispose();+ });++ testWidgets('first discovery enables the folder action for Enter', (+ tester,+ ) async {+ final app = _FirstUseApp();+ final local = app.machineStates.remove('m')!;+ app.machinesLoading = true;+ final oldPicker = FileSelectorPlatform.instance;+ final picker = _FolderPicker();+ FileSelectorPlatform.instance = picker;+ addTearDown(() => FileSelectorPlatform.instance = oldPicker);+ await mount(tester, app);+ expect(find.text('Finding your computers…'), findsOneWidget);+ await tester.sendKeyEvent(LogicalKeyboardKey.enter);+ await tester.pump();+ expect(picker.opened, 0);+ app.machineStates['m'] = local;+ app.machinesLoading = false;+ app.dismissError();+ await tester.pump();+ expect(find.text('Choose folder…'), findsOneWidget);+ await tester.sendKeyEvent(LogicalKeyboardKey.enter);+ await tester.pump();+ expect(picker.opened, 1);+ expect(find.byType(AlertDialog), findsOneWidget);+ expect(find.text('/work/my-project'), findsOneWidget);+ expect(app.launches, isEmpty);+ await tester.tap(find.text('Cancel'));+ await tester.pumpWidget(const SizedBox());+ app.dispose();+ });++ testWidgets('offline start retries once and retains its empty swarm', (+ tester,+ ) async {+ final app = _FirstUseApp()..reconnect = Completer<void>();+ app.machineStates['m']!.nodeOnline = false;+ final original = app.activeSwarm;+ await mount(tester, app);+ expect(find.text('Reconnect'), findsOneWidget);+ await tester.sendKeyEvent(LogicalKeyboardKey.enter);+ await tester.pump();+ expect(find.text('Finding your computers…'), findsOneWidget);+ await tester.sendKeyEvent(LogicalKeyboardKey.enter);+ await tester.pump();+ expect(app.reconnects, 1);+ expect(app.launches, isEmpty);+ expect(app.activeSwarm, same(original));+ app.reconnect!.complete();+ await tester.pumpAndSettle();+ expect(find.text('Reconnect'), findsOneWidget);+ await tester.pumpWidget(const SizedBox());+ app.dispose();+ });++ testWidgets('discovery preserves an explicit focus on browsing', (+ tester,+ ) async {+ final app = _FirstUseApp();+ final local = app.machineStates.remove('m')!;+ app.machinesLoading = true;+ await mount(tester, app);+ final browsing = find.text('Browse machines and projects');+ final focus = Focus.of(tester.element(browsing));+ focus.requestFocus();+ await tester.pump();+ expect(focus.hasPrimaryFocus, isTrue);+ app.machineStates['m'] = local;+ app.machinesLoading = false;+ app.dismissError();+ await tester.pump();+ expect(focus.hasPrimaryFocus, isTrue);+ await tester.sendKeyEvent(LogicalKeyboardKey.enter);+ await tester.pump();+ expect(find.text('Machines'), findsOneWidget);+ expect(find.byType(AlertDialog), findsNothing);+ expect(app.launches, isEmpty);+ await tester.pumpWidget(const SizedBox());+ app.dispose();+ });++ testWidgets(+ 'another unavailable computer does not hide the local start path',+ (tester) async {+ final app = _FirstUseApp();+ const remote = Machine(+ machineId: 'r',+ name: 'Remote computer',+ authMode: MachineAuthMode.remote,+ );+ app.machineStates['r'] = MachineState(remote)+ ..nodeOnline = false+ ..agentLoadStatus = AgentLoadStatus.error;+ final oldPicker = FileSelectorPlatform.instance;+ final picker = _FolderPicker();+ FileSelectorPlatform.instance = picker;+ addTearDown(() => FileSelectorPlatform.instance = oldPicker);+ await mount(tester, app);+ expect(find.text('Choose folder…'), findsOneWidget);+ expect(find.text('Machines'), findsNothing);+ await tester.tap(find.byKey(const ValueKey('swarm-start-primary')));+ await tester.pump();+ expect(picker.opened, 1);+ expect(find.text('/work/my-project'), findsOneWidget);+ expect(+ tester+ .widget<AppSelectField<String>>(+ find.byKey(const Key('new-agent-machine-field')),+ )+ .value,+ 'm',+ );+ expect(app.launches, isEmpty);+ await tester.tap(find.text('Cancel'));+ await tester.pump();+ await tester.pumpWidget(const SizedBox());+ app.dispose();+ },+ );++ testWidgets(+ 'the start page opens cloning separately and cancellation starts no agent',+ (tester) async {+ final app = _FirstUseApp();+ await mount(tester, app);+ final original = app.activeSwarm;+ await tester.tap(find.byKey(const ValueKey('swarm-start-clone')));+ await tester.pump();+ expect(find.byType(CloneRepositoryDialog), findsOneWidget);+ expect(find.text('Create agent'), findsNothing);+ await tester.tap(find.text('Cancel'));+ await tester.pump();+ expect(find.byType(CloneRepositoryDialog), findsNothing);+ expect(app.activeSwarm, same(original));+ expect(app.panes, isEmpty);+ expect(app.launches, isEmpty);+ expect(app.probes, 1);+ await tester.pumpWidget(const SizedBox());+ app.dispose();+ },+ );+testWidgets('pending creation stays visible and an error preserves choices for retry',(tester) async {@@ -214,14 +396,7 @@ void main() {}expect(find.byType(AlertDialog), findsOneWidget);expect(find.text('/work/existing'), findsOneWidget);- expect(- tester- .widget<AppSelectField<String>>(- find.byKey(const Key('new-agent-machine-field')),- )- .value,- 'm',- );+ expect(find.byKey(const Key('new-agent-machine-field')), findsNothing);expect(tester.widget<AppSelectField<String>>(@@ -275,14 +450,18 @@ void main() {.focusNode!.hasPrimaryFocus;- await tester.sendKeyEvent(LogicalKeyboardKey.tab);- await tester.pump();- expect(fieldFocused('new-agent-machine-field'), isTrue);+ expect(find.byKey(const Key('new-agent-machine-field')), findsNothing);await tester.sendKeyEvent(LogicalKeyboardKey.tab);await tester.pump();expect(- Focus.of(tester.element(find.text('Clone repository…')))- .hasPrimaryFocus,+ Focus.of(+ tester.element(+ find.descendant(+ of: find.byType(AlertDialog),+ matching: find.text('Clone repository…'),+ ),+ ),+ ).hasPrimaryFocus,isTrue,);await tester.sendKeyEvent(LogicalKeyboardKey.tab);@@ -372,16 +551,9 @@ void main() {expect(find.text('Projects'), findsNothing);expect(app.launches, isEmpty);expect(- tester- .widget<TextField>(- find.byKey(const ValueKey('swarm-welcome-search-input')),- )- .focusNode!- .hasPrimaryFocus,- isTrue,+ find.byKey(const ValueKey('swarm-welcome-search-input')),+ findsNothing,);- await tester.sendKeyEvent(LogicalKeyboardKey.tab);- await tester.pump();expect(Focus.of(tester.element(find.text('Choose folder…'))).hasPrimaryFocus,isTrue,@@ -391,11 +563,8 @@ void main() {final engine = tester.widget<AppSelectField<String>>(find.byKey(const Key('new-agent-engine-field')),);- final machine = tester.widget<AppSelectField<String>>(- find.byKey(const Key('new-agent-machine-field')),- );expect(engine.value, 'codex');- expect(machine.value, 'm');+ expect(find.byKey(const Key('new-agent-machine-field')), findsNothing);expect(tester.getTopLeft(find.text('Working folder')).dy,lessThan(tester.getTopLeft(find.text('Agent')).dy),diff --git a/desktop/test/swarm_project_members_test.dart b/desktop/test/swarm_project_members_test.dartindex af797941d..4f983c88c 100644--- a/desktop/test/swarm_project_members_test.dart+++ b/desktop/test/swarm_project_members_test.dart@@ -60,6 +60,8 @@ void main() {),);await tester.pump();+ await tester.tap(find.byKey(const ValueKey('swarm-start-browse')));+ await tester.pump();await tester.tap(find.byTooltip('Project options for Workshop'));await tester.pumpAndSettle();await tester.tap(find.text('Choose agents…'));diff --git a/desktop/test/swarm_screen_test.dart b/desktop/test/swarm_screen_test.dartindex 6ec457cfe..a1738fa24 100644--- a/desktop/test/swarm_screen_test.dart+++ b/desktop/test/swarm_screen_test.dart@@ -8,6 +8,7 @@ import 'package:harness/screens/swarm_screen.dart';import 'package:harness/shared/theme/app_theme.dart' as grid;import 'package:harness/state/app_state.dart';import 'package:harness/state/swarm_catalog.dart';+import 'package:harness/state/swarm_navigation.dart';import 'package:harness/terminal/terminal_binary.dart';import 'package:harness/terminal/terminal_session.dart';import 'package:harness/widgets/pane_grid.dart';@@ -18,7 +19,11 @@ import 'package:xterm/xterm.dart';import 'swarm_state_test.dart' show createApp;import 'swarm_interactions_test.dart' show chord;-Future<void> mount(WidgetTester tester, AppNotifier app) async {+Future<void> mount(+ WidgetTester tester,+ AppNotifier app, {+ SwarmProjectStore? projects,+}) async {tester.view.devicePixelRatio = 1;tester.view.physicalSize = const Size(1280, 800);addTearDown(tester.view.resetPhysicalSize);@@ -29,7 +34,7 @@ Future<void> mount(WidgetTester tester, AppNotifier app) async {home: SwarmScreen(notifier: app,nativeTabs: false,- projectStore: SwarmProjectStore(),+ projectStore: projects ?? SwarmProjectStore(),),),);@@ -67,6 +72,8 @@ void main() {},);await mount(tester, app);+ await tester.tap(find.byKey(const ValueKey('swarm-start-browse')));+ await tester.pump();expect(find.text('Existing project'), findsOneWidget);await tester.tap(find.byKey(const ValueKey('swarm-welcome-search-input')),@@ -77,9 +84,15 @@ void main() {'/work/existing',);await tester.pump();- expect(find.widgetWithText(ListTile, 'Agent 0'), findsOneWidget);- expect(find.widgetWithText(ListTile, 'Agent 1'), findsOneWidget);- expect(find.text('Agent 2'), findsNothing);+ expect(+ find.byKey(ValueKey(agentDestinationId('m', 'a0'))),+ findsOneWidget,+ );+ expect(+ find.byKey(ValueKey(agentDestinationId('m', 'a1'))),+ findsOneWidget,+ );+ expect(find.byKey(ValueKey(agentDestinationId('m', 'a2'))), findsNothing);await tester.sendKeyEvent(LogicalKeyboardKey.escape);await tester.pump();await tester.tap(find.text('Existing project'));@@ -98,6 +111,9 @@ void main() {await mount(tester, app);expect(find.text('Start a swarm'), findsOneWidget);expect(find.text('Models'), findsNothing);+ expect(find.text('Machines'), findsNothing);+ await tester.tap(find.byKey(const ValueKey('swarm-start-browse')));+ await tester.pump();expect(find.text('Machines'), findsOneWidget);await tester.tap(find.byKey(const ValueKey('swarm-welcome-search-input')),@@ -109,7 +125,7 @@ void main() {);await tester.pump();expect(find.text('Agent 1').last, findsOneWidget);- await tester.tap(find.widgetWithText(ListTile, 'Agent 1'));+ await tester.tap(find.byKey(ValueKey(agentDestinationId('m', 'a1'))));await tester.pump();await app.addAgentToSwarm('m', 'a2');app.toggleZoomPane();diff --git a/docs/handoff/app-v2-2026-09-13/README.md b/docs/handoff/app-v2-2026-09-13/README.mdindex eeed736cc..40910c462 100644--- a/docs/handoff/app-v2-2026-09-13/README.md+++ b/docs/handoff/app-v2-2026-09-13/README.md@@ -4,6 +4,11 @@ These files preserve work paused during the user's design discussion. They are**not active application source**. Read [the current handoff](../../harness-v2-handoff.md)before reusing them: the final decision requires distinct Navigate and Add UIs.+Both drafts are now superseded by production source. Navigate and Add were+implemented separately in `2d3c024`; the later common empty-swarm start page+adapts the onboarding ideas without introducing a first-tab-only component.+Keep these files as design history, not patches to apply to the current branch.+The drafts were saved from a worktree based on `ac443eb`. Both patches separatelypass `git apply --check` at the `26a372e` code checkpoint. They overlap in`desktop/lib/screens/swarm_screen.dart`; this is not a verified combined patch.@@ -42,7 +47,7 @@ first-use detection beyond a single empty-machine case. It was saved beforevalidation and must be adapted to the approved shared Add interface. Do notdescribe it as shipped or proven to improve onboarding.-Inspect/reuse selected changes rather than automatically applying both files:+Historical applicability checks (only against the old checkpoint named above):```sh# From repository root; checks only, without modifying source.diff --git a/docs/harness-v2-appearance-onboarding.md b/docs/harness-v2-appearance-onboarding.mdindex e04b13a9e..8194fa70d 100644--- a/docs/harness-v2-appearance-onboarding.md+++ b/docs/harness-v2-appearance-onboarding.md@@ -1,6 +1,6 @@# Appearance and first use-For the current goal, approved Navigate/Add separation, first-use plan, and acceptance criteria, start with [the continuation handoff](harness-v2-handoff.md). The earlier onboarding implementation below did not resolve the user's first-impression concerns. A further welcome draft is preserved in the handoff archive but remains unverified and unapplied.+For the current goal, approved Navigate/Add separation, first-use plan, and acceptance criteria, start with [the continuation handoff](harness-v2-handoff.md). The common empty-swarm start page below supersedes the earlier first-workspace-only behavior. The archived welcome draft is historical; useful ideas were adapted into the shared production page rather than adding a second onboarding surface.Research and implementation notes, 2026-09-13. The product decisions below are Harness adaptations, not claims that the referenced tools endorse them.@@ -40,7 +40,56 @@ Fourteen isolated profile/startup lifecycle checks and the existing first-run/maThe next discovery stage now overlaps agent inventory and terminal capabilities after the machine handshake. Agents become visible when their list arrives, while existing panes wait for both prerequisites before attaching. A combined app/WebSocket fixture verifies that both requests reach a loopback peer before either reply, including visible inventory while capabilities remain pending. This removes another serial dependency without shortening the existing connection/reply budgets or moving keyboard focus.-## Onboarding evidence and direction+## Common empty-swarm start page++The same `SwarmWelcome` now handles every empty swarm. Its next action depends on+available work, not whether this is the first tab or whether another swarm was+previously closed. This removes the first/second-tab inconsistency the user+reported.++- With no existing agent views, **Start with one agent** explains the immediate+ value and shows a clearly labeled static example of two agents working side+ by side. **Choose folder…** opens the native chooser directly when a usable+ local computer is known. **Clone repository…** opens the separate clone form.+ Both lead to the ordinary New agent form, preserving the folder and original+ target. No example task or agent is started automatically.+- With discovered or retained work, **Start a swarm** offers the shared Add+ search, three existing-agent shortcuts, and **New agent**. Adding keeps the+ user in this swarm and preserves source memberships. Offline retained work+ remains discoverable. No global-navigation action is introduced here.+- Saved projects stay visible without expanding a catalog, including projects+ with no agents. **Browse machines and projects** reveals the complete catalog+ and its existing linking/project-management actions. Another offline computer+ no longer hides a ready local computer's folder-first path.+- A single usable local computer no longer occupies a Machine dropdown in New+ agent. Multiple targets, remote targets, offline state and linking issues keep+ that choice visible. Agent selection, Advanced settings, explicit permission+ options and failure recovery keep their existing behavior.+- No machines during discovery shows a disabled progress action. No linked+ computer offers **Link a machine**; offline machines offer **Reconnect**, with+ repeat activation guarded while the retry is pending. A delayed first discovery+ gives the enabled folder action keyboard focus unless the user has already+ moved to another welcome control. Enter opens the chooser without an extra Tab.+- The example, search/action row and catalog stack with larger system text.+ New agent now uses the same darker shared modal veil. Welcome cards use plain+ tinted surfaces; the former backdrop filters are removed.++The source recheck used [Cursor's quickstart](https://cursor.com/docs/get-started/quickstart)+and [VS Code's agent tutorial](https://code.visualstudio.com/docs/agents/agents-tutorial).+Both move from a folder into useful agent work and subsequent review. Harness's+adaptation is one concrete starting action, an honest workspace example, and+contextual introduction of multiple agents. It is not an added mandatory tour.++Validation uses the actual screen and form with isolated machines, folder+selection and transports. It covers delayed discovery and explicit focus,+offline retry, saved-project visibility and folder routing, first/later/closed+empty swarms, clone cancellation, installed defaults, keyboard creation,+pending/failing launches, late choices and stale destinations. Real-font renders+were inspected at 1280×800 and at 880×560 with 2× text. These are synthetic UI+checks; first-install/provider-sign-in observation and measured time to a useful+real agent remain release qualification work.++## Earlier onboarding evidence and direction (historical)| Primary source | Observed behavior | Harness adaptation || --- | --- | --- |diff --git a/docs/harness-v2-handoff.md b/docs/harness-v2-handoff.mdindex 9359ed309..3e295fcb4 100644--- a/docs/harness-v2-handoff.md+++ b/docs/harness-v2-handoff.md@@ -50,7 +50,7 @@ On an existing checkout, preserve local work before updating; use a fast-forwardpull, not a reset. The prior computer's `/private/tmp` files, installed apps,saved account state, and localhost prototype server will not transfer with Git.The [handoff archive](handoff/app-v2-2026-09-13/README.md) preserves older drafts;-the picker patch is now superseded by production source. Do not reapply it.+both patches are now superseded by production source. Do not reapply them.## Core product rules@@ -179,21 +179,29 @@ remove terminal rules/recap headers, and show a bounded excerpt in a reading carThe shared modal veil is darker and the eye toggle is removed. Old custombindings for that retired toggle no longer invalidate the rest of the keymap.-**Empty-swarm consistency:** existing-agent suggestions now depend on discovered-inventory, not a first-workspace-only gate. Every empty tab, including one made-after closing a swarm, says “Add an existing agent” and adds to that tab. The-broader first-use education and setup simplification remain unfinished; do not-claim a verified onboarding conversion/time improvement.--**Archived drafts:** the picker draft is superseded by these changes. The-onboarding draft remains unapplied and unverified. Inspect and adapt useful-parts; do not apply it blindly over the new picker/welcome paths.--**Latest verification:** 1,256 desktop tests passed with one existing skip;-analyzer reports zero errors/warnings and 12 existing vendored infos. Native-checks passed 51 keymap decoder and 344 AppKit assertions, including hidden-window layout. Synthetic captures with real fonts were reviewed at 1280×800-and 880×560; they are not a real native-session visual or latency measurement.+**Current first-use continuation:** every empty tab uses one inventory-driven+start page. With no existing work, it leads with **Start with one agent**, a+static workspace example, **Choose folder…** and separate **Clone repository…**.+Available existing work gets Add search, three direct agent choices and New+agent. Saved projects stay visible; the rest of the machine/project catalog is+behind Browse. A single usable local computer no longer needs a Machine dropdown+in the creation form. Delayed discovery enables Enter on the primary action+without stealing an explicit focus choice. Offline/linking cases expose their+next action. Large text stacks the layout, and New agent now uses the shared+darker modal veil. See [first-use details](harness-v2-appearance-onboarding.md).+Observed first-install/provider flows and onboarding conversion/time remain+unverified; do not infer them from these UI changes.++**Archived drafts:** both are superseded. The onboarding ideas were adapted into+the common page, without adding another first-tab-only component.++**Latest verification:** 1,262 desktop tests passed with one existing skip;+analyzer reports zero errors/warnings and 12 existing vendored infos. The last+native checks passed 51 keymap decoder and 344 AppKit assertions; this onboarding+pass changes no native source. Synthetic start-page/form captures with real+fonts were reviewed at 1280×800 and 880×560 with 2× text; they are not a real+native-session visual or latency measurement. Logs:+`/private/tmp/harness-onboarding-{full-tests-final,analyze-clean}.log`.Navigate/Add timings and their exact scope are in[the performance record](harness-v2-performance.md). The new navigation catalogbuild measured 0.194 ms median / 0.264 ms p95 for 50 locations across 12 swarms.@@ -243,7 +251,14 @@ Historical checks for that terminal checkpoint:51 keymap decoder + 343 AppKit checks before it was parked. Those resultsapply to the old draft only. Its final visual treatment still needs review.-The workspace Release build at **`2d3c024` succeeded**. The old preview (PID 29025)+The common onboarding continuation's macOS arm64 **Release build succeeded**+with `FLUTTER_TARGET=lib/main.dart`. Log:+`/private/tmp/harness-onboarding-release-build.log`. Computer Use still returns+`cgWindowNotFound` for the exact workspace bundle path. The new binary is built;+it has not been confirmed loaded in the running preview or visually verified+through native capture. Preserve this distinction when resuming.++The previous workspace Release build at **`2d3c024` succeeded**. The old preview (PID 29025)was closed normally, then the exact workspace bundle was launched and verifiedrunning as PID 15377 with identity `ai.autonomous.harness.v2`. Those PIDs are onlyhistorical observations; recheck before any later process action. Build log:@@ -259,15 +274,17 @@ that its isolated window can become active/key.## Plan for the next session-1. **Confirm the latest source/build checkpoint.** The `2d3c024` release has been- built and its workspace process relaunched. Review+1. **Confirm the latest source/build checkpoint.** The common onboarding+ continuation has a successful Release build; its running-window revision is+ not confirmed. The last confirmed relaunch was `2d3c024`. ReviewNavigate, Add, command mode, and the fresh terminal position in the native appwhen computer-use access works. Preserve real running agents and input.-2. **Improve genuine first use.** Start with no account/runtime/agents/projects- knowledge. Make “choose a working folder → choose an agent → start” clear;- use this computer by default, reveal machine/link/project concepts when- needed, and offer existing work prominently when discovered. Adapt the saved- onboarding draft to the new Add experience. Preserve choices on failure.+2. **Observe genuine first use of the common start page.** Start with no+ account/runtime/agents/projects knowledge and record actual steps/errors to+ a usable agent. The folder-first path, workspace example and secondary+ catalog are implemented. Check fresh dependencies, provider sign-in, cloning,+ first task and adding a second agent; improve what the observation exposes.+ Preserve choices on failure and the distinction between Navigate and Add.3. **Recheck fresh terminal positioning and real workflows** on disposablelocal/remote agents: startup, delayed snapshots, resizing, returning to ascrolled view, reconnect, paste, selection, and IME.diff --git a/docs/harness-v2-progress.md b/docs/harness-v2-progress.mdindex 69f90a34a..8c13722d6 100644--- a/docs/harness-v2-progress.md+++ b/docs/harness-v2-progress.md@@ -1,10 +1,40 @@# Harness App V2 — development handoff-Updated 2026-09-13 after resuming the Navigate/Add implementation. This is a working preview, not a release.+Updated 2026-09-13 after the common empty-swarm onboarding continuation. This is a working preview, not a release.**Resume with [Harness v2: goal, plan, and continuation handoff](harness-v2-handoff.md).** It records the latest approved design, acceptance criteria, next-work order, and portable drafts. The checkpoints below are historical; the current handoff supersedes their conflicting toolbar, picker, preview, menu, and onboarding directions.-## Navigate and Add agent continuation+## Common empty-swarm onboarding continuation++- One start page serves every empty swarm. With no existing work it leads with+ **Start with one agent**, a static side-by-side example, **Choose folder…** and+ separate **Clone repository…**. With existing work it offers shared Add search,+ three direct agent choices and New agent. Saved projects stay visible, while+ Browse reveals the full machine/project catalog.+- A usable local computer retains the direct folder path even if another+ computer is offline. New agent skips the Machine dropdown for a single usable+ local target. Offline/linking/loading states offer their next action. The+ form now uses the darker shared modal veil; the welcome surfaces need no+ backdrop filters, and the layout stacks with larger text.+- A regression caught Enter doing nothing when first discovery finished after+ the initial disabled action. The newly enabled action now receives default+ focus in the welcome scope, while an explicit focus on another control wins.+ Tests also cover offline retry, saved-project routing/visibility in later+ tabs, clone cancellation and the existing creation/recovery paths.+- **1,262 desktop tests passed, one existing skip**; analyzer: zero errors or+ warnings, 12 existing vendored infos. Actual screen/form renders with real+ fonts were reviewed at 1280×800 and 880×560 with 2× text. Logs:+ `/private/tmp/harness-onboarding-{full-tests-final,analyze-clean}.log`.+- The [onboarding notes](harness-v2-appearance-onboarding.md) record the source+ research, current behavior and remaining qualification. The archived welcome+ draft is superseded. Real first-install/provider sign-in, time to useful work,+ native event-to-display latency and remote reconnect remain unverified.+- The macOS arm64 Release build succeeded with the normal `lib/main.dart`+ target (`/private/tmp/harness-onboarding-release-build.log`). Exact-path native+ capture still returns `cgWindowNotFound`; the new binary has not been confirmed+ loaded in the running preview. No native visual or latency result is claimed.++## Navigate and Add agent continuation (previous checkpoint)- Implemented distinct UIs: a compact compass/Navigate directory lists every existing swarm location for a matching agent; New swarm, bottom-right floating +, and both splits share Add results with an always-on preview and New agent action. Navigate does not mutate membership. Add reuses the session and preserves source swarms, avoids duplicates, and keeps the chosen split position.- Every empty swarm now offers the same existing-agent suggestions, including after closing earlier swarms. Removed the first-use-only gate and “Go to an agent” heading. Broader onboarding simplification remains next work.