Instructions to use Xx-Vexento-xX/la-writer with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Xx-Vexento-xX/la-writer with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Xx-Vexento-xX/la-writer") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Xx-Vexento-xX/la-writer") model = AutoModelForCausalLM.from_pretrained("Xx-Vexento-xX/la-writer", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - PEFT
How to use Xx-Vexento-xX/la-writer with PEFT:
Task type is invalid.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Xx-Vexento-xX/la-writer with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Xx-Vexento-xX/la-writer" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Xx-Vexento-xX/la-writer", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Xx-Vexento-xX/la-writer
- SGLang
How to use Xx-Vexento-xX/la-writer 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 "Xx-Vexento-xX/la-writer" \ --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": "Xx-Vexento-xX/la-writer", "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 "Xx-Vexento-xX/la-writer" \ --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": "Xx-Vexento-xX/la-writer", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use Xx-Vexento-xX/la-writer with Docker Model Runner:
docker model run hf.co/Xx-Vexento-xX/la-writer
la-writer
la-writer is a LoRA fine-tune of stabilityai/stablelm-2-1_6b-chat, merged into the base weights, trained to write literary analysis in a specific voice: short punchy openings, rhetorical questions as pivots, sparing use of ellipses and em dashes, dry understated reactions, no inflated claims of significance.
Model Details
- Base model: stabilityai/stablelm-2-1_6b-chat (~1.6B params)
- Fine-tuning method: LoRA (PEFT), merged into base weights for standalone use
- Language: English
- License: Inherits the base model's license (
stabilityai/stablelm-2-1_6b-chat, custom "other" license) โ see the base model license for terms before commercial use.
Model Description
This model was fine-tuned to produce literary-analysis prose in a specific, terse, first-person critical voice, guided by the system prompt:
Write literary analysis in this voice: open with a short punchy line, no throat-clearing. Use rhetorical questions to pivot. Allow ellipses for a beat and em dashes for asides. Drop short dry reactions. Do not inflate significance. Be specific and direct.
The repository previously hosted only the LoRA adapter weights; this update merges the adapter into the base model so it can be loaded directly with AutoModelForCausalLM, without requiring peft at inference time.
Uses
Direct Use
Generating literary analysis / close-reading commentary in the trained voice, e.g. as a writing assistant for essays, reviews, or annotations on literary texts. Best used with the system prompt above (see chat_template.jinja) for consistent style.
Out-of-Scope Use
- Not intended as a general-purpose chat assistant, factual Q&A system, or for tasks requiring reliable factual accuracy โ the base model's general instruction-following ability may be degraded by this narrow fine-tune.
- Not evaluated for safety-critical, medical, legal, or financial use.
- Subject to the base model's license restrictions on commercial use โ check before deploying in a commercial product.
Bias, Risks, and Limitations
- Very small training set. The model was fine-tuned on 23 examples for 5 epochs, which is enough to imprint a stylistic voice but is a high-overfitting regime โ expect the model to closely echo phrasing patterns from the training examples rather than generalize broadly.
- Inherits any biases and limitations of the base
stablelm-2-1_6b-chatmodel. - Not evaluated on any held-out benchmark; only training loss was tracked.
How to Get Started with the Model
from transformers import AutoModelForCausalLM, AutoTokenizer
model = AutoModelForCausalLM.from_pretrained("Xx-Vexento-xX/la-writer")
tokenizer = AutoTokenizer.from_pretrained("Xx-Vexento-xX/la-writer")
messages = [
{"role": "system", "content": "Write literary analysis in this voice: open with a short punchy line, no throat-clearing. Use rhetorical questions to pivot. Allow ellipses for a beat and em dashes for asides. Drop short dry reactions. Do not inflate significance. Be specific and direct."},
{"role": "user", "content": "Analyze the ending of The Great Gatsby."},
]
inputs = tokenizer.apply_chat_template(messages, add_generation_prompt=True, return_tensors="pt")
output = model.generate(inputs, max_new_tokens=300)
print(tokenizer.decode(output[0], skip_special_tokens=True))
Training Details
Training Data
23 hand-curated literary-analysis text examples (JSONL, single text field per example), formatted with the system voice prompt above.
Training Procedure
- Method: LoRA via PEFT,
r=4,lora_alpha=16,lora_dropout=0.05, target modulesq_proj,v_proj,task_type=CAUSAL_LM - Trainable parameters: 786,432 (0.0478% of 1,645,301,760 total)
- Epochs: 5
- Batch size: 1 (per device) x 8 gradient accumulation steps = effective batch size 8
- Learning rate: 2e-4, cosine schedule, 10% warmup
- Precision: fp32
- Hardware: CPU
- Training regime: fp32, CPU-only
Speeds, Sizes, Times
- Train runtime:
954s (16 min) for 15 optimizer steps - Final train loss: 3.359 (loss trended from ~3.64 at epoch ~0.35 down to ~3.00 at epoch 5)
Framework versions
- PEFT 0.19.1
- Transformers (see base model card for compatible versions)
Model Card Contact
Xx-Vexento-xX (via Hugging Face)
- Downloads last month
- 514
Model tree for Xx-Vexento-xX/la-writer
Base model
stabilityai/stablelm-2-1_6b-chat