INNER CODE UNIT · JavaScript

dif

kxxt/chatgpt-action · prompt.js:17

        let dif = prev + cur;
        if (dif.length > limit) {
          const header = diff.split("\n", 1)[0];
          const info = "This diff is too large so I omitted it for you.";
          splits.push(`${header}\n${info}`);
        } else splits.push(dif);
      }
      return cur;
    });

  return {
    welcomePrompts: [
      `Here is a pull request. Please assume you are a reviewer of this PR. First I will tell you the title and body of the PR. Please greet the PR author if you have done reading.
The title is ${title}
The remaining part is the body.
${body}`,
      `Now I will give you the changes made in this PR one file at a time.
When a diff is too large, I will omit it and tell you about that.`,

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…