Skip to content

[BUG] VectorCode process killed due to timeout #121

Closed

Description

@edmondop

"VectorCode process killed due to timeout." appears to me when running :lua require("vectorcode").query("mysql") or similar commands. I am running chromadb 0.6.3 in docker-compose mode using 1 core.

vectorcode query mysql -n 3  36.64s user 4.87s system 137% cpu 30.214 total
 vectorcode ls
Project Root      Collection Size    Number of Files  Embedding Function
--------------  -----------------  -----------------  ------------------------------------
~/code/my_proj                176                 88  SentenceTransformerEmbeddingFunction

sounds like a really long time, how can I troubleshoot it?

Activity

  1. added
    bug
    on May 4, 2025
  2. Davidyz commented on May 5, 2025

    @Davidyz
    Owner

    Hi, if you've got spare cpu cores it might help to allocate more cpu cores to the chromadb process because the query is compute-intensive.

    Alternatively, you can also try a different embedding model that produces lower embedding dimensions (the default all-MiniLM-L6-v2 model produces 384-dimension vectors, which is already on the lower end of the spectrum). Some models that produce high-dimensional embeddings claims to perform well even if you truncate the embeddings (that is, getting rid of some dimensions so that they become low-dimensional). snowflake-arctic-embed-m-v2.0 mentioned this on their huggingface page. To use this model with truncation, you can use the following config:

    {
      "embedding_params": {
        "model_name": "Snowflake/snowflake-arctic-embed-m-v2.0",
        "truncate_dim": 256,  // this truncate the embeddings to 256 dimensions
      }
    }
  3. Davidyz commented on May 5, 2025

    @Davidyz
    Owner

    Moving this to discussion for now. We can open a new issue if we find a specific thing (eg. a poorly written piece of code) that is slowing things down.

  4. Repository owner locked and limited conversation to collaborators on May 5, 2025
  5. converted this issue into a discussion #122 on May 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions