Downloads · 30 days
8
3% of all-time downloads
ethicalabs/FlowerTune-Echo-DSRN-114M-Finance-PEFT
FlowerTune-Echo-DSRN-114M-Finance-PEFT is a text generation model from ethicalabs. Use it when you need the model to write or continue text. It is set up for peft. The card lists the license as apache-2.0.
[](https://github.com/ethicalabs-ai/Echo-DSRN/) [](https://opensource.org/licenses/Apache-2.0) [](https://www.python.org/downloads/)
Downloads · 30 days
8
3% of all-time downloads
All-time downloads
278
Public
Repo size
7.5 GB
Likes
1
Public
Click a slice to open those files.
.safetensors7.6 GB · 100%
From the Hugging Face model README
[!WARNING] This repository contains experimental models designed strictly for academic evaluation and research purposes.
Critical Constraints:
- No Production Deployment: Experimental models must not be deployed in commercial, enterprise, or mission-critical environments under any circumstances.
- No Liability: Experimental models are provided "as-is" without warranties of any kind. The developers assume zero liability for downstream consequences, system integration failures, or regulatory non-compliance resulting from unauthorized deployment.
The Echo-DSRN(N) (Dual State Recurrent Neural Network, short name: Echo-DSRN, also know as echo) is a novel architecture specifically designed to be a viable alternative for low-resource tasks ("smol" tasks) that are currently being inefficiently handled by the excessive scale of Large Language Models (LLMs) 🌱
This LoRA adapter has been fine-tuned by using the Flower Framework and TRL in a simulated federated learning scenario.

You can load the fine-tuned PEFT adapter over the base model and run sentiment analysis inference as follows:
from peft import PeftModel
from transformers import AutoModelForCausalLM, AutoTokenizer
# Load the base model and tokenizer
base_model_name = "ethicalabs/Echo-DSRN-114M-v0.1.2"
base_model = AutoModelForCausalLM.from_pretrained(base_model_name, trust_remote_code=True)
tokenizer = AutoTokenizer.from_pretrained(base_model_name, trust_remote_code=True)
# Load the fine-tuned PEFT adapter
peft_model_name = "ethicalabs/FlowerTune-Echo-DSRN-114M-Finance-PEFT"
model = PeftModel.from_pretrained(base_model, peft_model_name, trust_remote_code=True)
# Prepare the prompt for sentiment analysis
instruction = "What is the sentiment of this news? Please choose an answer from {negative/neutral/positive}."
news_text = "The company reported a 20% increase in revenue for the third quarter, driven by strong sales in the tech division."
messages = [
{"role": "system", "content": "You are a helpful financial assistant."},
{"role": "user", "content": f"{instruction} {news_text}"}
]
prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
# Tokenize and generate
inputs = tokenizer(prompt, return_tensors="pt")
outputs = model.generate(**inputs, max_new_tokens=10)
response = tokenizer.decode(outputs[0], skip_special_tokens=False)
print(response.split("<|assistant|>")[1].replace("<|end|>", "").strip() if "<|assistant|>" in response else response)
Trained on a single AMD Radeon™ AI PRO R9700 (32 GB RAM).
You can download the source code and reproduce the training process by simply running the following commands:
# Downloads the flower app from Flower Hub
flwr new @mrs83/echo-dsrn-114m-finance
# Federation Local Setup
flwr federation simulation-config \
--num-supernodes=10 \
--client-resources-num-cpus=6 \
--client-resources-num-gpus=1.0
# Runs the federation and streams training log output.
flwr run --stream
Source code is available on the Flower Hub
| Property | Value |
|---|---|
| Model Type | echo_dsrn |
| Layers | 8 |
| Hidden Dim | 512 |
| Attention Heads | 4 |
| MLP Ratio | 8.0 |
| Vocab Size | 32011 |
| Hybrid Attention | True |
| RMSNorm | True |
| Component | Parameters | % of Total |
|---|---|---|
| Total | 114.69M (114,687,488) | 100% |
| Embeddings | 16.39M | 14.29% |
| DSRN Blocks (Aggregate) | 81.91M | 71.42% |
| LM Head | 16.39M | 14.29% |
| Sub-Component | Parameters | Description |
|---|---|---|
| MLP (Feed-Forward) | 4.20M | Upscaled hidden layers |
| DSRN Slow State | 3.15M | Constant-time memory gates |
| GRU Fast State | 1.58M | Recurrent fast path |
| Surprise Gating | 264,192 | Dynamic focus mechanism |
| Normalization | 1,024 | LayerNorm / RMSNorm |
To evaluate the best federated checkpoint (e.g., round 38) across the financial benchmarks (FPB, FIQA, TFNS), use the integrated evaluation script:
python echo_finance/eval.py \
--base-model-name-path ethicalabs/Echo-DSRN-114M-v0.1.2 \
--peft-path ~/.ethicalabs/flwr/results/[RUN_TIMESTAMP]/peft_38 \
--datasets fpb,fiqa,tfns \
--apply-chat-template
Note: The
--apply-chat-templateflag ensures the model is evaluated accurately using the structural ChatML format it was aligned on.
| Dataset | Sentiment Accuracy |
|---|---|
| FPB (Financial PhraseBank) | 71.45% |
| TFNS (Twitter Financial News Sentiment) | 70.14% |
| FIQA (Financial QA) | 63.82% |
@software{vonwerra2020trl,
title = {{TRL: Transformers Reinforcement Learning}},
author = {von Werra, Leandro and Belkada, Younes and Tunstall, Lewis and Beeching, Edward and Thrush, Tristan and Lambert, Nathan and Huang, Shengyi and Rasul, Kashif and Gallouédec, Quentin},
license = {Apache-2.0},
url = {https://github.com/huggingface/trl},
year = {2020}
}
@misc{gao2025flowertune,
title = {FlowerTune: A Cross-Domain Benchmark for Federated Fine-Tuning of Large Language Models},
author = {Yan Gao and Massimo Roberto Scamarcia and Javier Fernandez-Marques and Mohammad Naseri and Chong Shen Ng and Dimitris Stripelis and Zexi Li and Tao Shen and Jiamu Bai and Daoyuan Chen and Zikai Zhang and Rui Hu and InSeo Song and Lee KangYoon and Hong Jia and Ting Dang and Junyan Wang and Zheyuan Liu and Daniel Janes Beutel and Lingjuan Lyu and Nicholas D. Lane},
year = {2025},
eprint = {2506.02961},
archivePrefix = {arXiv},
primaryClass = {cs.LG},
url = {https://arxiv.org/abs/2506.02961}
}
@misc{Massimo Roberto Scamarcia, title={Echo-DSRN-114M: Surprise-Gated Dual-State Recurrent Architecture for Efficient Language Modeling and Classification}, DOI={10.5281/zenodo.19848279}, publisher={Zenodo}, author={Massimo Roberto Scamarcia} }