refactor: drop legacy session store keys
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { normalizeChatType } from "../../channels/chat-type.js";
|
||||
import { resolveConversationLabel } from "../../channels/conversation-label.js";
|
||||
import type { MsgContext } from "../templating.js";
|
||||
import { formatInboundBodyWithSenderMeta } from "./inbound-sender-meta.js";
|
||||
import { normalizeInboundTextNewlines } from "./inbound-text.js";
|
||||
|
||||
export type FinalizeInboundContextOptions = {
|
||||
@@ -55,5 +56,13 @@ export function finalizeInboundContext<T extends Record<string, unknown>>(
|
||||
normalized.ConversationLabel = explicitLabel;
|
||||
}
|
||||
|
||||
// Ensure group/channel messages retain a sender meta line even when the body is a
|
||||
// structured envelope (e.g. "[Signal ...] Alice: hi").
|
||||
normalized.Body = formatInboundBodyWithSenderMeta({ ctx: normalized, body: normalized.Body });
|
||||
normalized.BodyForAgent = formatInboundBodyWithSenderMeta({
|
||||
ctx: normalized,
|
||||
body: normalized.BodyForAgent,
|
||||
});
|
||||
|
||||
return normalized;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user