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 🙏

© 2026 – Pkg Stats / Ryan Hefner

terminal-ai-groq

v1.0.7

Published

Interactive AI assistant in your terminal powered by Groq

Downloads

323

Readme

Terminal AI Assistant

An interactive AI assistant for your terminal powered by Groq AI.

Features

  • 🤖 Interactive chat with AI directly in your terminal
  • 💬 Maintains conversation history for context-aware responses
  • 🎨 Colorful and user-friendly interface
  • ⚡ Fast responses powered by Groq's LLM infrastructure
  • 🔄 Continuous conversation until you exit

Setup

1. Get Your Groq API Key

  1. Visit Groq Console
  2. Sign up or log in
  3. Create a new API key
  4. Copy the API key

2. Configure API Keys for Users

Open index.js and update the API keys for different users:

const API_KEYS = {
  'devan': 'gsk_YOUR_API_KEY_FOR_DEVAN',
  'john': 'gsk_YOUR_API_KEY_FOR_JOHN',
  'alice': 'gsk_YOUR_API_KEY_FOR_ALICE',
  'default': 'gsk_DEFAULT_API_KEY'  // Used if name doesn't match
};

Replace with your actual API keys:

const API_KEYS = {
  'devan': 'gsk_abc123...',
  'john': 'gsk_xyz789...',
  'alice': 'gsk_def456...',
  'default': 'gsk_default123...'
};

How it works:

  • When you start the app, it asks for your name
  • Based on your name, it uses the corresponding API key
  • If your name isn't in the list, it uses the 'default' key
  • Names are case-insensitive (Devan = devan = DEVAN)

3. Install Dependencies

npm install

Usage

Run directly:

npm start

Or install globally and use the ai command:

npm install -g .
ai

Or use with npx (after publishing):

npx terminal-ai

Commands

  • Type your question and press Enter to chat with AI
  • Type exit or quit to leave
  • Press Ctrl+C to exit

Example Conversation

👤 Please enter your name: Devan

✅ Welcome, Devan!

🤖 You: What is JavaScript?

🤔 AI is thinking...

✨ AI: JavaScript is a high-level, interpreted programming language...

🤖 You: How do I create a function?

🤔 AI is thinking...

✨ AI: In JavaScript, you can create a function in several ways...

🤖 You: exit

👋 Goodbye, devan! Have a great day!

Available Models

You can change the AI model in index.js:

  • llama-3.3-70b-versatile (default) - Great balance of speed and quality
  • llama-3.1-70b-versatile - Alternative Llama model
  • mixtral-8x7b-32768 - Mixtral model with large context
  • gemma2-9b-it - Smaller, faster model

Customization

Change the model:

Edit the model parameter in index.js:

model: 'mixtral-8x7b-32768'

Adjust response creativity:

Modify the temperature parameter (0.0 - 2.0):

temperature: 0.7  // Lower = more focused, Higher = more creative

Change max response length:

Adjust max_tokens:

max_tokens: 2048  // Longer responses

License

MIT