PhoenixLLM
Buy LLM Token
POST https://www.phoenix.global/sdk/computation/LLM/buyLLMToken
Headers
token*
string
The token generated in the previous step
Request Body
tokensNum*
integer
The number of tokens to be purchased
jobName*
string
Job name
{
"code": 200,
"msg": "success",
"jobID": "15336929879565052031766977071313450079096374296015479727460579121350576553341"
}The usage of curl and golang sdk is as follows:
curl --location 'https://www.phoenix.global/sdk/computation/LLM/buyLLMToken' \
--header 'token: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJFbWFpbCI6IjExMUBnbWFpbC5jb20iLCJleHAiOjE2NzgyNzM4Mjh9.7Qy6jh5L1qvVVbOZYR3JrmWdothI2SCF-oGyC2BfZDs' \
--header 'Content-Type: application/json' \
--data '{
"tokensNum": 1000,
"jobName": "LLM job"
}'package main
import (
"github.com/PhoenixGlobal/Phoenix-Computation-SDK/common"
"github.com/PhoenixGlobal/Phoenix-Computation-SDK/controllers"
)
func main() {
tokenStr := "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJFbWFpbCI6IjExMUBnbWFpbC5jb20iLCJleHAiOjE2NzgyNzM4Mjh9.7Qy6jh5L1qvVVbOZYR3JrmWdothI2SCF-oGyC2BfZDs"
reqJSON := common.ReqBuyLlmToken{
UserToken: tokenStr,
JobName: "Buy llm token 31",
TokensNum: 1000,
}
result, err := controllers.BuyLLMToken(reqJSON)
...
}Query Token price
GET https://www.phoenix.global/sdk/computation/LLM/queryLLMPrice
Querying the price of LLM token, priced in ccd
Headers
token*
string
The token generated in the previous step
The usage of curl and golang sdk is as follows:
Default LLM
POST https://www.phoenix.global/sdk/computation/LLM/callLLM3
Headers
token*
string
The token generated in the previous step
Request Body
prompt*
string
Prompt
max_new_tokens
int
The maximum number of tokens that can be consumed by this call
Response
The usage of curl and golang sdk is as follows:
Coding LLM
POST https://www.phoenix.global/sdk/computation/LLM/verticalLLM
Headers
token*
string
The token generated in the previous step
Request Body
prompt*
string
Prompt
max_new_tokens
int
The maximum number of tokens that can be consumed by this call
Response
The usage of curl and golang sdk is as follows:
Last updated