Universal Script 📌
415 Views
53 Executions

talk to ai and play roblox

Universal Script 📌
gavinthesigma
gavinthesigmaPublished 5
7 months 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

um bro the same talk to ai duh

View Raw
local HttpService = game:GetService("HttpService")

local function talkToAI(message)
	local url = "https://your-server-url.com/chat"

	local data = {
		msg = message
	}

	local response = HttpService:PostAsync(
		url,
		HttpService:JSONEncode(data),
		Enum.HttpContentType.ApplicationJson
	)

	local decoded = HttpService:JSONDecode(response)
	return decoded.reply
endfrom flask import Flask, request, jsonify
from openai import OpenAI

app = Flask(__name__)
client = OpenAI(api_key="YOUR_API_KEY")

@app.route("/chat", methods=["POST"])
def chat():
    data = request.json
    msg = data["msg"]

    response = client.chat.completions.create(
        model="gpt-5.3",
        messages=[{"role": "user", "content": msg}]
    )

    return jsonify({
        "reply": response.choices[0].message.content
    })

app.run()


Comments

2
Log in to join the conversation. Login
gavinthesigma's profile picture
gavinthesigmaUploader7 months ago

like what

1

[deleted]

Replying to a deleted comment
gavinthesigma's profile picture
gavinthesigmaUploader7 months ago

@ashdevera153 what the hell do you mean like I know what it means but why did you say that

1

Tags

More universal scripts

See all
Universal Script 📌
6.0k
17.8k
Bumped 31 minutes ago
Key System
Universal Script 📌
528.2k
336.7k
Bumped 2 hours ago
Script hub
2.4k
2.2k
Bumped 3 hours ago
Key System
Universal Script 📌
273
22
Approved 3 hours ago
Script hub
2.8M
661.6k
Bumped 4 hours ago
Key System

Script hub

#3 today

Verified script badgeFlow Hub | 35 Games | Updated

Universal Script 📌
335
27
Approved 6 hours ago