I'm working with openai to process a document, trying to send the response to my db. I don't have 'path' declared anywhere else in my code. What could possibly be causing this? Would appreciate any advice.
This was working perfectly last night when I was working with hugginface/llama instead.
Summary
The user is experiencing an error message related to a local variable 'path' referenced before assignment in their Python code. They are unsure what might be causing the issue, as they have not declared the variable elsewhere in their code. The error occurred while working with OpenAI and trying to send a response to a database. They are seeking advice on what could be causing the error. The user also mentions that the code was working fine when using hugginface/llama instead of OpenAI.
Solution: It seems like the variable 'path' is not being declared before it is being referenced in the code. To fix this, the user
Binyamin
Aug 30, 2023, 15:48
Where you've declared the path variable before that?
bladmist
Rank 1: Thread
Aug 30, 2023, 15:51
Haven't declared it anywhere else. These are my imports also, cannot see anything that may be creating the variable underneath.
bladmist
Rank 1: Thread
Aug 30, 2023, 15:52
Binyamin
Aug 30, 2023, 15:53
It's a bit more general Python issue
But you can't use the replace method on variable you havn't declare before
What it would replace?
bladmist
Rank 1: Thread
Aug 30, 2023, 15:58
Yeah, I get that. I'm just confused what might be causing this. I have to wait for my colab gpu to refresh so I can test this again with llama, cause it worked fine yesterday.