Downloads · 30 days
11
7% of all-time downloads
yakul259/fint5-financeqa-customised
fint5-financeqa-customised is a machine learning model from yakul259. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as mit.
Downloads · 30 days
11
7% of all-time downloads
All-time downloads
169
Public
Parameters
60.5M
243 MB on disk
Likes
1
Public
Click a slice to open those files.
.safetensors242 MB · 100%
From the Hugging Face model README
Model Name: fint5-financeqa Base Model: t5-small Domain: Financial Question Answering Fine-tuned by: [Your Name] Training Environment: Google Colab License: MIT (inherits from t5-small)
fint5-financeqa is a fine-tuned version of the t5-small model, tailored for financial question-answering tasks using the sweatSmile/FinanceQA dataset.
The model is capable of answering domain-specific questions when given both the question and relevant context. This makes it suitable for chatbot assistants, enterprise finance automation, or as a component in investment-related QA systems.
You can use this model to:
Not recommended for:
| Detail | Value |
|---|---|
| Base Model | t5-small |
| Dataset | sweatSmile/FinanceQA |
| Dataset Size | 3705 total entries (80/20 split) |
| Preprocessing | QUERY + context: CONTEXT |
| Target Text | ANSWER string |
| Max Input Length | 512 tokens |
| Max Target Length | 128 tokens |
| Epochs | 3 |
| Batch Size | 4 |
| Optimizer & LR | AdamW @ 2e-5 |
| Mixed Precision | Enabled (fp16) |
| Evaluation Strategy | Per Epoch |
| Frameworks | 🤗 Transformers, Datasets, Accelerate |
| Metric | Value |
|---|---|
| Final Eval Loss | 0.415 |
| BLEU / ROUGE | [Not explicitly printed] |
| EM / Accuracy | [Can be added] |
Note: Evaluation beyond loss was mentioned but not shown. Future versions can include BLEU, ROUGE, or exact match scores using evaluate or sacrebleu.
Loss chart from the training loop:
Replace with actual matplotlib plot or embed image if hosted.
python from transformers import T5Tokenizer, T5ForConditionalGeneration
model = T5ForConditionalGeneration.from_pretrained("./fint5-financeqa") tokenizer = T5Tokenizer.from_pretrained("./fint5-financeqa")
question = "What is the net income of the company?" context = "The company reported a net income of $1.5 million for the last quarter."
input_text = f"{question} context: {context}" input_ids = tokenizer(input_text, return_tensors="pt").input_ids
output = model.generate(input_ids) answer = tokenizer.decode(output[0], skip_special_tokens=True)
print("Answer:", answer)
Tracked using codecarbon:
| Metric | Value |
|---|---|
| Emissions (kg CO₂eq) | Reported via emissions.csv |
| Duration | ~[training time] |
| Hardware | Google Colab GPU |
📁 Directory: ./fint5-financeqa ✅ Includes:
You can upload this model to Hugging Face using transformers-cli or huggingface_hub.