adamrushy / OpenAISwift

This is a wrapper library around the ChatGPT and OpenAI HTTP API
MIT License
1.6k stars 242 forks source link

Added user, temperature, topProbabilityMass, choices, stop, presencePenalty, frequencyPenalty parameters to ChatConversation and sendChat functions. #40

Closed JosephChing closed 1 year ago

JosephChing commented 1 year ago

Added the following to the ChatConversation, and both sendChat functions:

Corresponding strings have been added to the CodingKeys in ChatConversation. All added parameters are optional values, and do not have to be added when calling sendChat.

Note that the following parameters still need to be added:

The stream parameter makes it so that tokens are sent as server-sent events. This may require the use of another library such as https://github.com/inaka/EventSource.

adamrushy commented 1 year ago

@JosephChing thanks for the PR can you resolve conflicts? Thank you!

JosephChing commented 1 year ago

@adamrushy Done!