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

react-ai-faq-chat

v1.1.2

Published

A smart AI-powered FAQ chatbot

Readme

react-ai-faq-chat

🚀 Turn your documentation into a smart AI-powered FAQ chatbot in minutes – no backend, no APIs, 100% free.


🔹 Why Use This Package?

Imagine your users opening your Help Center and asking questions like:

“How do I reset my password?”
“Where can I find the latest API docs?”

…and instantly getting answers from your own PDFs, Word docs, or Excel sheets – without building complex AI systems or paying for APIs.

react-ai-faq-chat does all the heavy lifting for you:

  • Scans your documentation files
  • Indexes them for fast answers
  • Uses a free, local AI model (Mistral-7B) to reply intelligently
  • Works out-of-the-box in React and Next.js

All in one tiny package. 💡


🔹 Key Features

  • Supports PDF, Word (.docx), and Excel (.xlsx)
  • Ephemeral chat – conversation exists while the page is open
  • No database required
  • No API keys, 100% free
  • React + Next.js compatible
  • Minimal config: just point to your docs folder
  • Provides hook + ready-to-use ChatBot component

🔹 Installation

npm install react-ai-faq-chat

or

yarn add react-ai-faq-chat

🔹 Usage

Simply point docsFolder to the folder containing your PDF, Word, or Excel documentation. That’s it.

Using the Hook

import { useAIFAQChat } from "react-ai-faq-chat";

export default function CustomChat() {
  const { messages, sendMessage, loading } = useAIFAQChat({ docsFolder: "./public/docs" });

  return (
    <div>
      {messages.map((msg, idx) => (
        <p key={idx} style={{ textAlign: msg.user ? "right" : "left" }}>{msg.text}</p>
      ))}
      <input
        placeholder="Ask me anything..."
        onKeyDown={async (e) => {
          if (e.key === "Enter") await sendMessage((e.target as HTMLInputElement).value);
        }}
      />
      {loading && <p>Loading...</p>}
    </div>
  );
}

Perfect if you want to build a custom UI for your chatbot.


🔹 How It Works (Simplified)

  1. The package reads all your docs (PDF, Word, Excel)
  2. Splits them into small chunks for AI understanding
  3. Indexes them in a fast local vector database (FAISS)
  4. Uses Mistral-7B AI (completely local, free) to answer questions
  5. Returns answers in real-time to your React app

All this happens behind the scenes, no AI or backend setup required.


🔹 Who Should Use This

  • Product teams that want instant FAQ chatbots
  • Customer support portals
  • Developers who want zero-cost AI integration
  • Anyone who has documentation in PDF, Word, or Excel

🔹 Why It's Different

| Feature | react-ai-faq-chat | Other Solutions | |---------|-----------------|----------------| | Local AI (free) | ✅ | ❌ | | Works without backend | ✅ | ❌ | | Supports multiple doc types | ✅ | ❌ | | Easy React integration | ✅ | ❌ | | Ephemeral chat | ✅ | ❌ |


🔹 Minimal Config

All you need is:

{
  docsFolder: "./path-to-your-docs"
}

No API keys, no setup, no fuss.


🔹 License

MIT © 2025


🔹 Ready to Try?

npm install react-ai-faq-chat

Then drop it in your React/Next.js page and watch your docs come alive! 🚀