⚠️ You will need an OpenAI API to build this app
This is a basic .NET command line client for OpenAI's chatGPT. It uses the unoffical OPENAI .NET SDK betalgo/openai created by Betalgo.
- Currently set ot use the ChatGPT 3.5-Turbo model.
- ChatGPT replies are in green, while user input are in white.
- The first system param set for ChatGPT is "Introduce yourself".
- An active OpenAI API key
- .NET 7 Installed on your machine to build the app
- open the Cmd or Terminal to the base folder '/ChatGPT-.NET-CLI'
- ensure that .NET & is installed
- added the API key to your user secrets
dotnet user-secrets init
dotnet user-secrets set "OpenAIServiceOptions:ApiKey" "YOUR_OPENAI_API_KEY"
- build the project
dotnet build ChatGPT-.NET-CLI.sln
- Currently it is set to build to the '/bin/Debug/net7.0' folder
- From the base folder you can run the following
dotnet run bin/Debug/net7.0/ChatGPTDemo