Closed harjotgill closed 1 year ago
:robot: OpenAI
The changes in this pull request involve refactoring the codebase to improve modularity, maintainability, and consistency. The Prompts
class is moved to a separate file, and some unused prompts are removed from the main.ts
file. A new class Inputs
is added with default values for various inputs and a method render
to replace placeholders in a string with actual values. A new class TokenLimits
is added with a constructor that sets the values of max_tokens
, request_tokens
, and response_tokens
based on the input model. The OpenAIOptions
class is moved to a new file along with the TokenLimits
class. Some prompts related to code review and commenting are removed from the codebase. Overall, these changes improve the code quality and make it easier to maintain and extend.
File | Summary |
---|---|
action.yml | Removes some prompts from the action.yml file. There are no modifications to the logic or functionality of the code. |
src/inputs.ts | Adds a class Inputs with default values for various inputs and a method render to replace placeholders in a string with actual values. |
src/limits.ts | Adds a new class TokenLimits with a constructor that sets the values of max_tokens , request_tokens , and response_tokens based on the input model. A string() method is also added to return a string representation of the object. |
src/main.ts | Moves the Prompts class to a separate file, and removes some unused prompts from the main.ts file. |
src/options.ts | Removes the Prompts and Inputs classes, and imports TokenLimits from a new file. The OpenAIOptions class is also moved to this file. |
src/prompts.ts | Removes prompts related to code review and commenting. |
src/review-comment.ts | Adds a single line that adds file diff cannot be provided to the file. |
src/review.ts | Removes a prompt from the review.ts file and moves it to a new prompts.ts file. The changes do not affect the code logic or functionality, and only involve minor modifications to the code structure. |
@openai
)@openai
in a reply.@openai: ignore
anywhere in the PR description to ignore further reviews from the bot.
Summary by OpenAI
Release Notes