[AI Chapters] Add playback_start_latency prop to player_chapter_selected event - #5522
[AI Chapters] Add playback_start_latency prop to player_chapter_selected event#5522sztomek wants to merge 6 commits into
playback_start_latency prop to player_chapter_selected event#5522Conversation
|
Claude finished @sztomek's task in 4m 50s —— View job Code ReviewReviewed against Findings
Minor / non-blocking
No security concerns. · |
Project dependencies changeslist! Upgraded Dependencies
com.automattic:eventhorizon:pocket-casts-2026-07-20_08-31-45, (changed from pocket-casts-2026-07-14_22-15-37)tree +--- project ':modules:features:account'
| \--- project ':modules:features:search'
| \--- project ':modules:services:analytics'
-| +--- com.automattic:eventhorizon:pocket-casts-2026-07-14_22-15-37
+| +--- com.automattic:eventhorizon:pocket-casts-2026-07-20_08-31-45
| +--- project ':modules:services:model'
-| | +--- com.automattic:eventhorizon:pocket-casts-2026-07-14_22-15-37 (*)
+| | +--- com.automattic:eventhorizon:pocket-casts-2026-07-20_08-31-45 (*)
| | \--- project ':modules:services:utils'
| | \--- project ':modules:services:payment'
-| | \--- com.automattic:eventhorizon:pocket-casts-2026-07-14_22-15-37 (*)
+| | \--- com.automattic:eventhorizon:pocket-casts-2026-07-20_08-31-45 (*)
| \--- project ':modules:services:preferences'
-| \--- com.automattic:eventhorizon:pocket-casts-2026-07-14_22-15-37 (*)
+| \--- com.automattic:eventhorizon:pocket-casts-2026-07-20_08-31-45 (*)
\--- project ':modules:features:discover'
\--- project ':modules:features:podcasts'
\--- project ':modules:features:player'
\--- project ':modules:features:transcripts'
\--- project ':modules:services:sharing'
- \--- com.automattic:eventhorizon:pocket-casts-2026-07-14_22-15-37 (*)
+ \--- com.automattic:eventhorizon:pocket-casts-2026-07-20_08-31-45 (*) |
|
Version |
|
@geekygecko please take another look as i fixed all the issues |
| } ?: chapter | ||
| } else { | ||
| chapter | ||
| } |
There was a problem hiding this comment.
I can't seem to get this working. I saw the playback_start_latency parameter appear once, but I haven't been able to figure out exactly what's happening.
I'm also not quite sure I understand what this is measuring. Shouldn't we be timing the alignment process itself, rather than how long it takes the client app to move playback to the chapter position?
Screen.Recording.2026-07-15.at.4.29.09.pm.mp4
|
@sztomek @geekygecko I'm working on bringing this event to iOS and I have a few questions/suggestions. If I got it right, this will always be tracked, no matter if the chapter is generated or producer-provided, right? That means we're tracking two different things:
The big thing for me is that connection latency is out of our reach. This is a network problem, there isn't much we can do, so what do we really want with this data? On the other hand, calculating fingerprint is something on our side, that we might want to improve and to verify by checking a property. My 2 cents here would be: we should do a What do y'all think? |
|
@leandroalonso thanks for your thoughts 🙏
sounds good to me, will update this PR + address the comments it received. |
c0d95f5 to
f7045fc
Compare
|
@leandroalonso raised EventHorizonSchemas PR with the proposed changes: https://github.com/Automattic/EventHorizonSchemas/pull/110 |
cea1a03 to
176cb86
Compare
|
@sztomek sorry for hijacking this one again. At the moment, we have a difference between iOS and Android:
This basically means I can't have this property in this event because the fingerprint calculation will still happen. What do you think about another event for that? This way it can work for both Android and iOS. |
|
Version |
|
@geekygecko may i get a review on this one, please? 🙏 |
|
Version |
Description
This PR integrates the latest version of EventHorizon that contains the most recent analytics changes to track how long did it take to find the right moment of the stream where the chapter actually begins.
It builds upon our previous PR that introduced fingerptint syncing for chapters.
conversation: p1782969913761809-slack-C0BB11SBN12
UPDATE after PR discussion
fingerprint_calculation_time_ms(generated chapters only) — reports how long the episode's fingerprint mapping took to prepare (Preparing → Active), i.e. the alignment cost on our side, not the playback move. Sourced from FingerprintTimingManager.preparationDurationMs.playback_start_latency_msno longer conflates the two — it now excludes the fingerprint wait, so for generated chapters it measures the same tap→playback-start latency as producer-provided ones.UPDATE v2
player_chapter_fingerprint_calculatedis a new event that we report in order to be on par with iOS behavior.Fixes PCDROID-645 https://linear.app/a8c/issue/PCDROID-645/update-player-chapter-selected-with-playback-start-latency-ms-prop
Testing Instructions
Screenshots or Screencast
Checklist
./gradlew spotlessApplyto automatically apply formatting/linting)modules/services/localization/src/main/res/values/strings.xmlI have tested any UI changes...