Gokul-Raja84 / CHATBOT

Chatbots in Python !

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Project Overview

This repository contains a Python-based Chatbot project that utilizes the OpenAI API to create an interactive and conversational Chatbot. The Chatbot is designed to engage in real-time conversations with users and provide natural language-based responses.

Project Structure

Simple Chatbot - This Python script demonstrates a chatbot using the OpenAI GPT-3.5-turbo model. It communicates with users via text input and generates AI-driven responses. Before running, set your OpenAI API key in the 'openai.api_key' field. The chatbot generates creative ideas for apps and services when prompted.

Interactive chatbot using OpenAI API - This Python code creates a dynamic chatbot using OpenAI's GPT-3.5-turbo model. It takes the user's API key, initializes a list to store chat messages, and prompts the user to specify the chatbot type. The chatbot starts the conversation and keeps responding to the user until they type "quit()". The 'openai.ChatCompletion.create()' method is used to interact with the API and get AI-generated responses for the user's input.

Chatbot with a interface hosted in web - This Python script implements a chatbot using the OpenAI GPT-3.5-turbo model, allowing users to interact with an AI assistant that provides helpful responses based on their input. The script requires the installation of the openai and gradio libraries. To use the chatbot, you need to replace "OPENAI API key" with your actual OpenAI API key. The chatbot starts with an initial system message, "A Helpful AI Assistant," displayed to users upon initiation. The 'CustomChatGPT' function is defined to handle user input, appending it to the 'messages' list, and sending it to the OpenAI API for chat completion. The response received from the API contains the AI assistant's reply, which is then appended to the messages list. The script creates a Gradio interface to facilitate user interaction. Users can input text messages, and the chatbot will respond with human-like replies generated by the OpenAI model. The Gradio interface titled "CHATBOT by GOKUL RAJA" is launched when the script is executed, enabling users to communicate with the AI assistant.

By setting 'share=True', you can share the URL of the Gradio interface with others, allowing them to interact with the chatbot as well. The chatbot's versatility makes it suitable for integration into various applications, including customer support systems, interactive help desks, and personalized assistants, offering real-time responses to users' queries and enhancing user experience.

AI Voice Assistant - The "AI Assistant" is a virtual assistant powered by artificial intelligence, designed to simplify your daily tasks. With an intuitive voice and text interface, it offers seamless interaction for various functions. The assistant can open applications like Notepad, Spotify, and more upon voice command. It provides real-time information, including time, date, and weather. You can enjoy entertainment with YouTube video playback, read jokes, and receive helpful advice. The assistant ensures efficient communication by sending instant WhatsApp messages. Access your favorite websites like Wikipedia and conduct web searches with ease. The assistant even offers email functionality and can open various applications effortlessly. The "AI Assistant" streamlines your routine tasks, making technology an invaluable asset in your daily life.

Chatbot Web Interface

image

Features

  • Interactive Chat: Users can engage in real-time conversations with the Chatbot by inputting text prompts.

  • Natural Language Processing: The Chatbot uses OpenAI's powerful language model to understand and generate human-like responses.

  • Customizable Responses: The Chatbot's responses can be fine-tuned based on specific use cases and preferences.

  • User-friendly Interface: The Chatbot's interactions are presented through a simple and intuitive command-line interface.

How to Contribute

Contributions to the project are welcome! If you have any ideas for improvements, bug fixes, or additional features, feel free to submit a pull request.

  1. Fork the repository.
  2. Create a new branch for your feature: git checkout -b feature-name.
  3. Make the necessary changes and commit them: git commit -m "Add your message here".
  4. Push your changes to your fork: git push origin feature-name.
  5. Submit a pull request from your branch to the main branch of this repository.

Acknowledgements

This project was inspired by the need to create an interactive Chatbot using OpenAI's powerful language model. The implementation was guided by OpenAI's API documentation and various online resources.

If you have any questions or suggestions, feel free to contact me at [gokulraja840@gmail.com].

Enjoy the chatting with Chatbot!

About

Chatbots in Python !


Languages

Language:Python 79.6%Language:Jupyter Notebook 20.4%