adifyr / obsidian-chat-view

An elegant chat view for Obsidian pages.
MIT License
202 stars 11 forks source link

WebVTT Support #6

Closed kmarchand closed 2 years ago

kmarchand commented 2 years ago

Hello,

This plugin looks great, thank you!

Microsoft Teams and Zoom generate transcripts in WebVTT format and it would be really nice if this plugin supported that format natively so I could store call transcripts as-is in Obsidian, and take advantage of the great visual formatting you put together.

The date and time isn't stored, just the times from the start of the recording, but names are included.

Ex;

WEBVTT

00:00:00.000 --> 00:00:04.270
<v John Smith>No one touch it, it just works.</v>

00:00:04.310 --> 00:00:04.940
<v Bob Anderson>Uhm?</v>

00:00:05.790 --> 00:00:06.930
<v John Smith>Going forward, obviously.</v>

[...]

adifyr commented 2 years ago

This definitely looks interesting. Although, I'll have to test the waters a little first. Let me see what I can do. Will get back to you soon.

adifyr commented 2 years ago

@kmarchand I have a couple of questions regarding this.

kmarchand commented 2 years ago

My suggestion would be to align with the default in Teams and other message apps of having messages from yourself on the right, and from others all on the left, with a config parameter text field to list the name that should be treated as "self". Colour could be one for self and another one for everyone else, or have an internal list of colours and auto-assign one per name found in the vtt.

I think the cleanest approach would be to use a code block for the vtt data, maybe with "webvtt" called out explicitly.

Ex;

```webvtt WEBVTT

00:00:00.000 --> 00:00:04.270

No one touch it, it just works.

00:00:04.310 --> 00:00:04.940

Uhm?

00:00:05.790 --> 00:00:06.930

Going forward, obviously.

```

adifyr commented 2 years ago

@kmarchand Thank you for your inputs! I'll get some preliminary prototyping done to see how this can be integrated into the plugin.

Don't hold your breath though. This may take a while.

kmarchand commented 2 years ago

Thanks - I have zero expectations and appreciate your work on the plugin so far!

One quick additional thought about this bit; with a config parameter text field to list the name that should be treated as "self". ... it would probably be smart to have that config parameter accept a list instead of a single value in case it changes between apps ("Kevin Marchand" vs "K. Marchand" vs "kmarchand", etc).

adifyr commented 2 years ago

@kmarchand Hi, I've just added initial support for the WebVTT format to the master branch. Could you have a look and let me know if it's good for release? I've updated the README.md file to include the new set of instructions for the format. Scroll down to the WebVTT Support section and you'll see them.

adifyr commented 2 years ago

@kmarchand I've done some testing in WebVTT support. It seems everything is good to go. I'm moving it to release. Let me know if your use-case has been covered so that I can close the issue.

kmarchand commented 2 years ago

@adifyr I just had a chance to try it and it looks great, thank you!

The one additional suggestion I would have is to have the times not displayed by default maybe with an option in the header (along with "Self: xxx" that you already have) such as "DisplayTimes: True" to turn them on... for transcripts of calls I'm just interested in what was said and don't really care what specific time anyone said anything, so it would be more compact to hide those times.

Thanks again!