-
I have deployed a model locally using Ollama, and when I run it in vscode with python=3.12, I encountered the following Runtime error, which seems to be related to synchronization or asynchronization. I have checked that the local model runs normally and can be invoked properly. But I'm not sure where the problem occurred. Thank you all for your guidance. My code is
|
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
There are two similar unsolved discussions related to your issue:
Your issue seems to be related to the
These steps should help you troubleshoot and potentially resolve the issue with the To continue talking to Dosu, mention @dosu. Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other |
Beta Was this translation helpful? Give feedback.
-
Hello @wuyang910 ! Have you seen this discussion.
|
Beta Was this translation helpful? Give feedback.
-
Hello @wuyang910 , That's very weird. I am able to reproduce your error. However, the error doesn't exist when using other providers. I think the issue is on how |
Beta Was this translation helpful? Give feedback.
Thank you @maykcaldas
I run the code in vscode with the format of ".py". I try to add nast_asyncio to the beginning of my ".py". But the Runtime error still exists. I follow your advice, I try to run the code in a jupyter notebook with adding the code
to the beginning of my notebook. It works well. But I still don‘t understand what's the problem of runnming Doc synchronously in the format of ".py"
So I read the document of usage of paperqa in Pypi again carefully. This is the link https://pypi.org/project/paper-qa/ . I try to use Doc asynchronously in “.py”,it then works well.
My code as follows: