transformers safetensors t5 text2text-generation license:mit autotrain_compatible endpoints_compatible text-generation-inference region:us
---
license: mit
---

# T5-Small-CTX-QGEN : Contextual Question Generation Model

This repository contains a trained T5-Small model for generating questions based on contextual input.

## Model Details

The model in this repository has been fine-tuned on the pre-trained [T5-Small](https://huggingface.co/google-t5/t5-small) model. It takes contextual input and generates questions relevant to the context.

## Inference Pipeline

You can use the pretrained model for generating questions using the `transformers` library's pipeline feature.

```python
from transformers import pipeline

# Load the pretrained model for inference
model = pipeline("text2text-generation", model="nsu-intellisphere/t5-small-ctx-qgen")

# Example usage
context = "According to their estimates the universe is 13.7 billion years old with an uncertainty of 200 million years."
question = model(context)[0]['generated_text']

print(f'Context: {context}')
print(f'Question: {question}')
```

## Example Output

- **Context:** According to their estimates the universe is 13.7 billion years old with an uncertainty of 200 million years.
- **Generated Question:** What is the universe's estimated age?
