Commands: Add ask command

The ask command aims to ask another character about a question or
topic from the current chat. Essentially, the current chat is taken
out and prompted to another character.

This command also requires a few fixes to sprites and prompt creation.

Signed-off-by: kingbri <bdashore3@proton.me>
This commit is contained in:
kingbri
2023-10-16 02:12:12 -04:00
parent 2a16d24760
commit dfa25a1796
3 changed files with 109 additions and 22 deletions

View File

@@ -3548,7 +3548,7 @@ export function getBiasStrings(textareaText, type) {
*/
function formatMessageHistoryItem(chatItem, isInstruct, forceOutputSequence) {
const isNarratorType = chatItem?.extra?.type === system_message_types.NARRATOR;
const characterName = (selected_group || chatItem.force_avatar) ? chatItem.name : name2;
const characterName = chatItem?.name ? chatItem.name : name2;
const itemName = chatItem.is_user ? chatItem['name'] : characterName;
const shouldPrependName = !isNarratorType;