npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@negoziator/ai-commit

v1.2.139

Published

Writes your git commit messages for you with AI

Downloads

1,588

Readme


Table of Contents

Setup

A minimum of Node v20 is required. Check your Node.js version with node --version.

Installation

  1. Install AI-Commit:

    npm install -g @negoziator/ai-commit
    
  2. Retrieve your API key from OpenAI

    Note: This requires an OpenAI account. If you don't have one, you can sign up for a free trial.

  3. Set the key so aicommit can use it:

    aicommit config set OPENAI_KEY=<your token>

    This will create a .aicommit file in your home directory.

Upgrading

npm update -g @negoziator/ai-commit

Usage

CLI Mode

Use aicommit directly to generate a commit message for your staged changes:

git add <files...>
aicommit

Configuration

Manage configuration using the aicommit config command.

To get a configuration option value, use the command:

aicommit config get <key>

For example, to retrieve the API key, you can use:

aicommit config get OPENAI_KEY
> sk_1234567890

To set a configuration option, use the command:

aicommit config set <key>=<value>

Options

| Option | Default | Description | |---------------------|-----------------|---------------------------------------------------------------------------------------| | OPENAI_KEY | N/A | The OpenAI API key. | | locale | en | Locale for the generated commit messages. | | generate | 1 | Number of commit messages to generate. | | model | gpt-4o-mini | The Chat Completions model to use. | | timeout | 10000 ms | Network request timeout to the OpenAI API. | | max-length | 50 | Maximum character length of the generated commit message. | | type | "" | Type of commit message to generate. | | auto-confirm | false | Automatically confirm the generated commit message without user prompt. | | prepend-reference | false | Prepend issue reference from branch name to commit message. | | temperature | 0.2 | The temperature (0.0-2.0) is used to control the randomness of the output from OpenAI |

Maintainers

NegoZiatoR

Contributing

If you want to help fix a bug or implement a feature in Issues, checkout the Contribution Guide to learn how to setup and test the project.