MittaAI / webwright

Webwright is an AI-powered terminal emulator that lives within your OS. It eliminates time spent on repetitive tasks, conjures code, summons software, and bends the OS to its will. Are you ready to release the ghost in your shell?
MIT License
31 stars 2 forks source link

works with openai and anthropic #71

Open andyllegrand opened 2 months ago

andyllegrand commented 2 months ago

Used litellm to implement streaming with openai api calls. Could not get this to work with anthropic but the original anthropic code is still present and supported.

Streaming can be a little finicky, in order to get the formatted text to work each time a new chunk arrives the previously printed text is erased and replaced with the new text. Sometimes a line is not erased properly, but i don't think this is a big issue.

andyllegrand commented 2 months ago

Also I'm not sure if the way i delete lines from the terminal will work properly on windows, please test this merging