Commit 107a98e
committed
feat(home): score suggested actions by workspace signals
- Derive the suggestion pool from the curated block template catalog
(1,343 prompts across 172 blocks) instead of 15 hardcoded entries
- Fix inverted relevance: prompts for connected providers are now boosted
4x (instantly runnable) instead of excluded; unconnected discounted 0.4x
- Weight by featured (3x), popular category (1.5x), and resource gaps
(no tables -> boost table starters; has KBs -> dampen KB-creation prompts)
- Weighted sampling without replacement, max one suggestion per block
- Connect rows weighted by catalog template count; 2 for fresh workspaces,
1 once something is connected
- Key the catalog map by both versioned and base block types so gmail_v2
templates resolve (gmail, github, notion, linear were silently dropped)
- Replace derive-in-effect state with a useMemo keyed by a shuffle nonce
- Add suggested_action_clicked / suggested_actions_shuffled /
suggested_actions_toggled PostHog events1 parent 254af5c commit 107a98e
2 files changed
Lines changed: 250 additions & 199 deletions
File tree
- apps/sim
- app/workspace/[workspaceId]/home/components/suggested-actions
- lib/posthog
0 commit comments