Proposal: Signal to auto-refresh chapters and transcripts #548
Replies: 5 comments 17 replies
-
While something to signal chapters and transcripts status would be very useful for apps, the http response status might be a little difficult to implement for podcasters who self-host their shows. As an example: I put all my mp3s, chapters and transcript files in an S3 bucket, and I have no control on the http response status the server sends. Maybe putting an ETA as an attribute to the podcast:chapter and podcast:transcript tags might be more accessible for both established hosting services and self-hosted podcasts. |
Beta Was this translation helpful? Give feedback.
-
For Buzzsprout, the chapters and transcripts can change based on dynamic content. The only way to be sure you have the correct version is to request it at the same time as you request the audio. I hope that makes sense! |
Beta Was this translation helpful? Give feedback.
-
App developer point of view. Dave + Adam's way: chapters are not yet published, a placeholder file is published and its url is specified in the rss feed. The app will need to download and scan the chapter/transcript file repeatedly, optimally each time the user presses play, to check if the chapters/transcripts have been published or modified. Buzzsprout way: chapters have to be downloaded at the same time as the mp3 because with dynamic ads / content, the location markers would go out of sync. Refreshing the chapter/transcript file at a later time would download a mismatched version of the files. With the current P2.0 specifications I see no way to code an app that is compatible with both ways. A signal like the one in this proposal is necessary. I would really prefer it coded in the RSS file which should remain our main source of truth. |
Beta Was this translation helpful? Give feedback.
-
Here's what we should do: support ETags in the responses for these external resources (most CDNs already do), and include a similar <podcast:chapters url="https://example.com/episode1/chapters.json" type="application/json+chapters" etag="890abc" /> RSS feed is the source of truth, and any change is a signal that the external resource needs to be refetched. btw this approach should be used for any of the This will work for any non-dynamic audio shows, and even "dynamic" hosts like Buzzsprout that are not really request-dynamic, just restitched every so often. Truly dynamic responses would still need to rely on something like Link headers, and would not set an |
Beta Was this translation helpful? Give feedback.
-
I like our goal here: to ensure the audience has the correct version of the chapters (which might be different from the latest version if they downloaded audio with dynamically inserted content). Something to keep in mind. Some developers, such as Marco with Overcast, absolutely refuse to implement anything that can be used to track the audience. So checking for updated chapters every time the episode is opened or played won't fly with him, and I think we should keep those privacy concerns in mind. I like the idea of using Podping for this because that can reduce the number of times an audience member's app will have to ping a server and thus be trackable. But there needs to be a mechanism to distinguish between changes resulting in dynamic content that will not align with predownloaded audio and changes (like corrections or improvements) that will align with predownloaded audio. |
Beta Was this translation helpful? Give feedback.
-
This proposal suggests a standard way for hosting services to signal to apps when chapters and transcripts should be re-fetched.
Chapters and transcripts can change after the first time they're fetched, and hence they sometimes need to be re-fetched. This is because chapters and transcripts take time to produce, and sometimes are produced not purely by AI ahead of time, but actually contributed at some later time by listeners of the show. Or, it can simply be because even if these files are AI produced, the inference models take time to execute, and depending on server load, may need to wait in a processing queue. Therefore in the meantime, one of these placeholders tends to be uploaded to indicate "please try again in a few moments, it will be ready soon..." (e.g. the type of placeholder that Dreb uploads before the real chapters and transcripts are ready).
Currently, apps don't have a good signal for when chapters and transcripts are expected to be ready, whether in 5 minutes or in 24 hours, and so apps either have to poll for changes or provide users a refresh button where users end up repeatedly hitting the refresh button, having the same end effect on the network as polling. At the same time, if an app tries to poll on behalf of the user, it must deal with the possibility that actually the first version of the asset that was already fetched IS the final version, and so polling should NOT be attempted.
It would therefore be helpful to have a signal to apps indicating if and when a re-fetch should be attempted.
Checking online for solutions that people are already adopting, I found one interesting approach based on the HTTP protocol. We have the 200 status for a resource that is "ready", we have 404 for a resource that is a broken link. But do we have a status code for a resource that is "not ready yet", or "pending"?
A number of interesting suggestions have been made on StackOverflow and StackExchange:
Of these, 503 seems particularly interesting and has attracted interest on StackOverflow because unlike the other options, it also supports the optional Retry-After header:
Example response:
Thus, we can issue a valid chapters or transcripts file in the response so that it could be consumed and shown by the app, but at the same time use the HTTP status and
Retry-After
header to signal to the app when a re-fetch should happen.I do not see any harm in hosts choosing to implement this approach before it is standardised, since apps should already be programmed to handle whatever server response they receive, but apps could then learn to leverage the information returned by the 503 request to more smartly poll for updates.
There may also be alternative solutions to the same problem (e.g. additional attributes tacked onto the chapters and transcript tags, or additional server headers), but in the meantime I think the 503 request status is a conservative solution that could be adopted now with minimal risk.
Beta Was this translation helpful? Give feedback.
All reactions