Skip to content

Commit

Permalink
openai api test 14
Browse files Browse the repository at this point in the history
  • Loading branch information
davecthomas committed Mar 13, 2024
1 parent f783fe6 commit 8ac4216
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion dist/index.js

Large diffs are not rendered by default.

18 changes: 9 additions & 9 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -154,15 +154,15 @@ export async function run(): Promise<void> {
// fetchOpenAIDescription(diff)
// }

const diffsJoined: string = diffs.join("\n")
const encodedDiff = Buffer.from(diffsJoined).toString("base64")
core.setOutput("encodedDiffs", encodedDiff)
core.setOutput("filesList", filenames.join(", "))
core.setOutput("countFiles", filenames.length.toString())
// const openAiConfiguration = new Configuration({
// apiKey: apiKey,
// })
// const openai = new OpenAIApi(configuration)
// const diffsJoined: string = diffs.join("\n")
// const encodedDiff = Buffer.from(diffsJoined).toString("base64")
// core.setOutput("encodedDiffs", encodedDiff)
// core.setOutput("filesList", filenames.join(", "))
// core.setOutput("countFiles", filenames.length.toString())
const openAiConfiguration = new Configuration({
apiKey: apiKey,
})
const openai = new OpenAIApi(openAiConfiguration)

// core.setOutput("diffs", diffsJoined)
// console.log(diffsJoined)
Expand Down

0 comments on commit 8ac4216

Please sign in to comment.