diff --git a/docs/reference/feature-discovery-interaction-tracking.md b/docs/reference/feature-discovery-interaction-tracking.md index 1e35b38b76a..c1233fb7a75 100644 --- a/docs/reference/feature-discovery-interaction-tracking.md +++ b/docs/reference/feature-discovery-interaction-tracking.md @@ -24,7 +24,8 @@ Do not upload this state as broad analytics. Product analytics should continue t | Feature | Interaction ID | Record when | Education use | | --- | --- | --- | --- | | Review notes to agent | `review-notes` | A diff or markdown review note is added, or review notes are marked sent to an agent. | Suppress or target a future review-notes tour/tip about adding line notes and sending focused feedback back to an agent. | -| Ship with AI | `ai-commit-pr` | AI commit/PR generation is enabled or a commit message / PR draft is generated. | Suppress future education about AI commit/PR generation. No contextual tour is planned for this branch. | +| AI commit generation | `ai-commit-generation` | AI commit-message generation is enabled or an AI commit message is generated. | Suppress future education about AI commit generation. No contextual tour is planned for this branch. | +| AI PR generation | `ai-pr-generation` | AI pull-request title/body/draft fields are generated. | Suppress future education about AI PR generation. No contextual tour is planned for this branch. | | Floating Workspace | `floating-workspace` | The floating workspace opens, is enabled, or is configured. | Suppress future tips about the global terminal/browser/markdown workspace. No contextual tour is planned for this branch. | | Quick Commands | `quick-commands` | A terminal quick command is created or edited. | Suppress future tips about saved terminal commands. No contextual tour is planned for this branch. | | Computer Use | `computer-use` | Computer Use is selected in onboarding, a permission setup is opened, or the skill setup terminal opens. | Suppress future tips once the user has started setup. No contextual tour is planned until there is a better non-settings entry point. | diff --git a/src/renderer/src/components/right-sidebar/SourceControl.tsx b/src/renderer/src/components/right-sidebar/SourceControl.tsx index 6d882a03a63..a660a834739 100644 --- a/src/renderer/src/components/right-sidebar/SourceControl.tsx +++ b/src/renderer/src/components/right-sidebar/SourceControl.tsx @@ -1746,7 +1746,7 @@ function SourceControlInner(): React.JSX.Element { } return writeCommitDraftForWorktree(prev, activeWorktreeId, result.message) }) - useAppStore.getState().recordFeatureInteraction('ai-commit-pr') + useAppStore.getState().recordFeatureInteraction('ai-commit-generation') setGenerateErrors((prev) => ({ ...prev, [activeWorktreeId]: null })) } catch (error) { setGenerateErrors((prev) => ({ @@ -2031,7 +2031,7 @@ function SourceControlInner(): React.JSX.Element { if (!nextRecord) { return prev } - useAppStore.getState().recordFeatureInteraction('ai-commit-pr') + useAppStore.getState().recordFeatureInteraction('ai-pr-generation') return { ...prev, [generationKey]: nextRecord diff --git a/src/renderer/src/components/right-sidebar/useCreatePullRequestDialogFields.ts b/src/renderer/src/components/right-sidebar/useCreatePullRequestDialogFields.ts index 0cef8c0cbc6..5cb643a367f 100644 --- a/src/renderer/src/components/right-sidebar/useCreatePullRequestDialogFields.ts +++ b/src/renderer/src/components/right-sidebar/useCreatePullRequestDialogFields.ts @@ -263,7 +263,7 @@ export function useCreatePullRequestDialogFields({ setTitle(result.fields.title) setBody(result.fields.body) setDraft(result.fields.draft) - useAppStore.getState().recordFeatureInteraction('ai-commit-pr') + useAppStore.getState().recordFeatureInteraction('ai-pr-generation') setGenerateError(null) } catch (error) { if (generationRequestIdRef.current !== requestId) { diff --git a/src/renderer/src/components/settings/CommitMessageAiPane.tsx b/src/renderer/src/components/settings/CommitMessageAiPane.tsx index ca89b000915..c0e9d428d9b 100644 --- a/src/renderer/src/components/settings/CommitMessageAiPane.tsx +++ b/src/renderer/src/components/settings/CommitMessageAiPane.tsx @@ -470,7 +470,7 @@ export function CommitMessageAiPane({ ...selectedModelPatch, selectedThinkingByModel: nextSelectedThinkingByModel }) - useAppStore.getState().recordFeatureInteraction('ai-commit-pr') + useAppStore.getState().recordFeatureInteraction('ai-commit-generation') } const onAgentChange = (newAgentId: string): void => { diff --git a/src/shared/feature-interactions.test.ts b/src/shared/feature-interactions.test.ts index 02076b7b8fd..daebcb088f3 100644 --- a/src/shared/feature-interactions.test.ts +++ b/src/shared/feature-interactions.test.ts @@ -31,7 +31,8 @@ describe('feature interactions', () => { 'workspace-creation', 'agent-browser-use', 'agent-orchestration', - 'ai-commit-pr', + 'ai-commit-generation', + 'ai-pr-generation', 'claude-account-switching', 'computer-use', 'codex-account-switching', diff --git a/src/shared/feature-interactions.ts b/src/shared/feature-interactions.ts index b4c860949cf..26ac2432504 100644 --- a/src/shared/feature-interactions.ts +++ b/src/shared/feature-interactions.ts @@ -11,7 +11,8 @@ export type FeatureInteractionId = | 'workspace-creation' | 'agent-browser-use' | 'agent-orchestration' - | 'ai-commit-pr' + | 'ai-commit-generation' + | 'ai-pr-generation' | 'claude-account-switching' | 'computer-use' | 'codex-account-switching' @@ -98,8 +99,12 @@ export const FEATURE_INTERACTIONS = [ interaction: 'Agent Orchestration setup enabled or used' }, { - id: 'ai-commit-pr', - interaction: 'AI commit message or pull request generation enabled or used' + id: 'ai-commit-generation', + interaction: 'AI commit message generation enabled or used' + }, + { + id: 'ai-pr-generation', + interaction: 'AI pull request generation used' }, { id: 'claude-account-switching',