Fix LLM connection problems in Noulek

Problem

Search or Chat fails, or Settings → LLM shows Not connected. Test connection reports a failure or you cannot save settings.

What it means

Noulek cannot call the configured OpenAI model. Chat and RAG answers need a valid OpenAI API Key and Model in Settings → LLM. Embeddings for retrieval use the same API key.

Checks to perform

  1. Open Noulek AI → Settings → LLM.
  2. Confirm the status pill shows Connected (not Not connected).
  3. Verify OpenAI API Key is saved (the field may show a placeholder like (key saved — leave blank to keep)).
  4. Confirm a Model is selected (Luna, Terra, or Sol tier).
  5. Click Test connection and read the inline result.

LLM settings and connection status

Common messages from Test connection:

Message Likely cause
Connection failed: OpenAI API key is required. Save your key before testing. No API key stored
Connection failed: LLM model is required. Select and save a model before testing. Model not saved
Connection test failed (with provider detail) Invalid key, network issue, or provider error
  1. If Chat shows a configuration error, open Settings → Activity log and look for llm_connection_test_failed or NX_LLM_CALL_FAILED entries.

How to resolve

  1. Paste a valid OpenAI API Key and click Save changes.
  2. Select a Model and save again if you changed it.
  3. Run Test connection until it succeeds.
  4. Retry Search or Chat on Search & Chat or your front-end widget.

If you cleared the key accidentally, use Remove API key only when you intend to delete it, then save a new key.

Expected result

Settings → LLM shows Connected. Test connection succeeds. Search and Chat can generate answers when Vector DB and indexed documents are also ready.

LLM alone is not enough for RAG answers. Also verify Settings → Vector DB and documents in Ready status. See Vector Database connection problems and Search or Chat returns no useful results.