gustabin / chatgpt-php
Chatbot using openai API chatgpt in PHP
Installs: 8
Dependents: 1
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Language:HTML
Type:project
Requires
- php: ^8.0
- gustabin/chatgpt-php: dev-main
This package is auto-updated.
Last update: 2024-05-20 02:33:40 UTC
README
Description
This is a simple chatbot that uses the OpenAI API to generate responses based on user-input messages. The chatbot is capable of generating coherent and relevant text, maintaining conversation context, and performing specific tasks.
Usage
- Clone this repository.
- Open the
index.html
file in your web browser. - Interact with the chatbot by entering messages in the input field and clicking "Send."
Files
index.html
: Main file containing the chatbot's interface.chat.js
: Script for the chat's functionality.chatApi.js
: Script to make requests to the OpenAI API and obtain chatbot responses.chatHistory.js
: Chat history to keep a record of conversations.chat.php
: PHP file to process chatbot requests to the OpenAI API.
Credits
- Author: Ing. Gustavo Arias
- Website: Stack code lab
Notes
Free preview. ChatGPT may produce inaccurate information about people, places, or facts.
License
This project is under the MIT License. See the LICENSE
file for more details.
Installation
composer create-project gustabin/chatgpt-php