Giter Club home page Giter Club logo

chatbot_interface_with_gpt-4's Introduction

Chatbot Interface with OpenAI GPT-4

Overview

This project is a simple chat interface built using Streamlit and powered by the OpenAI GPT-4 model. It allows users to interact with a chatbot by entering messages and receiving responses generated by the OpenAI model.

Getting Started

Dependencies

This code uses the following libraries:

  • streamlit: for building the user interface.
  • openai: for chat
  • OpenAI API key: Get it from OpenAI platform

Usage

Follow these steps to set up and run the project:

  1. Create a virtual environment:
python3 -m venv my_env
source my_env/bin/activate 
.\my_env\Scripts\activate 
  1. Install dependencies:
pip install -r requirements.txt
  1. Run the Streamlit server:
streamlit run app.py
  1. Access the application in your browser at http://localhost:8501.

  2. Enter your OpenAI API key in the provided input field.

  3. Start chatting with the assistant!

Repository Structure

repository/
├── app.py # the code and UI integrated together live here
├── about.py # function adding gui elements
├── requirements.txt # the python packages needed to run locally
├── .streamlit/
│   └── config.toml # theme info for the UI
└── docs/
    └── preview.png # preview photo for Github

How it Works

The app as follows:

  1. The user enters a question in the input field.

  2. User messages are sent to the OpenAI GPT-4 model for processing.

  3. The user's input, along with the chat history, is used to generate a response.

  4. The GPT-4 model generates a response based on the patterns it learned during training.

  5. Users can continue the conversation by entering additional messages.

chatbot_interface_with_gpt-4's People

Contributors

ilhansevval avatar

Stargazers

Herley avatar  avatar Saba Hesaraki avatar

Watchers

 avatar

Forkers

herley-shaori

chatbot_interface_with_gpt-4's Issues

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.