diff --git a/src/main.ts b/src/main.ts index c3a596be..0619a1ef 100644 --- a/src/main.ts +++ b/src/main.ts @@ -11,6 +11,8 @@ const OPENAI_API_MODEL: string = core.getInput("OPENAI_API_MODEL"); const REVIEW_MAX_COMMENTS: string = core.getInput("REVIEW_MAX_COMMENTS"); const REVIEW_PROJECT_CONTEXT: string = core.getInput("REVIEW_PROJECT_CONTEXT"); +const MAX_TOKENS = 32768; + const octokit = new Octokit({ auth: GITHUB_TOKEN }); const configuration = new Configuration({ @@ -151,7 +153,7 @@ async function getAIResponse( const queryConfig = { model: OPENAI_API_MODEL, temperature: 0.2, - max_tokens: 700, + max_tokens: MAX_TOKENS, top_p: 1, frequency_penalty: 0, presence_penalty: 0,