Skip to content

feat: prompt before launching mobile agent profiles - #803

Merged
leynier merged 2 commits into
mainfrom
feat/mobile-prompted-agent-launch
Sep 17, 2026
Merged

leynier merged 2 commits into
mainfrom
feat/mobile-prompted-agent-launch

Conversation

@leynier

@leynier leynier commented Sep 17, 2026

Copy link
Copy Markdown
Owner

Summary

Mobile New Tab now opens a prompt dialog before spawning an opted-in Agent Profile, matching desktop #731.

  • Skip launches with an empty prompt.
  • Start Agent requires a non-empty prompt (typed, dictated, or an attached host path).
  • Reuses the existing mobile dictation control and Add Attachment sources (photo library, files, workspace file).
  • Selects the new tab after a successful launch.
  • showInNewTabMenu still gates the menu. Profiles that are not opted in are not launched.

No protocol version bump. agentProfile.launch already accepts prompt, and agentProfilePromptLaunchV1 is already in MOBILE_HELLO_CAPABILITIES.

Validation

  • flutter analyze on the touched mobile files (no issues)
  • flutter test test/agent_profile_launch_sheet_test.dart test/workspace_tabs_screen_test.dart test/workspace_agent_comments_test.dart

Risks

  • Attachment uploads still depend on the host advertising image, file, or workspace-file capabilities. The button is hidden when none are available.
  • Dictation only appears when the user has enabled it.

AGENTS.md was not updated: this is UI-only on a verb the runtime already allowlists.

Open a prompt dialog from New Tab for opted-in Agent Profiles, matching desktop skip-or-prompt launch.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Important

Dictated prompts never enable Start Agent, so Skip is the only remaining launch control and it drops the text.

Reviewed changes

Mobile New Tab now collects a starting prompt before agentProfile.launch, matching desktop #731.

  • Launch sheet — New dialog with Skip, Start Agent, dictation, and capability-gated attachments that insert host paths into the prompt.
  • New Tab wiring — Profile menu actions carry the full AgentProfileSummary and open the sheet instead of launching immediately; a successful launch still selects the new tab.
  • Tests — Widget coverage for skip, start, close, in-dialog errors, image path insertion, and the New Tab prompt round-trip.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using Grok | 𝕏

Comment thread mobile/lib/src/features/terminal/presentation/agent_profile_launch_sheet.dart Outdated
Listen on the prompt controller so dictation and other programmatic writes enable Start Agent.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes

The launch sheet now listens on the prompt controller so dictated and other programmatic writes enable Start Agent.

  • Controller listener — _promptController.addListener updates _hasPrompt and drives _canStart, matching TerminalComposeBar and replacing the onChanged rebuild.
  • Coverage — Widget test assigns controller.value the same way dictation does and asserts Start Agent becomes enabled, then launches the dictated text.

Pullfrog  | View workflow run | Using Grok | 𝕏

@leynier
leynier merged commit 3e9e52c into main Sep 17, 2026
20 checks passed
@leynier
leynier deleted the feat/mobile-prompted-agent-launch branch September 17, 2026 07:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant