Universal Script 📌
24.2k Views
767 Executions

OpenAI chat bot

Universal Script 📌
Seby
SebyPublished 10
4 years ago
Get an executor
Please login to perform these actions:

Does it work?

No reports yet

No reports yet. Tried it? Be the first to say.

Also noticed:

Description

how to use: - create an account in https://openai.com/api/ - go to Manage Account -> API Key (https://beta.openai.com/account/api-keys), copy the api key and paste it inside the SECRET_KEY variable - write the name of people you want the bot to reply to, inside the WHITELISTED table (or simply enable the CLOSE_RANGE_ONLY variable if you want it to answer everyone around you) - enjoy notes: - the bot will only reply to texts that has > 15 characters and < 50 characters (you can change these settings in the script, inside the MESSAGE_SETTINGS table) - there's a cooldown between replies in order to not spam the API, 5 seconds - if the response is > 200 characters (roblox chat limit) then the text will be cut in 2 parts Showcase: https://medal.tv/games/roblox/clips/qCW0QQDYnfptO/d1337r0YtsZw?invite=cr-MSw3ckssMTY4NjEyMzcs Credits to BillsTheGod on v3rmillion Original thread: https://v3rmillion.net/showthread.php?tid=1176455 If you have a v3rmillion account, consider liking the thread post so that the user gets the 500 likes badge

View Raw
repeat wait() until game:IsLoaded();

-- // SETTINGS \\ --

local SECRET_KEY = "secret key here"; --https://beta.openai.com/account/api-keys
local CLOSE_RANGE_ONLY = false;

_G.MESSAGE_SETTINGS = {
	["MINIMUM_CHARACTERS"] = 15,
	["MAXIMUM_CHARACTERS"] = 50,
	["MAXIMUM_STUDS"] = 15,
};

_G.WHITELISTED = { --Only works if CLOSE_RANGE_ONLY is disabled
	["seem2006"] = true,
};

_G.BLACKLISTED = { --Only works if CLOSE_RANGE_ONLY is enabled
	["Builderman"] = true,
};

-- // DO NOT CHANGE BELOW \\ --

if _G.OpenAI or SECRET_KEY == "secret key here" then return end;

_G.OpenAI = true;

local ReplicatedStorage = game:GetService("ReplicatedStorage");
local Players = game:GetService("Players");
local HttpService = game:GetService("HttpService");
local LocalPlayer = Players.LocalPlayer;
local SayMessageRequest = ReplicatedStorage:WaitForChild("DefaultChatSystemChatEvents"):WaitForChild("SayMessageRequest");
local Debounce = false;

local function MakeRequest(Prompt)
	return syn.request({
		Url = "https://api.openai.com/v1/completions", 
		Method = "POST",
		Headers = {
			["Content-Type"] = "application/json",


Comments

4
Log in to join the conversation. Login
upseguest's profile picture
upseguest4 years ago(edited)

i get kicked with 'Player service requires player disconnect" why?????

3
alejosdaniel98's profile picture
alejosdaniel984 years ago(edited)

Does this still work?! I saw someone using an AI Bot earlier in PLS DONATE but this won't work. They told me to look up "OPEN AI" so that led me here.

2
AlperSocial's profile picture
AlperSocial4 years ago(edited)

fire

2
OlimPather's profile picture
OlimPather4 years ago(edited)

No way! This is awesome!

2

Tags

More universal scripts

See all
Script hub
2.2M
714.6k
Bumped 6 minutes ago
Key System

Script hub

#5 today

Verified script badgeLumin Hub | #1 | Insta Steal

Universal Script 📌
14
0
Approved 10 minutes ago
Universal Script 📌
14
2
Approved 24 minutes ago
Key System
Universal Script 📌
30
0
Approved 35 minutes ago
Key System