Open akeslo opened 9 months ago
Lemme take a look into it !!
Fixed !! (:
@Sweetdevil144 Thanks for the efforts here, I am for some reason still seeing the error. Do you have an example youtube url that works?
Hey @akeslo. Can you try the following :
If you scrounge within fetchresults.js
, you'll find the lines :
model: "gpt-4-1106-preview",
// model: "gpt-3.5-turbo-16k",
Try degrading the model to gpt-3.5 The error arises because your current gpt key is not meant to work with gpt-4 because it requires an organisation's permission. After that, it should work perfectly fine.
Weird, I swapped that but same error.
Do I need to define anything more in my .env?
OPENAI_API_KEY=sk-xxxxkeyhere Rapid_API_KEY=355keyhere
I don't think I can catch that. Try one thing. log the API keys in your background in fetchresults.js and youtube.js and check whether they are correctly fetched or not. Try using the website Linked within the repository..I think the repository works pretty fine. If that too doesn't works, try logging all responses and errors recieved and sent to openai in API calls. Check if the captions are correctly fetched or not. Sometimes your keys expire so it's difficult to find errors. If nothing works try contacting me again. If possible, can you file a PR too given you find the cause of the problem? It would be a great contribution to our repository. Also, try using nodemon instead of node.
@Sweetdevil144 Is this supposed to work on all youtube URLs or is there a specific requirement from a caption perspective? I've tried it across several but no luck even with the website linked in the repo. Same error from the website:
Thanks for insights @akeslo. Let me take a look into this issue.
Is this supposed to work on all youtube URLs
Yes, this is supposed to work on all shorts.
Seems like my credits of openai have expired on the website. I've improved the log messages on the source code. Can you verify it with your code logs again?
Any updates @akeslo ?
Sorry for the delay @Sweetdevil144, I am still seeing the same error with the latest code:
╰─$ node app.js Server is running on port 3000 transcript fetched Caught error in app.js An Error occurred -> TypeError: captions is not iterable transcript fetched Caught error in app.js An Error occurred -> TypeError: captions is not iterable