LLocalSearch icon indicating copy to clipboard operation
LLocalSearch copied to clipboard

The page bounces and glitches as the model types if the text box reaches the bottom of page.

Open dillfrescott opened this issue 1 year ago • 2 comments

Pretty much what the title says haha. Its glitchy as the model types and the whole page bounces up and down!

dillfrescott avatar Apr 05 '24 18:04 dillfrescott

its down to this mfer not liking the rapid changed while parsing markdown.

https://github.com/nilsherzig/LLocalSearch/blob/1e19940ea5079fdd00e922bf7e7712f79eb9a47b/src/lib/log_item.svelte#L14

While using a slow model you can see how the markdown parser gets confused by the streaming text from time to time (for example everything becomes a heading while an empty list item exists). I think i need to implement some kind of buffer for this. I still want the streaming responses be in rendered markdown. Especially tables look very cool while getting created haha

nilsherzig avatar Apr 05 '24 20:04 nilsherzig

Ohhhhh gotcha!

I still want the streaming responses be in rendered markdown.

Yes certainly! I think it's really cool too!

dillfrescott avatar Apr 05 '24 21:04 dillfrescott

i really dont know how to fix the glitching, so i guess i should just debounce the page scrolling?

nilsherzig avatar Apr 06 '24 08:04 nilsherzig

Thats fine!

dillfrescott avatar Apr 06 '24 09:04 dillfrescott

nvm i think i got it

nilsherzig avatar Apr 06 '24 09:04 nilsherzig