Closed pelikhan closed 2 weeks ago
/genai-describe
/genai-review
.env
file template.However, there are a couple of areas which could be improved:
In the cli.ts
file, the async keyword is added to the preAction
hook. However, it's unclear if the parent function that calls this hook can handle promises or async operations. If the parent function can't handle promises, this could lead to unhandled promise rejections.
In the constants.ts
file, the GITHUB_PULLREQUEST_REVIEW_COMMENT_LINE_DISTANCE
constant is added but it's not clear how this constant is used. If this is an important configuration value, it might be better to put it into a configuration file or in environment variables.
Otherwise, LGTM :rocket:.
generated by pr-review
Environment variable to specify the default model for all scripts
GENAISCRIPT_DEFAULT_MODEL
andGENAISCRIPT_DEFAULT_TEMPERATURE
).modelId
is defined before it is used.NodeHost.install()
function has been updated to be async, and now includes a call to parse default settings from the environmental variables.githubCreatePullRequestReview
function to check the distance between lines when comparing with existing comments.expandTemplate
module have been updated to use the new default settings from the host.parseTokenFromEnv
function now handles parsing the default model from the environment variables..env
configuration handling has been improved, with additional checks and balances.