Stop sending voice transcripts and AI responses to PostHog#81
Conversation
User transcripts and Claude responses were being sent verbatim to PostHog analytics, exposing private conversation content to a third-party service. Retain character_count for usage metrics only.
|
Hey @farzaa — just curious, was there a specific reason for sending full transcripts and responses to PostHog? Given that Clicky has access to the user's screen and voice, I think keeping conversation content off third-party servers is important for user trust. If there's specific analytics signal you were hoping to get from the content, let me know and I'm happy to add something more privacy-preserving to this PR. |
khaledmhirsi
left a comment
There was a problem hiding this comment.
Reviewed this as the privacy-focused low-hanging PR.
This is scoped correctly: it removes the raw user transcript and raw AI response from the two PostHog events while keeping character_count, so product analytics still preserve input/output length trends without shipping conversation content to PostHog.
I checked this against PostHog's current privacy/data-collection guidance: their docs recommend preventing sensitive data before it reaches PostHog servers and call out private-by-default collection for sensitive text. This PR aligns with that shape.
Validation I ran locally on the PR branch:
rg -n '"transcript"\s*:|"response"\s*:' leanring-buddy/ClickyAnalytics.swiftreturned no matches.git diff --check origin/main...HEADpassed, and the diff is exactlyleanring-buddy/ClickyAnalytics.swift | 2 --.swiftc -parse leanring-buddy/*.swiftpassed.gh pr view 81 --repo farzaa/clicky --json state,isDraft,mergeable,mergeStateStatusreports open, not draft, mergeable, and clean.
Docs reference: https://posthog.com/docs/privacy/data-collection
Problem
trackUserMessageSentandtrackAIResponseReceivedinClickyAnalytics.swiftwere sending the full verbatim text of every user voice transcript and every
Claude response to PostHog. For an app that captures screen and voice, users
reasonably expect that conversation content stays on their device.
Fix
Remove the
transcriptandresponseproperties from the two analytics events.The
character_countproperty is retained in both — this preserves useful usagemetrics (response length trends, input length) without exposing any content.
Changes
ClickyAnalytics.swift: remove"transcript"fromuser_message_senteventClickyAnalytics.swift: remove"response"fromai_response_receivedevent