microsoft / genaiscript

Automatable GenAI Scripting
https://microsoft.github.io/genaiscript/
MIT License
2.02k stars 116 forks source link

`genaiscript parse html-to-text` output is broken #891

Closed mattpowell closed 6 days ago

mattpowell commented 6 days ago

When running the the html-to-text parser via cli the output is:

$> npx genaiscript parse html-to-text demo.html
Promise { <pending> }

I believe this issue was introduced in this commit when the various HTML functions were converted to async.

And I think it can be resolved by adding an await to the HTMLToText call here.

Let me know if additional info is needed or if I can test anything on my end.

Thanks!

pelikhan commented 6 days ago

Thanks for the analysis! Fixed in https://github.com/microsoft/genaiscript/commit/a8a908d2959428d1ecc67b82f89f8f69d124f2b8 .

pelikhan commented 6 days ago

you can test it out in 1.78.3 @mattpowell

pelikhan commented 6 days ago

@mattpowell jsxmin is quite cool; it'd be interresting to get a lightweight jsx syntax for prompt (well there's also priompt and vscode/prompt-tsx but hey).