SimpleChat:JS: MultiChat initial skeleton

Will help maintain multiple independent chats in future
This commit is contained in:
HanishKVC 2024-05-20 22:38:36 +05:30
parent af621975bb
commit 9b97feab45

View file

@ -218,6 +218,29 @@ let gChatURL = {
}
const gbCompletionFreshChatAlways = true;
class MultiChat {
constructor() {
/** @type {number} */
this.iChat = -1;
/** @type {SimpleChat[]} */
this.simpleChats = [];
/** @type {string[]} */
this.baseURLs = [];
}
/**
* Start a new chat
* @param {string} baseURL
*/
new_chat(baseURL) {
this.simpleChats.push(new SimpleChat());
this.baseURLs.push(baseURL);
this.iChat = this.simpleChats.length - 1;
}
}
function startme() {