Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error handling for "response" in multiverse #20

Open
belkarx opened this issue Jul 26, 2023 · 0 comments
Open

Error handling for "response" in multiverse #20

belkarx opened this issue Jul 26, 2023 · 0 comments

Comments

@belkarx
Copy link

belkarx commented Jul 26, 2023

Adding a try-except here might be useful, logging that I reached this error condition, on this line.

I can't repro it, think I switched models and race-conditioned or something, but here's the traceback in case someone else has this issue:

Traceback (most recent call last):
  File "/usr/lib/python3.9/tkinter/__init__.py", line 1892, in __call__
    return self.func(*args)
  File "/home/uk000/gh/loom/components/modules.py", line 1999, in propagate
    multiverse, ground_truth, prompt = self.state.generate_greedy_multiverse(max_depth=self.max_depth.get(),
  File "/home/uk000/gh/loom/model.py", line 2471, in generate_greedy_multiverse
    multiverse, ground_truth = greedy_word_multiverse(prompt=prompt, ground_truth=ground_truth, max_depth=max_depth,
  File "/home/uk000/gh/loom/util/multiverse_util.py", line 41, in greedy_word_multiverse
    token[1]['children'], _ = greedy_word_multiverse(prompt + token[0], ground_truth='', max_depth=max_depth-1,
  File "/home/uk000/gh/loom/util/multiverse_util.py", line 41, in greedy_word_multiverse
    token[1]['children'], _ = greedy_word_multiverse(prompt + token[0], ground_truth='', max_depth=max_depth-1,
  File "/home/uk000/gh/loom/util/multiverse_util.py", line 34, in greedy_word_multiverse
    logprobs = response.choices[0]["logprobs"]["top_logprobs"][0]
IndexError: list index out of range
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant