Instructions to use Alvaropar/FinQwen3-8B-adapter with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use Alvaropar/FinQwen3-8B-adapter with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("Qwen/Qwen3-8B") model = PeftModel.from_pretrained(base_model, "Alvaropar/FinQwen3-8B-adapter") - Transformers
How to use Alvaropar/FinQwen3-8B-adapter with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Alvaropar/FinQwen3-8B-adapter") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("Alvaropar/FinQwen3-8B-adapter", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Alvaropar/FinQwen3-8B-adapter with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Alvaropar/FinQwen3-8B-adapter" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Alvaropar/FinQwen3-8B-adapter", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Alvaropar/FinQwen3-8B-adapter
- SGLang
How to use Alvaropar/FinQwen3-8B-adapter with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "Alvaropar/FinQwen3-8B-adapter" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Alvaropar/FinQwen3-8B-adapter", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "Alvaropar/FinQwen3-8B-adapter" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Alvaropar/FinQwen3-8B-adapter", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use Alvaropar/FinQwen3-8B-adapter with Docker Model Runner:
docker model run hf.co/Alvaropar/FinQwen3-8B-adapter
Model Card for Qwen3-8B Finetuned (Financial Sentiment - LoRA)
Model Details
Model Description
This model is a parameter-efficient fine-tuned version of Qwen3-8B, adapted using LoRA (Low-Rank Adaptation) for financial sentiment analysis.
It is trained as an instruction-following text generation model that classifies financial sentences into:
positivenegativeneutral
The model generates a single-word output, making it suitable for lightweight classification pipelines while retaining generative flexibility.
- Developed by: Authors of the referenced paper
- Model type: Causal Language Model (decoder-only transformer)
- Language(s): English (financial domain)
- License: Same as base model (Qwen license – verify before use)
- Finetuned from model: Qwen/Qwen3-8B
Model Sources
- Base Model: Qwen/Qwen3-8B
- Paper: https://arxiv.org/pdf/2512.00946
Uses
Direct Use
This model is intended for:
- Financial sentiment classification
- Text generation with constrained outputs
- Research on instruction-tuned LLM classifiers
Example applications:
- Market sentiment analysis
- News sentiment tagging
- Signal generation for trading pipelines
Downstream Use
- Integration into trading or analytics systems
- Combination with time-series models (e.g., LSTM, TFT)
- Use in RAG pipelines for financial reasoning
Out-of-Scope Use
- High-stakes financial decision-making without validation
- Legal or medical analysis
- Tasks requiring guaranteed factual correctness
- General sentiment analysis outside financial domain (may degrade)
Prompt Format Requirement
This model is highly sensitive to prompt structure.
It was trained using a fixed instruction template, and performance depends heavily on using the same format at inference time.
Required Prompt
You are an AI language model trained to detect the sentiment of each sentence for finance trends.
Analyze the following sentence and determine if the sentiment is: positive or negative or neutral.
Return only a single word, either positive or negative or neutral.
<your input text>
- Downloads last month
- 2