Create a fill-in-the-middle completion
Generate a code completion given a prompt (prefix) and optional suffix. Designed for IDE-style inline completion. Returns a FimCompletion object, or a server-sent events stream of FimCompletionChunk deltas when stream=true. Tool calling and function calling are not supported.
Authorizations
API key provided as a Bearer token: Authorization: Bearer <api_key>. Get an API key at https://platform.inceptionlabs.ai.
Body
The prompt to complete.
The model to use for the FIM completion.
The suffix to complete.
Maximum number of tokens to generate.
1 <= x <= 8192Float that controls the cumulative probability of the top tokens to consider.
0 <= x <= 1Limits sampling to the k most likely tokens. Must be -1 (disables the cutoff and considers all tokens) or an integer from 1 to 1000; other values such as 0 are rejected.
-1 <= x <= 1000Number between -2 and 2. Positive values penalize tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim.
-2 <= x <= 2Number between -2 and 2. Positive values penalize tokens based on whether they have appeared in the text so far, increasing the model's likelihood to talk about new topics.
-2 <= x <= 2Penalizes tokens that have already appeared in the generated text. Must be greater than 0. Values greater than 1.0 discourage repetition; 1.0 applies no penalty.
x >= 0A list of sequences where the API will stop generating further tokens. The returned text will not contain the stop sequences. Defaults to common code-block boundaries.
Whether to stream the response.
Options that control streaming behavior.
Response
Successful response. Returns a JSON object when stream=false, or a server-sent events stream of TextCompletionChunk objects (terminated by data: [DONE]) when stream=true.