Completion
This endpoint generates text completions for a given prompt.
POST
https://api.geodd.io/inference/v1/completions
Authorizations
Authorization
string
header
required
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/json
model
string
required
Model name to use for generating completions.
Example:
meta-llama/Llama-3.1-405B-instruct
prompt
string | array
required
The prompt(s) to generate completions for, encoded as a string, array of strings, array of tokens, or array of token arrays.
max_tokens
integer
optional
The maximum number of tokens to generate in the completion. The total length of input tokens and generated tokens is limited by the model's context length.
Responses
200
OK
Request processed successfully. Returns a completion object.
401
Unauthorized
Invalid or missing API Key. Check the
Authorization header.
429
Too Many Requests
Token limit exceeded. Upgrade to a dedicated instance for higher limits.
Example Request
bash
curl --location 'https://api.geodd.io/inference/v1/completions' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"model": "meta-llama/Llama-3.1-405B-instruct",
"prompt": "How big is earth?",
"max_tokens": 200
}'Previous
Chat CompletionNext
Embedding