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 🙏

© 2025 – Pkg Stats / Ryan Hefner

smart-commits-ai

v2.0.2

Published

AI-powered Git commit message generator - Pure Node.js implementation (no Python required)

Readme

Smart Commits AI - NPM Package

NPM Version Downloads

AI-powered Git commit messages for JavaScript/TypeScript projects

This NPM package provides a seamless way to use Smart Commits AI in Node.js, React, Next.js, Vue, and any JavaScript project without requiring Python knowledge.

🚀 Quick Start

Global Installation

npm install -g smart-commits-ai
smart-commits-ai install

Project Installation

npm install --save-dev smart-commits-ai
npx smart-commits-ai install

One-Time Use

npx smart-commits-ai install

📦 Package.json Integration

Add to your project's package.json:

{
  "devDependencies": {
    "smart-commits-ai": "^1.0.4"
  },
  "scripts": {
    "postinstall": "smart-commits-ai install",
    "commit": "git commit",
    "setup-ai": "echo 'GROQ_API_KEY=your_key_here' >> .env"
  }
}

🔧 Setup

  1. Get API Key (free): https://console.groq.com/keys
  2. Add to environment:
    echo "GROQ_API_KEY=your_key_here" >> .env
  3. Install Git hook:
    npx smart-commits-ai install

💡 Usage

# Normal Git workflow - AI generates commit messages
git add src/components/Button.tsx
git commit  # AI generates: "feat(components): add Button component with TypeScript support"

# Manual generation
npx smart-commits-ai generate

# Check status
npx smart-commits-ai status

🎯 Perfect For

  • React Projects: Component and hook changes
  • Next.js Apps: Page and API route updates
  • Vue Applications: Component and store modifications
  • Node.js APIs: Endpoint and middleware changes
  • TypeScript Projects: Type definition updates
  • Any JavaScript Project: Universal compatibility

🔧 Configuration

Create .commitgen.yml in your project root:

api:
  provider: groq

commit:
  max_chars: 250
  types:
    - feat      # New features
    - fix       # Bug fixes
    - refactor  # Code refactoring
    - style     # Styling changes
    - test      # Adding tests
    - docs      # Documentation
    - chore     # Maintenance

  scopes:
    - components  # React/Vue components
    - pages       # Next.js pages
    - api         # API routes
    - hooks       # Custom hooks
    - utils       # Utility functions
    - styles      # CSS/styling
    - config      # Configuration

🏢 Team Setup

Automatic Setup for New Team Members

{
  "scripts": {
    "postinstall": "smart-commits-ai install || echo 'Please add GROQ_API_KEY to .env'"
  }
}

CI/CD Integration

# .github/workflows/commits.yml
name: AI Commit Messages
on: [push, pull_request]
jobs:
  ai-commits:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - uses: actions/setup-node@v3
        with:
          node-version: '18'
      - run: npm install smart-commits-ai
      - run: npx smart-commits-ai generate --dry-run
        env:
          GROQ_API_KEY: ${{ secrets.GROQ_API_KEY }}

🆘 Troubleshooting

"Python not found"

The package automatically installs the Python dependency. If you encounter issues:

# Install Python 3.8+
# macOS: brew install python
# Windows: winget install Python.Python.3
# Ubuntu: sudo apt install python3 python3-pip

# Then retry
npm install smart-commits-ai

"Command not found"

# Use npx for one-time execution
npx smart-commits-ai --help

# Or install globally
npm install -g smart-commits-ai

🔗 Links

  • Main Repository: https://github.com/Joshi-e8/ai-commit-generator
  • PyPI Package: https://pypi.org/project/smart-commits-ai/
  • Documentation: https://github.com/Joshi-e8/ai-commit-generator/blob/main/README.md

📄 License

MIT License - see LICENSE


Transform your JavaScript team's commit messages today! 🚀