1
0
This commit is contained in:
2024-05-23 20:43:52 +08:00
parent e6da567437
commit 9a33bd6f49
11 changed files with 292 additions and 1 deletions

11
gpt.py Normal file
View File

@@ -0,0 +1,11 @@
from g4f.client import Client
content = "张量在机器学习中的主要用途"
client = Client()
response = client.chat.completions.create(
model="gpt-4o",
messages=[{"role": "user", "content": content}],
)
print(response.choices[0].message.content)