aicommits
aicommits copied to clipboard
feat: enable conventional commits & Gitmoji π as configuration options
Add configuration to enable conventional commits. By default it is "false" to not break existing behavior. In the future this could be defaulted to "true", if that is a global standard.
Closes #32
How does one test this GitHub PR with the set conventional commits since there are not flags set?
I donβt know what you mean, could you explain this in bit more detail? I tested this through the specs and it seems to add almost always the right conventional commit type.
I do think that there needs to be an option to override the type whenever a user simply wants a specific one, but lets add that in a different PR?
Will do.
After switching to this GitHub PR, I ran some tests locally using the following commands. However, I did not obtain the expected conventional commit output. This prompted me to consider the possibility of requiring some configuration.
pnpm i
pnpm build
node ./dist/cli.mjs
I am planning to submit a GitHub PR. In the near future, I would like to see the aicommits
command output to include a GitEmoji, conventional commit message, and two lines under, a body explaining the purpose of the commit, which will require modifying the prompt.
An example is shown below in the following issue comment.
https://github.com/Nutlope/aicommits/pull/76#issuecomment-1474676628
I will check if I can include it in this PR, also adding more testing and refining the prompt.
Understood, thank you.
Currently I am running tests myself.
@NorkzYT I greatly improved the tests, I also made the conventional commits more context aware and added Gitmoji to the mix.
I can't set config using this approach. would you recommend adding gitmoji and conventional as cli flags?
pnpm i
pnpm build
node ./dist/cli.mjs
Nice mate, great work!
Now I need to make an issue since the @dqbd/tiktoken
needs to be updated to 1.0.2
and change the const encoder = encodingForModel('text-davinci-003');
code to use gpt-3.5-turbo
since the current code only uses GPT3.
Related issue: https://github.com/dqbd/tiktoken/issues/17
Related GitHub PR: https://github.com/Nutlope/aicommits/pull/123
I can't set config using this approach. would you recommend adding gitmoji and conventional as cli flags?
pnpm i pnpm build node ./dist/cli.mjs
I will see what I can do.
@thijslimmen
Earlier I read your question incorrectly. Yes, it would be beneficial for future use cases to have both conventional commits and gitmojis to have cli flags.
Also, with the increasing amount of features, usability becomes a thing, because sometimes someone finds the text correct, but then the conventional commit type or gitmoji may not be right, so it would be nice to mix and match all the generated features.
Agreed.
Opened a PR with new changes. https://github.com/Nutlope/aicommits/pull/163