How to customize hover tooltip

I have a plot that has multiple curves as shown in the attached.

Each of the curves have a really long name so I’d like to customize the hovertemplate so that it shows (x,y) …

For for my example I’d expect to see something like …bel6.nameA or …different or …l6.unknown. Where as right now I’m getting Main.app.fol… for all the plots so I can’t differentiate between them. I also tried setting the hovertemplate to just (x,y) but then the whole name is shown and that is just ridiculously long.