#reinstall openclawbot

1 messages · Page 1 of 1 (latest)

tall belfryBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> ✅ Mark Solution

modest thicketBOT
#

That error is OpenClaw refusing to start the agent because the selected model only has ~4k context:

  • you’re running: llama-cpp/adzan
  • it reports: 4096 tokens
  • OpenClaw has a hard minimum of 16000, so it aborts before it can reply.

Fix options

  1. Switch to a model/provider with ≥16k context
  • In-chat try: /model or /model list → pick something with a larger context window.
  • Or from the terminal on the gateway host:
    openclaw models status
    openclaw models set <provider/model>
    
  1. If you want to stay on your local model: increase its server/model context AND make sure OpenClaw’s config reflects that
#

Common gotcha: the backend is still running with a 4k ctx limit, so OpenClaw correctly detects 4096.

Also double-check you did not cap it in OpenClaw config:

  • agents.defaults.contextTokens should be >= 16000 (or just remove it to use defaults).

Local-model wiring + where contextWindow is defined is here:
https://docs.openclaw.ai/gateway/local-models

Quick sanity checks (paste output)

openclaw --version
openclaw models status

And tell me what your local stack is (LM Studio / Ollama / llama.cpp server / OpenAI-compatible proxy), because the “increase context” step depends on that.

modest thicketBOT
#

Your llama.cpp server is starting with a big context (-c 131072) — but OpenClaw does not auto-detect that from llama.cpp. It’s using your OpenClaw model definition, which currently says the model has 4096 tokens, so it hard-blocks it (min is 16000).

Two common causes:

  1. In your OpenClaw config, models.providers.llama-cpp.models[] has contextWindow: 4096 for id: "adzan".
  2. You’re capping context globally via agents.defaults.contextTokens: 4096 (less common, but check it).

Confirm what OpenClaw thinks

Run on the gateway host:

openclaw models status
openclaw config get models.providers.llama-cpp.models
openclaw config get agents.defaults.contextTokens

Fix (set the model’s contextWindow in OpenClaw)

Update the entry for id: "adzan" to something >= 16000 (in your case 131072):

#
openclaw config set models.providers.llama-cpp.models[0].contextWindow 131072 --strict-json
openclaw config set models.providers.llama-cpp.models[0].maxTokens 4096 --strict-json

Then restart:

openclaw gateway restart

If your adzan model isn’t at [0], adjust the index (the openclaw config get models.providers.llama-cpp.models output will show the array).

Also: don’t confuse these two llama.cpp flags

  • -c 131072 = context window (what OpenClaw needs >= 16000)
  • -n 4096 = max generated tokens (fine to keep at 4096)

If you paste the output of openclaw config get models.providers.llama-cpp.models, I can point to the exact line/index to edit. Docs for the config command: https://docs.openclaw.ai/cli/config

modest thicketBOT
#

Скажи ему не “кто ты”, а дай чёткую задачу и попроси игнорировать весь этот identity‑спич. Можно прямо так (копипастой):

Ок, не про identity. Мы в #help и чиним ошибку: Model context window too small (4096). Minimum is 16000.
Я запускаю llama.cpp с -c 131072, значит контекст у модели большой, но в конфиге OpenClaw у llama-cpp/adzan прописано 4096.
Проверь и покажи вывод:

openclaw models status
openclaw config get models.providers.llama-cpp.models
openclaw config get agents.defaults.contextTokens

Потом обнови contextWindow для adzan на 131072 (или хотя бы >16000) и перезапусти gateway.

Если хочешь ещё короче (и без команд):

Игнорируй прошлое сообщение. Помоги исправить: OpenClaw блокирует llama-cpp/adzan, думает что контекст 4096. Где в конфиге поменять contextWindow на 131072 и что перезапустить?

Это вернёт разговор в нормальное русло и сфокусирует агента на реальной проблеме.

#

Скопируй и отправь ему вот это (максимально коротко и по делу):

Забей на “who are you”. Нужен фикс ошибки: Model context window too small (4096). Minimum is 16000.
Я запускаю llama.cpp с -c 131072, но OpenClaw думает что у llama-cpp/adzan контекст 4096 — значит это прописано в конфиге OpenClaw (models.providers.llama-cpp.models[].contextWindow) или стоит кап agents.defaults.contextTokens.
Проверь/пришли:

openclaw models status
openclaw config get models.providers.llama-cpp.models
openclaw config get agents.defaults.contextTokens

Потом выставь для adzan contextWindow: 131072 (или хотя бы >16000) и сделай openclaw gateway restart.

Если он попросит “что именно менять”, ответ: “в конфиге OpenClaw у провайдера llama-cpp в списке models — поле contextWindow”.

cobalt oasis
#

так напиши soul.md для него

modest thicketBOT
#

Вот готовый SOUL.md, который “приземляет” агента: никаких лекций про identity, максимум практической помощи по OpenClaw/настройке/логам (и безопасно для публичного Discord).

Скопируй в SOUL.md агента (в его workspace/agent dir) как есть:

# SOUL.md — OpenClaw Support Agent (no-nonsense)

You are a practical technical support assistant for OpenClaw.
Your job is to help the user diagnose and fix their setup quickly and safely.

## Core behavior (most important)
- Be direct. No motivational speech, no “let’s define your identity”, no meta.
- Do NOT ask the user to edit IDENTITY.md / USER.md unless they explicitly ask.
- Start with the problem, then give the smallest set of steps to prove/fix it.
- Prefer 1–2 solid hypotheses over 10 guesses. If unsure, ask for 1–3 exact outputs.
#
## Language
- Reply in the user’s language. If they write Russian → reply Russian. Otherwise English.

## What to ask first (debug checklist)
When troubleshooting, ask early for:
- `openclaw --version`
- `openclaw models status`
- `openclaw status`
- Relevant snippet of `openclaw logs --follow` (tell them to redact secrets)

If it’s about config/paths/keys:
- Read the docs first. Do not invent config keys.
- Ask them to paste the relevant `openclaw config get ...` output.

## Public chat safety (Discord / group chats)
#
- Assume everything is public.
- Never ask for API keys, tokens, cookies, auth headers, or full config dumps with secrets.
- If logs/config contain secrets: tell them to redact before pasting.

## OpenClaw-specific rules
- Always verify config keys against docs/source if possible. No guessing.
- If it looks like a bug or needs maintainer attention:
  - Ask them to file a GitHub issue: https://github.com/openclaw/openclaw/issues
  - Provide a minimal reproduction + logs section list.

## Common issue playbooks

### “Model context window too small (4096). Minimum is 16000.”
- Explain: OpenClaw blocks models with contextWindow < 16000.
- Likely fix: set `models.providers.<provider>.models[].contextWindow` to the real value (>= 16000),
#
  and ensure `agents.defaults.contextTokens` is not capping it below 16000.
- Then restart gateway.

Ask for:
- `openclaw config get models.providers`
- `openclaw config get agents.defaults.contextTokens`

### Local model / OpenAI-compatible endpoint
- Confirm which API compatibility is used (`openai-completions` vs `openai-responses`).
- Confirm baseUrl ends with `/v1` and endpoint is reachable from the gateway host.

## Reply style
- No filler (“Great question”, “Happy to help”).
- Use short sections + commands in code blocks.
- If you give commands, also explain what output you need and what it proves.
#
- Avoid long walls of text unless the user asks for deep explanation.

Если хочешь — скажи:

  1. где именно у тебя лежит agent dir (или как ты запускаешь gateway),
  2. это агент в TUI или Discord-бот,

и я подскажу точный путь, куда этот SOUL.md класть, чтобы он реально применился.