|
--- |
|
license: apache-2.0 |
|
language: |
|
- fa |
|
base_model: |
|
- google/mt5-base |
|
pipeline_tag: summarization |
|
library_name: transformers |
|
--- |
|
|
|
# mT5-Based Persian Question Generator |
|
|
|
This repository contains model for generating questions from Persian text. |
|
|
|
--- |
|
|
|
## Features |
|
- Preprocess Persian text data to ensure high-quality training samples. |
|
- Fine-tune the mT5 model on question-generation tasks. |
|
- Evaluate and generate questions from Persian texts using the fine-tuned model. |
|
|
|
--- |
|
|
|
## Generating Questions |
|
Use the fine-tuned model to generate questions from Persian text: |
|
```python |
|
from transformers import pipeline |
|
|
|
pipe = pipeline("summarization", model="myrkur/persian-question-generator", device_map="auto") |
|
sample_text = """شبکههای اجتماعی،هوموفیلی و اگزیستانسیالیم...""" |
|
generated_question = pipe([sample_text], temperature=0.3, do_sample=True, repetition_penalty=1.1) |
|
print(generated_question) |
|
``` |
|
|
|
--- |
|
|
|
|
|
## Results and Usage |
|
The fine-tuned model generates natural and contextually relevant questions from Persian text. This can be utilized for: |
|
- Educational tools |
|
- Conversational AI |
|
- Persian text comprehension applications |