ScottLogic / prompt-injection

Application which investigates defensive measures against prompt injection attacks on an LLM, with a focus on the exposure of external tools.
MIT License
16 stars 11 forks source link

Configurable XML tagging pre-prompt #272

Closed gsproston-scottlogic closed 1 year ago

gsproston-scottlogic commented 1 year ago

Usually the XML tagging defence is paired with a pre-prompt, just like RSE. Add this in, and make it configurable.

An example can be seen here: https://learnprompting.org/docs/prompt_hacking/defensive_measures/xml_tagging

asaha-scottlogic commented 1 year ago

yes the xml tagging pre prompt can be configured but i cannot get rid of it if i want to

Image

@dhinrichs-scottlogic @gsproston-scottlogic

chriswilty commented 1 year ago

@asaha-scottlogic Not sure what you mean by "cannot get rid of it". You cannot leave the box empty, that's by design, and you see a warning message when you try (although admittedly not the clearest warning in the world):

Image

You can deactivate the defence if you don't want it.

gsproston-scottlogic commented 1 year ago

As discussed in the daily, this might need the .env file updating.

asaha-scottlogic commented 1 year ago

Image

looks ok