Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Computer freezes when trying to call s2v_most_similar()

Open
#129 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
python

Research direction

Start by reviewing the s2v_most_similar() call, the downloaded-vector initialization, and the single-word synonym function shown in the issue images. Reproduce the freeze using the supplied example and input, then identify the cause and confirm that synonym lookup completes without freezing the computer.

Written by the indexing model from the issue text.

Description

I am trying to use sense2vec with my text processing project to automatically generate rules for matching, and I am having problems with attempts to find synonyms of words specified in a text file. For some reason, the entire computer freezes whenever I try to find synonyms. I tried to write the example code, and it works fine, though it did slightly stutter on model load. I tried to make the code as close to the example as possible, but for some reason it still doesn't prevent freezing.

This is the code initializing the vectors downloaded:
image

This is the code where the function is called:
image

This is my synonym function, also a modified version of one of the examples( I don't need any token but the first since the string that gets passed only consists of one word anyway):
image

I also tried to double check the exact values that get passed to the function, but that didn't yield any results either. As the image shows, the word that gets passed into the function is not some unusual string either, and the documentation doesn't mention any freezing issues, which is why I thought I would seek help here.

Dominant language
Python
Stars
1.7k
Forks
236
PR merge metrics
No merged PRs in 30d

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from explosion/sense2vec

All issues in explosion/sense2vec

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.