Parasail
  • Welcome
  • Serverless
    • Serverless
    • Available Parameters
  • Dedicated
    • Dedicated Endpoints
    • Speeding up Dedicated Models with Speculative Decoding
    • Deploying private models through HuggingFace Repos
    • Dedicated Endpoint Management API
    • Rate Limits and Limitations
  • Batch
    • Quick start
    • Batch Processing with Private Models
    • Batch file format
    • API Reference
  • Cookbooks
    • Run and Evaluate Any Model
    • Chat Completions
    • RAG
    • Multi-Modal
    • Text-to-Speech with Orpheus TTS models
  • Billing
    • Pricing
    • Billing And Payments
    • Promotions
    • Batch SLA
  • Security and Account Management
    • Data Privacy and Retention
    • Account Management
    • Compliance
  • Resources
    • Silly Tavern Guide
    • Community Engagement
Powered by GitBook
On this page
  • OpenAI API reference
  • Client Setup
  • Chat Completions vs Text Completions:
  1. Batch

API Reference

PreviousBatch file formatNextRun and Evaluate Any Model

Last updated 5 months ago

Parasail offers a direct drop-in replacement for OpenAI's batch API. The same documentation, guides, and cookbooks apply.

We encourage you to use OpenAI's or community-built client libraries for your preferred language.

The only workflow changes are:

  • Use the Parasail URL: https://api.saas.parasail.io

  • Use your Parasail API key. Create one .

  • Use an open model that Parasail supports instead of ChatGPT.

OpenAI API reference

Client Setup

# pip install openai
from openai import OpenAI

client = OpenAI(
    base_url="https://api.saas.parasail.io/v1",
    api_key="$PARASAIL_API_KEY",
)

Chat Completions vs Text Completions:

As long as vLLM keeps support for both we have support for both endpoints.

/completions endpoint provides the completion for a single prompt and takes a single string as an input, whereas the /chat/completions provides the responses for a given dialog and requires the input in a specific format corresponding to the message history.

/v1/completions is for single prompt. you can use this endpoints if your app provides those services

-translation
-text or code generation
-revise a message
-write an email

On the other hand you use /v1/chat/completions if your app provides those services

-chatgpt style chatbots
-virtual assistant for customer service
-interactive surveys and forms

here
OpenAI Batch API reference
OpenAI Files API reference