How to have same capabilities of px.line(df, line_group='line_id', color='category')

Hi,
I am deciding to migrate from a plotting library built on plotly to build apps in panel later. I know I could use pn.pane.Plotly but I would like to have the full capabilities of this framework (access easily to datasets of elements, composing layouts, streams etc…)
Here the problem

  • I have a dataframe with 4701 rows
  • line_id unique entries are 340
  • category unique entries are 1 (in this example)
  • the dataframe contains x,y lines to display grouped by line_id and category.
  • I would like to use line_id to group lines (like plolty express line_group arg) and ‘category’ to have separated colors + traces in the legend

I tried the following

pl = hvPlot(df)
ly = pl.line(
    x='x',
    y='y',
    by=['line_id', 'category'],
)

but I obtain each line with color given by (line_id, category) tuple (so not color given by only category as in px.express)
Morover the rendering is quite slow (17 seconds VS 0.8 seconds in plotly)
Rendering time is the part that concerns me the most about migrating to the Holoviz framework. Any help would be greatly appreciated.