Skip to content

[Improve] Route chat suggestions when users start them - #1149

Merged
daniel-lxs merged 2 commits into
developfrom
feature/simplify-chat-suggestions-3eli2rsyju7sk
Aug 7, 2026
Merged

[Improve] Route chat suggestions when users start them#1149
daniel-lxs merged 2 commits into
developfrom
feature/simplify-chat-suggestions-3eli2rsyju7sk

Conversation

@roomote-roomote

@roomote-roomote roomote-roomote Bot commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

Opened on behalf of Daniel Riccio. Follow up by mentioning @roomote-roomote, in the web UI, or in Slack.

What changed

  • Reduced ordinary chat-reply suggestions to the title and description shown to users; the submission endpoint drops any launch metadata older workers still send.
  • Chat-reply suggestion cards are stamped launchRouting: 'router' in tracked-message metadata when posted (Slack, Discord, Telegram, Teams).
  • Launch routing is decided once, at the claim boundary: claim functions null the pinned launch metadata (repository, environment, investigation context) for router-marked cards, and downstream launchers simply use field presence. On Slack, router-marked cards launch through normal workspace routing, with safe claim release when routing cannot select a workspace.
  • Unmarked cards keep their verified pinned targets on every surface: scheduled Scan workflow suggestions, setup suggestions, and cards posted before the marker existed.
  • Scan workflows keep the rich suggestion contract in the MCP tool schema; ordinary chat replies only accept title and description.

Why this change was made

Chat suggestions could select and persist the wrong repository before a user approved them. Repository selection belongs to the task router at launch time, while verified scheduled and setup automation targets must remain deterministic.

Impact

Users see simpler suggestion cards, and approved chat suggestions run in the workspace selected by Roomote's router. Scan and setup suggestions retain their repository, environment, priority, category, and investigation context behavior on all surfaces. Cards posted before this release launch exactly as they did before.

@roomote-community

roomote-community Bot commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

No code issues found. See task

  • Telegram Start buttons preserve the pinned workspace for current-thread Scan suggestions (apps/api/src/handlers/telegram/setup-suggestions.ts:194).
  • Reaction launches preserve the pinned workspace for current-thread Scan suggestions (apps/api/src/handlers/tasks/current-thread-suggestion-reaction.ts:80).

Reviewed ddc70e2

Comment thread apps/api/src/handlers/tasks/current-thread-suggestion-reaction.ts Outdated
Comment thread apps/api/src/handlers/telegram/setup-suggestions.ts Outdated
Launch routing now has a single rule: cards whose tracked-message metadata
carries launchRouting: 'router' are presentation-only chat-reply suggestions,
and every claim function nulls their pinned launch metadata before returning.
Downstream launchers just use field presence, so the per-surface
launchRouting !== 'router' guards, the suggestionGroupKey heuristic, and the
legacy taskRuns payloadKind lookup are gone. Unmarked cards (scan, setup, and
cards posted before the marker existed) keep their verified pinned targets on
every surface, including current-thread scan suggestions on Discord, Telegram,
and Teams.

@daniel-lxs daniel-lxs left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Reviewed the full diff, trimmed the launch-routing logic to a single claim-boundary rule, and smoke-tested the Slack reaction flow against the mock harness (router branch taken, claim released cleanly on routing fallback). Scan and setup suggestions keep their verified pinned targets.

@daniel-lxs
daniel-lxs marked this pull request as ready for review August 7, 2026 17:38
@daniel-lxs
daniel-lxs merged commit 32952fa into develop Aug 7, 2026
19 checks passed
@daniel-lxs
daniel-lxs deleted the feature/simplify-chat-suggestions-3eli2rsyju7sk branch August 7, 2026 17:38
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