claude 3
1.0.0
تعرف على كلود 3 Haiku ، وهو شيطان سريع يعالج 30 صفحة في وميض ، وتفكر يضع معايير جديدة ، وصور فك تشفير البصيرة إلى الرسوم البيانية الفنية. مثالي للعب الأدوار
إذا كنت تستخدمه من خلال أي واجهة أمامية ، بالنسبة لـ Librechats ، SillyTavern ، Janitorai إلخ.
https://galaxyapi.onrender.comcurl https://galaxyapi.onrender.com/v1/chat/completions
-H " Content-Type: application/json "
-H " Authorization: Bearer $GALAXYAI_API_KEY "
-d ' {
"model": "claude-3-haiku-20240307",
"messages": [
{
"role": "system",
"content": "You are a helpful assistant."
},
{
"role": "user",
"content": "Hello!"
}
]
} 'بيثون
from openai import OpenAI
client = OpenAI ( apikey = "galaxy-secret-key-here" )
client . base_url = "https://galaxyapi.onrender.com/v1"
completion = client . chat . completions . create (
model = "claude-3-haiku-20240307" ,
messages = [
{ "role" : "system" , "content" : "You are a helpful assistant." },
{ "role" : "user" , "content" : "Hello!" }
]
)
print ( completion . choices [ 0 ]. message )Nodejs
import OpenAI from "openai" ;
const openai = new OpenAI ( {
apiKey : 'GALAXY_API_KEY' ,
baseURL : 'https://galaxyapi.onrender.com/v1'
} )
async function main ( ) {
const completion = await openai . chat . completions . create ( {
messages : [ { role : "system" , content : "You are a helpful assistant." } ] ,
model : "claude-3-haiku-20240307" ,
} ) ;
console . log ( completion . choices [ 0 ] ) ;
}
main ( ) ;وجود مشكلات ، لا تتردد في الإبلاغ عنها عن طريق إنشاء المشكلة أو الإبلاغ عنها هنا.