mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
Form new chat context
This commit is contained in:
@ -169,6 +169,7 @@ export {
|
||||
getStoppingStrings,
|
||||
getStatus,
|
||||
reloadMarkdownProcessor,
|
||||
getCurrentChatId,
|
||||
chat,
|
||||
this_chid,
|
||||
selected_button,
|
||||
@ -485,6 +486,15 @@ function reloadMarkdownProcessor(render_formulas = false) {
|
||||
return converter;
|
||||
}
|
||||
|
||||
function getCurrentChatId() {
|
||||
if (selected_group) {
|
||||
return groups.find(x => x.id == selected_group)?.chat_id;
|
||||
}
|
||||
else if (this_chid) {
|
||||
return characters[this_chid].chat;
|
||||
}
|
||||
}
|
||||
|
||||
const CHARACTERS_PER_TOKEN_RATIO = 3.35;
|
||||
const talkativeness_default = 0.5;
|
||||
|
||||
|
Reference in New Issue
Block a user