s-nel / h3-archive

h3-archive
8 stars 21 forks source link

Feature request discussion: UI for suggesting edits to the transcript #2

Open tylervz opened 1 year ago

tylervz commented 1 year ago

Hi @s-nel , I love what you've done and would like to help improve the site a bit. Admittedly, I don't have any React or Scala experience and I've only dabbled with Elasticsearch but this seems like a great opportunity to learn. I saw in CONTRIBUTING.md that

We're working on implementing controls for editing directly in the app at which point we can open up access to those who want to help improve the data.

Crowd-sourcing corrections to the transcripts is a fantastic idea. I wanted to open this GitHub issue so people can discuss the following topics:

  1. what the best UI controls would be for such a feature.
  2. once the UI controls have been implemented, what should happen when someone suggests a data correction in the UI? I don't think we would want malicious actors (i.e. kav kav) to be able to easily vandalize the data in the production database, so there should be some sort of process that a data correction goes through before being considered a proper correction.

Regarding topic 1, do you have some ideas already? For an example of data that needs to be corrected, we can reference in the After Dark #58 episode when AB says "Show must go on." and in the transcript it is "Show them us go on". My idea is to have a "Suggest an Edit to the Transcript" link or button under the Transcript accordion; when clicked, the link or button would change to "Done Editing". While the user is in edit mode, the links in the transcript would no longer be YouTube timestamp links but instead open a dialog/modal with the transcript text for the user to edit and Save and Cancel buttons.

Screenshot 2023-04-12 at 12 25 25 PM

Also, are you using any UI frameworks / libraries are you using besides React and Elastic UI? This will help myself and others be able to reference specific UI elements provided by the framework.

s-nel commented 1 year ago

once the UI controls have been implemented, what should happen when someone suggests a data correction in the UI? I don't think we would want malicious actors (i.e. kav kav) to be able to easily vandalize the data in the production database, so there should be some sort of process that a data correction goes through before being considered a proper correction.

Thanks for raising the issue. I have been thinking about it a bit. Like you said, we don't want just anybody to be able to make changes to content unchecked. Ideally it would go through a public process similar to a GitHub PR where others can review, approve, request changes etc. It could work if we put all the content into the repo and create some kind of job to sync it to Elasticsearch. The upside is that if the ES cluster gets nuked we would be able to rebuild it, and we can point-in-time revert the content. The downside is that GH isn't a very user-friendly place for non-devs and may suppress user contributions. What do you think about the first step being to have all content in GitHub, and have a link from the content to the specific file in the repository to suggest edits. In stage two, we might be able to programmatically open an anonymous PR for the user without them needing an account

what the best UI controls would be for such a feature.

Maybe some kind of icon like this:

Screenshot 2023-04-13 at 12 43 18 PM

In the first stage it can just be a link to the GitHub file. Implementing proper transcript editing in the app could be tricky because we have the plain text (what's searched) and the segment array (links to timestamps/what's rendered). I think there are transcript editing UI libraries out there that might help.

Also, are you using any UI frameworks / libraries are you using besides React and Elastic UI? This will help myself and others be able to reference specific UI elements provided by the framework.

Nope, that's it!