Skip to main content

Prem Is Also OpenAI Compatible

Instead of using the Prem API, you can use the OpenAI SDK to generate chat completions with Prem by just changing the base URL and adding your API key.See our Client SDKs guide to learn how to use Prem AI with OpenAI’s API/SDK.
This is the API Reference for Prem AI. Here you can find documentation for all of the endpoints that are available in the Prem API. You can use the sidebar to navigate to the different sections. Prem provides a REST API that you can use to interact with the platform with any programming language that can make HTTP requests.

API Endpoints

Build your data pipeline

Projects

Provision and inspect project workspaces

Datasets

Ingest JSONL files or trigger synthetic runs

Snapshots

Split datasets into train and validation sets

Recommendations

Request model suggestions for a snapshot

Fine-Tuning

Launch and monitor fine-tuning jobs

Run and observe models

Chat Completions

Send prompts to deployed chat models

Models

List all available models

Traces

Retrieve traces captured during inference

Authentication

All API endpoints are authenticated using Bearer tokens. You’ll need to create an API key first - see our API Key guide for instructions. Once you have your API key, include it in the Authorization header:
Authorization: Bearer YOUR_API_KEY
The authentication is automatically picked up from the OpenAPI specification file:
"security": [
  {
    "bearerAuth": []
  }
]