Skip to content

OpenClaw

OpenClaw is an open-source AI agent platform that can connect to any OpenAI-compatible inference provider. This guide walks through configuring OpenClaw to use CompactifAI as its reasoning model via the OpenAI Chat Completions API.

Before you begin, ensure you have:

  • A CompactifAI API key
  • The model ID you want to use (for example hypernova-60b, carina-60b, or glm-5-2)
  • Your CompactifAI API endpoint (typically https://api.compactif.ai/v1)
OpenClaw --> CompactifAI API

OpenClaw sends requests directly to CompactifAI using the OpenAI-compatible /v1/chat/completions endpoint. No proxy or translation layer is required.

Terminal window
curl -fsSL https://openclaw.ai/install.sh | bash
Terminal window
iwr -useb https://openclaw.ai/install.ps1 | iex

Alternatively, if you already have Node.js installed:

Terminal window
npm install -g openclaw@latest

Launch the interactive setup:

Terminal window
openclaw onboard --classic

When prompted:

  • Accept the security disclaimer.
  • Select Manual setup.
  • Choose Local gateway (this machine).
  • Accept the default workspace directory unless you have a reason to change it.

When prompted for Model/auth provider, select:

More…
└── Custom Provider

Then enter the following values:

PromptValue
API Base URLhttps://api.compactif.ai/v1
API KeyYour CompactifAI API key
Endpoint compatibilityOpenAI-compatible
Model IDA model ID from the Models Catalog (for example hypernova-60b, carina-60b, or glm-5-2)
Endpoint IDAccept the generated value (custom-api-compactif-ai) or enter your own
Model aliasOptional
Does this model support image input?Select Yes for multimodal models; otherwise No

OpenClaw verifies the endpoint by sending a test completion request. Continue once you see:

Verification successful.

The onboarding wizard then configures the local gateway.

Unless you have specific networking requirements, accept the default values:

PromptRecommended value
Gateway port18789
Gateway bind addressLoopback (127.0.0.1)
Gateway access protectionToken (recommended)
Tailscale exposureOff
Gateway tokenGenerate a new token or reuse an existing one

OpenClaw supports connecting to messaging platforms including Discord, Slack, Telegram, WhatsApp, Signal, Microsoft Teams, Matrix, and many others.

When prompted:

Set up a chat channel now?

Choose:

  • Yes to configure a messaging platform immediately.
  • No to finish the installation and configure channels later.

You can add or update channels at any time after installation.

Start OpenClaw:

Terminal window
openclaw

or launch the default assistant directly:

Terminal window
openclaw crestodian

OpenClaw will use the CompactifAI model you configured during onboarding.

Try a simple prompt:

Hello! Which model are you using?

or

Write a Python function to calculate Fibonacci numbers.

If the model responds successfully, OpenClaw is communicating with CompactifAI correctly.

Requests are sent using the same OpenAI-compatible Chat Completions API described in Chat Completion.

IssueSolution
401 UnauthorizedVerify your CompactifAI API key from the Authentication page.
404 Model Not FoundEnsure the model ID exactly matches a deployed model from the Models Catalog.
Verification failedConfirm the API Base URL is correct and that the endpoint implements POST /v1/chat/completions.
Connection failedVerify the endpoint is reachable and includes the /v1 suffix.
Streaming errorsEnsure your deployment supports Server-Sent Events (SSE) for streaming responses.
Gateway unavailableVerify that the local gateway is listening on 127.0.0.1:18789, or rerun openclaw onboard --classic.

For details about request and response formats, see Chat Completion and the API Reference.