PhoenixLLM

Good to know: All LLM interfaces need to use token as the request header.

Buy LLM Token

POST https://www.phoenix.global/sdk/computation/LLM/buyLLMToken

Headers

Name
Type
Description

token*

string

The token generated in the previous step

Request Body

Name
Type
Description

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"
}'

Query Token price

GET https://www.phoenix.global/sdk/computation/LLM/queryLLMPrice

Querying the price of LLM token, priced in ccd

Headers

Name
Type
Description

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

Name
Type
Description

token*

string

The token generated in the previous step

Request Body

Name
Type
Description

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

Name
Type
Description

token*

string

The token generated in the previous step

Request Body

Name
Type
Description

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