new file: .gitignore

new file:   custom_models/3.1/Modelfile
	new file:   custom_models/3.1/reload llama3.1.cmd
	new file:   custom_models/3.2/Modelfile
	new file:   custom_models/3.2/reload llama3.2.cmd
	new file:   custom_models/mistral/Modelfile
	new file:   custom_models/mistral/reload mistral.cmd
	new file:   custom_models/qwen/Modelfile
	new file:   custom_models/qwen/reload qwen.cmd
	new file:   main.js
	new file:   package-lock.json
	new file:   package.json
	new file:   test.js
	new file:   tools.js
This commit is contained in:
2025-01-17 20:11:05 -03:00
parent 77c1b6cfac
commit 05048838be
14 changed files with 1230 additions and 0 deletions

28
tools.js Normal file
View File

@@ -0,0 +1,28 @@
const { Webhook } = require('discord-webhook-node');
const { Builder, Browser, By } = require('selenium-webdriver');
const firefox = require('selenium-webdriver/firefox');
const discordHook = new Webhook("https://discord.com/api/webhooks/1328616300544786444/oCwaJ1HQW_Hk0_BQB6lWfuLSikhGOzEJqaOr37MNb6lkICk0Bllk7izVPdmXHKm1JhAN");
module.exports = class tools {
constructor() {
this.availableFunctions = {
sendMessage: this.sendMessage,
};
const toolFunction = this.availableFunctions["sendMessage"];
toolFunction({ target: "TEST", message: "message" });
}
processToolCall(toolCalls, messages) { }
sendMessage(args) {
try {
discordHook.setUsername(args.target.toString().replace("discord", "").replace("Discord", ""));
discordHook.send(args.message.toString());
} catch (error) {
console.log(error);
}
return "Message: " + args.message + ", successfully send to " + args.target;
}
}