Instructions to use Gro97/financial-reasoning-qa-llama3-3-70b-lora with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use Gro97/financial-reasoning-qa-llama3-3-70b-lora with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("togethercomputer/Meta-Llama-3.3-70B-Instruct-Reference") model = PeftModel.from_pretrained(base_model, "Gro97/financial-reasoning-qa-llama3-3-70b-lora") - Notebooks
- Google Colab
- Kaggle
Model Card: Financial Reasoning QA — Llama 3.3 70B LoRA
Model Details
Model Description
This is a LoRA adapter fine-tuned on top of Llama-3.3-70B-Instruct to do step-by-step numeric reasoning over personal finance questions. It covers both generic/global reasoning tasks (debt payoff strategy comparison, loan amortization, retirement projection, budget trade-offs, opportunity-cost decisions between paying off debt vs. investing, emergency-fund trade-offs) and Kenya/East-Africa-specific financial reasoning (KRA PAYE take-home pay calculations including NSSF/Housing Levy/SHIF, SACCO vs. bank loan comparisons, chama rotating-savings timing, mobile-money savings products).
Every training answer shows worked, step-by-step arithmetic rather than a bare final number — training labels for the generic and Kenya-localized tasks were computed programmatically (Python) rather than hand-written, so ground-truth correctness of the underlying numbers is guaranteed by construction.
Submitted to the AutoScientist Challenge (Personal Finance track) by Adaption Labs.
- Developed by: Grold Otieno Mboya
- Shared by: Grold Otieno Mboya
- Model type: LoRA adapter for causal language modeling (personal finance numeric reasoning)
- Language(s): English
- License: Llama 3.3 Community License Agreement (inherited from the base model — see https://www.llama.com/llama3_3/license/)
- Finetuned from model:
togethercomputer/Meta-Llama-3.3-70B-Instruct-Reference
Model Sources
- Dataset: https://huggingface.co/datasets/Gro97/financial_reasoning_qa
- Dataset (Kaggle): https://www.kaggle.com/datasets/groldotieno/adaption-financial-reasoning-qa
- Model (Kaggle): https://www.kaggle.com/models/groldotieno/financial-reasoning-qa-llama3-3-70b-lora
- Demo interface: https://kenya-finance-math.adaptionlabs.app/
- Challenge: AutoScientist Challenge, Adaption Labs
Uses
Direct Use
Answering personal-finance numeric-reasoning questions with worked, step-by-step arithmetic: comparing debt payoff strategies, projecting loan or retirement balances, weighing budget trade-offs, deciding between paying down debt vs. investing, and reasoning through Kenya-specific financial products (SACCO vs. bank loans, chama contribution timing, mobile-money savings, KRA PAYE take-home pay).
Downstream Use
Could serve as a starting point for further fine-tuning on adjacent personal-finance or localized-financial-literacy tasks, or as a component in an educational finance tool aimed at Kenyan/East African users.
Out-of-Scope Use
Not intended as a substitute for licensed financial or tax advice. Not evaluated for general capability, factuality, or safety beyond the Personal Finance task category described here. Illustrative/generic tax brackets used in the non-localized tax-reasoning task type are not tied to any specific country's real tax code and should not be treated as such.
Bias, Risks, and Limitations
The training data is synthetic and procedurally generated across the task types described above; the Kenya-localized content (NSSF, Housing Levy, SHIF, PAYE bands) reflects rates believed accurate as of the dataset's construction and may drift out of date if those rates change.
Known arithmetic limitation: direct testing against DeepSeek on
identical loan-amortization questions found this model's generated
arithmetic can be off by a small margin on multi-step calculations
involving exponentiation (e.g. (1+r)^n in reducing-balance loan formulas)
— a general limitation of LLM-generated arithmetic (numbers are generated
token-by-token, not computed), not specific to this fine-tune. This affects
single-formula questions, not just the more obviously iterative ones (e.g.
month-by-month debt payoff simulations). For exact figures, pair this model
with an actual calculator/code-execution step rather than trusting its
generated arithmetic directly — the deployed demo interface includes a
disclaimer to this effect for the same reason.
Recommendations
Users should independently verify any numeric output used for real financial decisions, and should not assume performance on Kenya-specific financial products generalizes to other countries' financial systems.
How to Get Started with the Model
from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel
base_model_id = "togethercomputer/Meta-Llama-3.3-70B-Instruct-Reference"
adapter_id = "Gro97/financial-reasoning-qa-llama3-3-70b-lora"
tokenizer = AutoTokenizer.from_pretrained(base_model_id)
base_model = AutoModelForCausalLM.from_pretrained(base_model_id, device_map="auto")
model = PeftModel.from_pretrained(base_model, adapter_id)
prompt = "KES 300,000 SACCO loan at 1% per month reducing balance over 24 months — total cost?"
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
output = model.generate(**inputs, max_new_tokens=400)
print(tokenizer.decode(output[0], skip_special_tokens=True))
Training Details
Training Data
Custom-built dataset financial_reasoning_qa: 3,456 rows
(prompt/input/output triples) across thirteen task types, mixed
approximately as follows:
| Task type | Share |
|---|---|
| Debt payoff strategy (avalanche vs. snowball) | 19% |
| SACCO vs. bank loan comparison | 10% |
| Retirement/compound-growth projection | 9% |
| Loan amortization — extra-payment impact | 9% |
| Opportunity cost (pay off debt vs. invest) | 8% |
| Chama rotating-savings timing | 8% |
| KRA PAYE take-home pay | 7% |
| SACCO/mobile-money savings goal timing | 6% |
| Raise allocation (pay debt vs. invest, Kenya) | 6% |
| Budget trade-off / savings-goal timing | 5% |
| Emergency-fund trade-off | 4% |
| KRA PAYE raise impact | 4% |
| Generic illustrative tax-bracket reasoning | 2% |
Every row's numeric answer was computed programmatically (Python) rather than hand-written. Full generator script and version history (including earlier rejected versions — see Limitations of the dataset itself for that history) are in the dataset repository.
- Hugging Face: https://huggingface.co/datasets/Gro97/financial_reasoning_qa
- Kaggle: https://www.kaggle.com/datasets/groldotieno/adaption-financial-reasoning-qa
Training Procedure
Fine-tuned via Adaption Labs' AutoScientist platform using LoRA.
Training Hyperparameters
- Training regime: see
adapter_config.jsonin this repository for the exact LoRA rank/alpha/target-module configuration used for this run.
Speeds, Sizes, Times
Not independently benchmarked by the author; training was run on Adaption Labs' hosted infrastructure (specific hardware not disclosed to the end user for this run).
Evaluation
Testing Data, Factors & Metrics
Testing Data
Two evaluation sets, as reported by Adaption Labs' AutoScientist platform: (1) a held-out split of this project's own dataset, (2) a broader set of unseen tasks from Adaption's internal Personal Finance category benchmark.
Metrics
Pairwise preference win rate against the un-adapted base model, as reported by Adaption Labs' AutoScientist platform (judge methodology not disclosed to the end user).
Results
| Evaluation set | Base model win rate | Adapted model win rate |
|---|---|---|
| This dataset's held-out samples | 10% | 90% |
| Broader Personal Finance category | 11% | 89% |
Summary
The adapter shows a large improvement over the base model both on its own training distribution (90% win rate) and on the broader Personal Finance category benchmark (89% win rate) — the two numbers are close, suggesting the gains generalize reasonably well beyond the specific training distribution, unlike cases where own-dataset performance substantially outpaces category-wide performance.
Environmental Impact
- Hardware Type: Not disclosed by the training platform for this run.
- Hours used: Not disclosed.
- Cloud Provider: Adaption Labs' hosted infrastructure.
- Compute Region: Not disclosed.
- Carbon Emitted: Not calculated.
Technical Specifications
Model Architecture and Objective
LoRA adapter applied to togethercomputer/Meta-Llama-3.3-70B-Instruct-Reference,
trained via supervised fine-tuning to improve step-by-step numeric
reasoning over personal finance questions.
Compute Infrastructure
Software
- PEFT 0.15.1
- Trained via Adaption Labs' AutoScientist platform
Citation
BibTeX:
@misc{mboya2026financialreasoning,
author = {Mboya, Grold Otieno},
title = {Financial Reasoning QA: A LoRA Adapter for Personal Finance
Numeric Reasoning with Kenya/East-Africa Localization},
year = {2026},
howpublished = {AutoScientist Challenge submission, Adaption Labs},
url = {https://huggingface.co/Gro97/financial-reasoning-qa-llama3-3-70b-lora}
}
Model Card Contact
See author's Hugging Face profile: https://huggingface.co/Gro97
Framework versions
- PEFT 0.15.1
- Downloads last month
- 20