princeton-nlp/AutoCompressor-2.7b-30k

Model

license: apache-2.0

2

4 commits

2 linked in READMEs

updated Oct 27, 2023

See the code

README

license: apache-2.0

Paper: Adapting Language Models to Compress Contexts

Code: https://github.com/princeton-nlp/AutoCompressors

Models:


AutoCompressor-2.7b-30k is a model fine-tuned from facebook/opt-2.7b following the AutoCompressor method in Adapting Language Models to Compress Contexts. This model is fine-tuned on 2B tokens from Books3 in The Pile. The pre-trained OPT-2.7b model is fine-tuned on sequences of 30,720 tokens with 50 summary vectors, summary accumulation, randomized segmenting, and stop-gradients.

To get started, download the AutoCompressor repository and load the model as follows:

from auto_compressor import AutoCompressorModel

model = AutoCompressorModel.from_pretrained("princeton-nlp/AutoCompressor-2.7b-30k")

Evaluation

We record the perplexity achieved by our 30k-fine-tuned OPT models on segments of 2048 tokens sampled from Books3 and ArXiv in The Pile, conditioned on different amounts of context.

Context Tokens014,33628,672
RMT-1.3b-30k13.1812.5012.50
AutoCompressor-1.3b-30k13.2112.4912.47
AutoCompressor-2.7b-30k11.8611.2111.18

Bibtex

@misc{chevalier2023adapting,
      title={Adapting Language Models to Compress Contexts}, 
      author={Alexis Chevalier and Alexander Wettig and Anirudh Ajith and Danqi Chen},
      year={2023},
      eprint={2305.14788},
      archivePrefix={arXiv},
      primaryClass={cs.CL}
}
endpoints_compatible
pytorch
text-generation-inference
transformers

princeton-nlp/AutoCompressor-2.7b-30k

Model

license: apache-2.0

2

4 commits

2 linked in READMEs

updated Oct 27, 2023

See the code

README

license: apache-2.0

Paper: Adapting Language Models to Compress Contexts

Code: https://github.com/princeton-nlp/AutoCompressors

Models:


AutoCompressor-2.7b-30k is a model fine-tuned from facebook/opt-2.7b following the AutoCompressor method in Adapting Language Models to Compress Contexts. This model is fine-tuned on 2B tokens from Books3 in The Pile. The pre-trained OPT-2.7b model is fine-tuned on sequences of 30,720 tokens with 50 summary vectors, summary accumulation, randomized segmenting, and stop-gradients.

To get started, download the AutoCompressor repository and load the model as follows:

from auto_compressor import AutoCompressorModel

model = AutoCompressorModel.from_pretrained("princeton-nlp/AutoCompressor-2.7b-30k")

Evaluation

We record the perplexity achieved by our 30k-fine-tuned OPT models on segments of 2048 tokens sampled from Books3 and ArXiv in The Pile, conditioned on different amounts of context.

Context Tokens014,33628,672
RMT-1.3b-30k13.1812.5012.50
AutoCompressor-1.3b-30k13.2112.4912.47
AutoCompressor-2.7b-30k11.8611.2111.18

Bibtex

@misc{chevalier2023adapting,
      title={Adapting Language Models to Compress Contexts}, 
      author={Alexis Chevalier and Alexander Wettig and Anirudh Ajith and Danqi Chen},
      year={2023},
      eprint={2305.14788},
      archivePrefix={arXiv},
      primaryClass={cs.CL}
}
endpoints_compatible
pytorch
text-generation-inference
transformers