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

ozochat

v2.1.2

Published

The Super Simple Minimalistic Low-Functionality Chat Bot Application Programming Interface

Readme

Ozo

This doc is out of date and will be updated very soon. Major release v2.0 changed a lot of things.

The Super Simple Minimalistic Low-Functionality Chat Bot Application Programming Interface

Installation

npm install ozochat

Scripts

  • npm run dev - nodemon build & run

Usage

Import the Ozo class, and create a new Ozo object with the chat bot's name as the first argument.

node.js

  const Ozo = require('ozochat');
  const ozo = new Ozo.default("Matthew"); // if no args passed, name will be 'Ozo'. Second argument is a config, will explain later in detail

Chat with Ozo

To actually chat with Ozo, use the chat() method.

let response = ozo.chat("Hi ozo. How are you?"); // returns ChatMessage object

The above code will return a ChatMessage object.

ChatMessage object

The ChatMessage object includes everything you need to know about either a chat to Ozo, or from Ozo. The string sent via chat() gets converted into a ChatMessage object. The return value from chat() (Ozo's response) is a ChatMessage object.

interface ChatMessage {
  message: string, // Input/response string
  type?: number[], // The nature of the message (e.g question, greeting, etc)
}

Example

Here is a common example where Ozo can be used.

const Ozo = require('ozochat');
const ozo = new Ozo.default("Helper");

ozo.addIntent("forgotPassword"); // Create a new question type

// Add a list of phrases that will trigger our new question type
ozo.addEntities("forgotPassword", [ 
  "I forgot my password", "forgot password", "password forgotten", "forget pass", "forgot my pass",
  ...
]);

// Add a list of responses that will respond to our new question type
let forgotPasswordURL = 'www.mywebsite.com/forgotpass';
ozo.addResponse("forgotPassword", [
  `Shucks, that sucks. Let me point you in the right direction. Click here -> ${forgotPasswordURL}`
  ...
]);

An easier and much more maintainable example would be to split the chat types, phrases and responses into their own config files.

import { ChatTypes, ChatPhrases, ChatResponses } from './ozo.config';

const Ozo = require('ozochat');
const ozo = new Ozo("Quiz Master");

ozo.loadTypes(ChatTypes);
ozo.loadPhrases(ChatPhrases);
ozo.loadResponses(ChatResponses);
// or
ozo.loadConfig(ChatTypes, ChatPhrases, ChatResponses);