Summarization
Transformers
PyTorch
bart
text2text-generation
summary
booksum
long-document
long-form
lsg
custom_code
Instructions to use ccdv/lsg-bart-base-4096-booksum with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ccdv/lsg-bart-base-4096-booksum with Transformers:
# Use a pipeline as a high-level helper # Warning: Pipeline type "summarization" is no longer supported in transformers v5. # You must load the model directly (see below) or downgrade to v4.x with: # pip install "transformers<5.0.0" from transformers import pipeline pipe = pipeline("summarization", model="ccdv/lsg-bart-base-4096-booksum", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSeq2SeqLM tokenizer = AutoTokenizer.from_pretrained("ccdv/lsg-bart-base-4096-booksum", trust_remote_code=True) model = AutoModelForSeq2SeqLM.from_pretrained("ccdv/lsg-bart-base-4096-booksum", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
Download eval_results.json from ccdv/lsg-bart-base-4096-booksum: direct link, hf CLI and curl.
- Browser
- Download file 314 Bytes
-
https://huggingface.co/ccdv/lsg-bart-base-4096-booksum/resolve/main/eval_results.json
- Command line
-
hf download hf://ccdv/lsg-bart-base-4096-booksum/eval_results.json
-
curl -L -o eval_results.json https://huggingface.co/ccdv/lsg-bart-base-4096-booksum/resolve/main/eval_results.json
314 Bytes
| { | |
| "eval_gen_len": 427.6918, | |
| "eval_loss": 3.2653846740722656, | |
| "eval_rouge1": 33.9468, | |
| "eval_rouge2": 6.7034, | |
| "eval_rougeL": 16.7879, | |
| "eval_rougeLsum": 31.7677, | |
| "eval_runtime": 2910.3841, | |
| "eval_samples": 1431, | |
| "eval_samples_per_second": 0.492, | |
| "eval_steps_per_second": 0.062 | |
| } |