9P9 / gpt4all-wrapper-js

just a wrapper for gpt4all https://github.com/nomic-ai/gpt4all/ for nodejs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

gpt4all-wrapper-js

This just provides a simple js wrapper around gpt4all.

Installation and Usage

You need to get gpt4all and put the gpt4.js and example.js in the chat folder.

import GPT4 from './gpt.js';

let GPT = new GPT4('./gpt4all-lora-quantized-OSX-m1');
GPT.on('ready',async ()=>{
  console.log(await GPT.ask("What is the capital of Korea?"));
  console.log(await GPT.ask("Are you an AI?"));
});

License

MIT

About

just a wrapper for gpt4all https://github.com/nomic-ai/gpt4all/ for nodejs


Languages

Language:JavaScript 100.0%