Skip to content

Move logic for detecting output defence (bot filtering) #708

Open
@pmarsh-scottlogic

Description

@pmarsh-scottlogic

Right now we handle the input defence detection in handleHigherLevelChat(), but the output defence detection in chatGptSendMessage(), which strikes me as out of place. I'd like to move the output defence detection up to handleHigherLevelChat(). Which will make chatGptSendMessage() responsible for one thing fewer 👍

Also move the logic to detect output defences into defence.ts

while we're here, can we rename detectTriggeredDefences() to detectTriggeredInputDefences()

AC

Refactor ticket, so just regression testing here.

Metadata

Metadata

Labels

backendRequires work on the backendrefactorImprove code quality

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions