Discord: add trusted channel topics on new sessions
This commit is contained in:
@@ -173,6 +173,7 @@ export async function processDiscordMessage(ctx: DiscordMessagePreflightContext)
|
||||
const forumContextLine = isForumStarter ? `[Forum parent: #${forumParentSlug}]` : null;
|
||||
const groupChannel = isGuildMessage && displayChannelSlug ? `#${displayChannelSlug}` : undefined;
|
||||
const groupSubject = isDirectMessage ? undefined : groupChannel;
|
||||
const channelTopic = isGuildMessage ? channelInfo?.topic : undefined;
|
||||
const untrustedChannelMetadata = isGuildMessage
|
||||
? buildUntrustedChannelMetadata({
|
||||
source: "discord",
|
||||
@@ -334,6 +335,7 @@ export async function processDiscordMessage(ctx: DiscordMessagePreflightContext)
|
||||
SenderTag: senderTag,
|
||||
GroupSubject: groupSubject,
|
||||
GroupChannel: groupChannel,
|
||||
ChannelTopic: channelTopic,
|
||||
UntrustedContext: untrustedChannelMetadata ? [untrustedChannelMetadata] : undefined,
|
||||
GroupSystemPrompt: isGuildMessage ? groupSystemPrompt : undefined,
|
||||
GroupSpace: isGuildMessage ? (guildInfo?.id ?? guildSlug) || undefined : undefined,
|
||||
|
||||
Reference in New Issue
Block a user