Instructions to use bayan10/summarization-model with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use bayan10/summarization-model 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="bayan10/summarization-model")# Load model directly from transformers import AutoTokenizer, AutoModelForMultimodalLM tokenizer = AutoTokenizer.from_pretrained("bayan10/summarization-model") model = AutoModelForMultimodalLM.from_pretrained("bayan10/summarization-model") - Notebooks
- Google Colab
- Kaggle
Bayan Arabic Summarization Model
This repository contains the summarization checkpoint used by Bayan.
Recommended generation settings
Use the following defaults for the best balance of faithfulness and brevity:
summary = model.generate(
**inputs,
max_new_tokens=40,
num_beams=1,
do_sample=False,
early_stopping=False,
no_repeat_ngram_size=3,
repetition_penalty=1.1,
)
Notes
- The checkpoint is optimized for Arabic news-style summarization.
- Beam search and sampling may increase hallucination on some inputs.
- If a summary drifts too far from the source, prefer a more extractive fallback.
- Downloads last month
- -