Coder Social home page Coder Social logo

include76 / csharpwpfchatgpt Goto Github PK

View Code? Open in Web Editor NEW

This project forked from psun247/csharpwpfchatgpt

0.0 0.0 0.0 523 KB

A C# WPF ChatGPT (GPT-3.5 model turbo) app that mimics ChatGPT website UI

Home Page: https://petersun.azurewebsites.net

License: MIT License

C# 100.00%

csharpwpfchatgpt's Introduction

Please read the project article at codeproject.com

https://www.codeproject.com/Tips/5377103/ChatGPT-API-in-Csharp-WPF-XAML-MVVM

C# WPF ChatGPT

C# WPF app that communicates OpenAI GPT3.5-turbo API

image

image

Setup

Create an Open AI account to obtain an API key (free): https://platform.openai.com/account/api-keys

You can use the key as a command line parameter (without compiling the project):

  1. Click CSharpWpfChatGPT_v1.2 under Releases on the right side of this page
  2. Download CSharpWpfChatGPT_v1.2_net6.0-windows.zip
  3. Unzip the file and run CSharpWpfChatGPT.exe /the key obtained above (CSharpWpfChatGPT.exe /sk-Ih...WPd)

Or in App.xaml.cs, modify this line: return "<Your Open AI API Key is something like "sk-Ih...WPd">";

Build CSharpWpfChatGPT.sln with Visual Studio 2022 (Community version okay). This app is targeted for .NET 6 and 8. If you don't have .NET 8 installed, remove net8.0-windows in CSharpWpfChatGPT.csproj.

Whetstone.ChatGPT

I used John Iwasz's excellent Whetstone.ChatGPT to do the heavy lifting for ChatGPT API calls.

https://www.nuget.org/packages/Whetstone.ChatGPT

Other Supporting Libraries

CommunityToolkit.Mvvm

https://www.nuget.org/packages/CommunityToolkit.Mvvm

ModernWpfUI

https://www.nuget.org/packages/ModernWpfUI/

RestoreWindowPlace

https://www.nuget.org/packages/RestoreWindowPlace

csharpwpfchatgpt's People

Contributors

psun247 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.