Skip to main content
View source

OpenAI-Compatible API

View as Markdown

A RocketRide LLM node that connects any OpenAI-compatible API endpoint to a pipeline.

What it does

Connects any OpenAI-compatible API endpoint to your pipeline. Use this node for providers that implement the OpenAI API spec (Featherless, Together, Groq, Ollama, LM Studio, and others) but do not have a dedicated RocketRide node. Used primarily as an llm invoke connection by agents and other nodes that need an LLM, but can also be used directly via lanes.

Built on langchain-openai (ChatOpenAI) over the official openai SDK. The chat client is created with temperature: 0 for deterministic output, and max_tokens is set from the shared LLM base's output-token budget (default 4096, minimum 1024). When base_url is empty, the SDK falls back to the default OpenAI endpoint.

When the node configuration is saved, it validates the settings by sending a 1-token "Hi" completion request to the configured endpoint (10-second timeout) and surfaces any provider error (bad key, unknown model, unreachable URL) as a warning with the provider's status code and message, truncated to 500 characters.

Lanes

Lane inLane outDescription
questionsanswersSend a question directly, receive a generated answer

Profiles

Generic endpoint default: Custom OpenAI-compatible endpoint (custom). Nebius preset default: Llama 3.3 70B Instruct (llama-3-3-70b).

The directory documents the generic endpoint and the Nebius branded preset in one combined profile table.

ProfileModelContext tokensSource
Generic custom (default)(user-specified)32,768Any OpenAI-compatible API
llama-3-3-70b (default)meta-llama/Llama-3.3-70B-Instruct131,072Nebius Token Factory
qwen3-235bQwen/Qwen3-235B-A22B131,072Nebius Token Factory
deepseek-v3deepseek-ai/DeepSeek-V3131,072Nebius Token Factory

Configuration

Choose custom for a generic provider and set its model ID, base URL, context limit, and API key. Choose one of the named Nebius profiles when using Token Factory; those profiles pin the model ID, endpoint, and context limit.

Generic OpenAI-compatible endpoints

Set base_url to the provider's OpenAI-compatible API root and model to its exact model identifier. When base_url is empty, the OpenAI SDK uses its default endpoint. Use a positive modelTotalTokens value that matches the selected model.

Nebius preset

services.nebius.json registers Nebius (llm_nebius://) as a branded preset of this node. It uses the same Python implementation and pins the base URL to https://api.tokenfactory.nebius.com/v1/. The three named Nebius profiles in the combined table require no model or endpoint edits.

Nebius profiles default the API key to the ${ROCKETRIDE_NEBIUS_KEY} environment substitution, so no per-node key entry is needed when that variable is set. The Nebius service also exposes its own custom option for another Token Factory model, retaining the pinned endpoint, environment-backed key, and 131,072-token context limit. The combined table represents the duplicate custom key once, using the generic service's merged 32,768-token default.

Authentication

For custom, provide the API key expected by the configured endpoint. Nebius named profiles use ${ROCKETRIDE_NEBIUS_KEY} by default; replace it only when the credential must be supplied directly in the node configuration.

Notes

Error handling and retries

Provider errors are mapped to friendly messages and classified for retry:

Provider exceptionRetriedSurfaced as
AuthenticationErrornoInvalid API key.
APIErrornoAn error occurred with the API.
RateLimitErroryesRate limit exceeded. Please try again later.
APIConnectionErroryesFailed to connect to the API.

Anything else falls through to the shared LLM base's default retry and mapping logic.

Testing

services.json includes a test block that runs the custom profile against a local test server with a mocked langchain_openai, so no real API key is required. ROCKETRIDE_MOCK must point to nodes/test/mocks.


Schema

OpenAI-Compatible API (services.json)

FieldTypeDescriptionDefault
base_urlstringBase URL
API base URL (e.g. https://api.featherless.ai/v1)
modelstringModel
Model name (e.g. zai-org/GLM-5, meta-llama/Llama-3-70b)
modelTotalTokensnumberTokens
Total Tokens
openai_api.profilestringModel
Profile selection
"custom"

Nebius (services.nebius.json)

FieldTypeDescriptionDefault
base_urlstringBase URL
OpenAI-compatible base URL. Defaults to Nebius Token Factory.
modelstringModel
Nebius Token Factory model id (e.g. meta-llama/Llama-3.3-70B-Instruct). Full list: https://tokenfactory.nebius.com/models
modelTotalTokensnumberTokens
Total Tokens
openai_api.profilestringModel
Nebius Token Factory model
"llama-3-3-70b"

Dependencies

  • openai
  • langchain-openai
  • langchain-core
  • langchain