feat(editor): Add node-context chat telemetry (no-changelog) - #36912
Draft
jgalmeida wants to merge 1 commit into
Draft
feat(editor): Add node-context chat telemetry (no-changelog)#36912jgalmeida wants to merge 1 commit into
jgalmeida wants to merge 1 commit into
Conversation
Two INSTANCE_AI events for the add-nodes-to-chat feature: - "User added nodes to chat" (source + node_count), fired from the shared addSelectedNodesToChat chokepoint with the source threaded from each Canvas trigger (node toolbar, selection toolbar, context menu, group title bar, keyboard). - "User sent chat message with nodes" (node_count), fired from both send paths when the message carries node context. https://linear.app/n8n/issue/ADO-5793 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds telemetry for the "add nodes to chat" (node context) feature, per https://linear.app/n8n/issue/ADO-5793. Two events in the
INSTANCE_AIdomain of the@n8n/telemetryregistry.Stacked on the feature branch (base is
claude/ado-5773-front-end-bc4413, PR #36225), so the diff here is only the telemetry commit.Events
User added nodes to chatsource,node_countaddSelectedNodesToChatchokepoint, after the attachment is built — sonode_countis the count actually attached (unresolved ids dropped, capped at the per-set max), not the raw selection.sourceis threaded from each Canvas trigger.User sent chat message with nodesnode_countnode_counttotals nodes across every attached set.sourcevalues:node_toolbar,selection_toolbar,context_menu,group_title_bar,keyboard.Kept intentionally minimal (
source+ count) — nothread_id/instance_id(PostHog already carries session identity), no set-count.Testing
useAddNodesToChatsource/count, 2 for thecountAttachedNodeshelper); mockuseTelemetry().trackand assert the registry entry + payload.@n8n/telemetryregistry checks pass (descriptions non-blank, JSON-schema-representable).pnpm typecheck(editor-ui) clean — confirms everytrack()payload matches its zod schema.🤖 Generated with Claude Code