Skip to content

RooCode codesearch feature does not work with LM StudioΒ #4435

@christopherowen

Description

@christopherowen

App Version

3.19.4

API Provider

LM Studio

Model Used

nomic-embed-code

πŸ” Steps to Reproduce

On MacOS Sequoia 15.5, using LM Studio 0.3.16.

LM Studio will produce errors during this Indexing Process of:

Unexpected endpoint or method. (POST /embeddings). Returning 200 anyway

testing the API with python returns a result and no error in the LM Studio console:

# Make sure to `pip install openai` first
from openai import OpenAI
client = OpenAI(base_url="http://localhost:1234/v1", api_key="lm-studio")

def get_embedding(text, model="nomic-embed-code"):
   return client.embeddings.create(input = [text], model=model).data[0].embedding

print(get_embedding("Once upon a time, there was a cat."))

Also, testing with curl produces a result and no error in the LM Studio console:

curl http://127.0.0.1:1234/v1/embeddings \
  -H "Content-Type: application/json" \
  -d '{
    "model": "text-embedding-nomic-embed-code",
    "input": "Some text to embed"
  }'

Steps to reproduce:

services:
  qdrant:
    image: qdrant/qdrant:latest
    restart: always
    container_name: qdrant
    ports:
      - 6333:6333
      - 6334:6334
    expose:
      - 6333
      - 6334
      - 6335
    configs:
      - source: qdrant_config
        target: /qdrant/config/production.yaml
    volumes:
      - ./qdrant_data:/qdrant/storage

configs:
  qdrant_config:
    content: |
      log_level: INFO
  • Visit RooCode Experimental features

  • Set Enable Codebase Indexing

  • Embeddings Provider: OpenAI Compatible

  • Base URL: http://localhost:1234 <- default LM Studio

  • API Key: fakekey

  • Model: nomic-embed-code

  • Embedding Dimension: tried both blank and 3584

  • Qdrant URL: http://localhost:6333

  • Qdrant Key: provided during Qdrant first launch

  • click Save

  • click Start Indexing

Some debugging that was attempted:

  • As I do not know what Dimensions are, I tried setting it to the qwen2.embedding_length of 3584.
  • I tried setting the context window of the model to 3584.

πŸ’₯ Outcome Summary

I expected the indexing operation to produce an index of my codebase. Instead there were errors during the indexing process in LM Studio and an empty index was produced in Qdrant with 0 Points, 8 Segments, and 1 Shard.

πŸ“„ Relevant Logs or Errors (Optional)

LM Studio Developer Logs:

2025-06-07 02:36:18 [DEBUG] 
Received request: POST to /embeddings with body  {
  "input": [
    "public function down()\n    {\n\n        $container =... <Truncated in logs> ...\n        $container['db']->query($query);\n\n\n\n    }",

( more lines of input... )

  ],
  "model": "nomic-embed-code",
  "encoding_format": "base64"
}
2025-06-07 02:36:18 [ERROR] 
Unexpected endpoint or method. (POST /embeddings). Returning 200 anyway

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions