Create an embedding
OpenAI compatible embeddings endpoint. If the model does not respond in time, the request will be timed out and the prediction will be cancelled.
In: header
The model to use for this OpenAI compatible endpoint. Models must be in the following format: model_owner/model_name or model_owner/model_name:version_number.
Input text to embed, encoded as a string or array of tokens. To embed multiple inputs in a single request, pass an array of strings or array of token arrays.
The number of dimensions the resulting output embeddings should have.
The format to return the embeddings in.
Response Body
curl -X POST "https://api.wrift.ai/v1/embeddings" \ -H "Content-Type: application/json" \ -d '{ "model": "string", "input": "string" }'{
"data": [
{
"embedding": [
0
],
"index": 0,
"object": "embedding"
}
],
"model": "string",
"object": "list",
"usage": {
"prompt_tokens": 0,
"total_tokens": 0
}
}{
"detail": [
{
"loc": [
"string"
],
"msg": "string",
"type": "string"
}
]
}Create a chat completion POST
OpenAI compatible chat completions endpoint. If the model does not respond in time, the request will be timed out and the prediction will be cancelled.
Generate an image POST
OpenAI compatible image generation endpoint. If the model does not respond in time, the request will be timed out and the prediction will be cancelled.