Quick Start

LLM as a service quick start

Setting up API Key

After accessing LLM as a service, you need to set up your API key. Learn how to set your API key here.

Quickly test API

To quickly try the API using cURL, use the following command:

curl -X POST https://api.float16.cloud/v1/chat/completions -d 

  '{
    "model": "seallm-7b-v3",
    "messages": [
      {
        "role": "system",
        "content": "You are a helpful assistant."
      },
      {
        "role": "user",
        "content": "ΰΈͺΰΈ§ΰΈ±ΰΈͺΰΈ”ΰΈ΅"
      }
    ]
   }'

  -H "Content-Type: application/json" 
  -H "Authorization: Bearer <float16-api-key>"

Paste this in your terminal to see the response.

Using the Chat API

Our API is compatible with OpenAI, allowing integration with your chat UI using OpenAI or LangChain libraries.

OpenAI

  1. Install the OpenAI package:

  1. Use this Python code snippet (example using SeaLLM-7B-v2.5 model):

For more information on the OpenAI library, visit the OpenAI docs.

LangChain

To use Float16.cloud with the LangChain, follow these steps:

  1. Install the LangChain package:

or

  1. Use this Python code snippet (example using SeaLLM-7B-v2.5 model):

For more information on the LangChain library, visit the LangChain docs.

For Further Assistance:

If you need additional help, feel free to contact us at [email protected].

Last updated