Skip to content

Commit

Permalink
Create nexus_aipowered_chatbot.js
Browse files Browse the repository at this point in the history
  • Loading branch information
KOSASIH authored Jul 12, 2024
1 parent 837e781 commit dc86d03
Showing 1 changed file with 17 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import { Chatbot } from 'rivescript';

class NexusAIPoweredChatbot {
constructor() {
this.bot = new Chatbot();
this.bot.load('nexus_chatbot.rive');
}

respond(input) {
return this.bot.reply('localuser', input);
}
}

const chatbot = new NexusAIPoweredChatbot();

// Example usage:
console.log(chatbot.respond('Hello, how are you?'));

0 comments on commit dc86d03

Please sign in to comment.