load1n9 / openai

Unofficial Deno wrapper for the Open Ai api
MIT License
73 stars 23 forks source link

Extract ChatCompletionMessage type #19

Closed blakechambers closed 1 year ago

blakechambers commented 1 year ago

This was mentioned in a comment as part of #17, but the differences between ChatCompletion and ChatCompletionOptions make it difficult to exchange sequences of messages with the API (without needing to limit fields passed to OpenAI). This refactor makes it a little easier.

Let me know if you have any suggestions or feedback.