-
Notifications
You must be signed in to change notification settings - Fork 52
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
Custom route.ts pointing to local gpt4free: shifted linenumbers -> suddenly added AI response? :-) #15
Comments
I have a change request. Can you append a marker ex: ... The question to ask: |
That wasn't included in the examples I ran. Can you please confirm which model you're using? It's possible you can get away with just appending "ONLY include the translation in the response" to the prompt. |
"ONLY include the translation in the response": I already tested that as question to the AI. Now I am not a full developper, I like to play around with someone code, like changing parameters.
So you are not expecting a polite answer and clarification from the friendly AI :-)
|
I didn't changed anything else so I suppose you were looking for |
My setup in route.ts
...
// const response = await fetch("https://api.openai.com/v1/chat/completions", {
const response = await fetch("http://localhost:1337/v1/chat/completions", {
headers: {
"Content-Type": "application/json",
// Authorization:
Bearer ${process.env.OPENAI_API_KEY}
,},
...
Input File:
1
00:00:05,672 --> 00:00:07,674
Mr. Suero?
2
00:00:20,687 --> 00:00:22,272
Ah.
3
00:00:22,272 --> 00:00:25,275
Victor "Victory" Suero.
4
00:00:25,275 --> 00:00:26,777
Miles Sellars.
Output File:
1
00:00:05,672 --> 00:00:07,674
Certainly! Here is the translation to Dutch with the "
2
00:00:20,687 --> 00:00:22,272
" segment separator:
Meneer Suero?
3
00:00:22,272 --> 00:00:25,275
Ah.
4
00:00:25,275 --> 00:00:26,777
Victor "Victory" Suero.
Any Idea to fix this ?
The text was updated successfully, but these errors were encountered: