1.0.29 • Published 1 year ago

chriss v1.0.29

Weekly downloads
-
License
ISC
Repository
-
Last release
1 year ago

CHRISS

CHRISS is a computerised, humanoid, real-time & intelligent support system that has been expanded into a multipurpose chatbot system, made by Prozilla.

Using CHRISS you can create your own intuitive chatbot for your website, Discord bot or anything else that can import npm packages!

Some of its most outstanding features are: advanced sentence analysis that can understand gramatically incorrect sentences, the simulation of human emotions to make chatting more fun, high customizability that lets you change everything about the bot, ranging from a simple name to an entire vocabulary of words.

Installing

npm install chriss

Setting up a basic bot

Follow this small step by step guide to create a simple bot that can greet users:

  1. Create bot.js and write the following code inside:
// bot.js
import { Bot } from "chriss";

const name = "Example bot";
const responses = {
	// The key of the objects in this dictionary refer to the context value, 
	// this will be explained in detail later on
    0: [
        {
            input: ["hello"], // User input (case-insensitive)
            output: ["Hello."], // Bot ouput
            end: true, // This indicates the end of a conversation
        },
    ]
};

export const bot = new Bot(name, responses);
  1. Create index.js and write the following code inside:
// index.js
import { bot } from "bot.js";

// In a real bot, the following code would run every time the user sends a message,
// where input refers to the user's input and response to the bot's output, which is then sent back to the user
const input = "hello";
const response = bot.getResponse(input); 

// Log the response to the output
console.log(response);
  1. To test your brand new bot, run the following command:
node index.js
  1. You should see the following output logged to the console:
{
	output: "Hello.",
	input: {
		content: "hello",
		analysis: Sentence {
			isSentence: false,
			isNegative: false,
			isQuestion: false,
			questionWord: undefined,
			verb: undefined,
			subject: undefined,
			directObject: undefined,
			keyWord: "hello"
		}
	},
	mood: { happy: 100, sad: 0, angry: 0, scared: 0 },
	context: 0
}
1.0.26

1 year ago

1.0.25

1 year ago

1.0.24

1 year ago

1.0.23

1 year ago

1.0.29

1 year ago

1.0.28

1 year ago

1.0.27

1 year ago

1.0.22

1 year ago

1.0.21

1 year ago

1.0.20

1 year ago

1.0.19

1 year ago

1.0.18

1 year ago

1.0.17

1 year ago

1.0.16

1 year ago

1.0.15

1 year ago

1.0.14

1 year ago

1.0.13

1 year ago

1.0.12

1 year ago

1.0.11

1 year ago

1.0.10

1 year ago

1.0.9

1 year ago

1.0.8

1 year ago

1.0.7

1 year ago

1.0.6

1 year ago

1.0.5

1 year ago

1.0.4

1 year ago

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago