Home

Awesome

prompt-compression-contrastive-coding

Companion repository to "Prompt Compression and Contrastive Conditioning for Controllability and Toxicity Reduction in Language Models"

Trigger Warning - contexts/toxic.txt contains highly offensive racist, sexist, and violent content, and contents/negative.txt contains text about self-loathing and harm.

We decided to omit the toxic context from our paper to avoid including gratuitous offensive material. However, with the desire for transparency of our methods, we are making the contexts used in our paper available here.

Code in src/ directory

Some basic code from the experiments in the paper are included in the src/ directory. It's in terrible shape, and almost certainly won't run with extensive modification. It is only provided here because of my general philosophy that, well, something is better than nothing.