subbuzdesk/gemma4-financial-sentiment
1201
subbuzdesk/gemma4-financial-sentiment
<div align="center">
 ![Accuracy]() ![Macro F1]() ![Context Window]()
</div>
subbuzdesk/gemma4-financial-sentiment is a state-of-the-art Financial Small Language Model (SLM) developed by Ambiakshi Financial Technologies. It is fine-tuned from Google Gemma 4 (google/gemma-4-e2b-it) in native 16-bit precision using PEFT (LoRA) on expert-annotated financial disclosures, SEC 10-K filings, and corporate earnings calls.
Key Capabilities
- 8,192-Token Long-Context Window: Ingests multi-paragraph financial statements, risk factor disclosures, and earnings call transcripts without truncation.
- Chain-of-Thought Financial Reasoning: Outputs structured JSON containing
sentiment(BULLISH/BEARISH/NEUTRAL),confidence(0.0–1.0),primary_driver, andstock_signal. - Zero Quantization Degradation: Trained in unquantized 16-bit precision with LoRA rank 16.
- Local & Edge Friendly: Runs at 80–120 tokens/sec on Apple Silicon (M1/M2/M3/M4) or standard GPUs.
Benchmark Performance vs. Baselines
Quick Start / Inference Example
import torch
from transformers import AutoTokenizer, AutoModelForCausalLM
from peft import PeftModel
base_model_id = "google/gemma-4-e2b-it"
adapter_id = "subbuzdesk/gemma4-financial-sentiment"
tokenizer = AutoTokenizer.from_pretrained(base_model_id)
model = AutoModelForCausalLM.from_pretrained(base_model_id, torch_dtype=torch.float16, device_map="auto")
model = PeftModel.from_pretrained(model, adapter_id)
prompt = [
{"role": "system", "content": "You are Ambiakshi AI, a financial sentiment and stock analysis SLM."},
{"role": "user", "content": "Operating profit rose to EUR 14.5 mn from EUR 10.2 mn on expanding SaaS subscriptions."}
]
formatted_input = tokenizer.apply_chat_template(prompt, return_tensors="pt").to("cuda")
outputs = model.generate(formatted_input, max_new_tokens=256, temperature=0.2)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))License
Released under the Apache 2.0 permissive license for commercial and private enterprise use.
