Downloads · 30 days
35
12% of all-time downloads
leandronunes/qwen3.8-4b-a1-omnimerge-m8
qwen3.8-4b-a1-omnimerge-m8 is a text generation model from leandronunes. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as apache-2.0.
Combinar a deducao logica do Qwen3.8-4B-Distill (78% em BBH Logical Deduction) com a capacidade agentica e de causalidade do Agents-A1-4B (38% em BBH Causal Judgement).
Downloads · 30 days
35
12% of all-time downloads
All-time downloads
290
Public
Parameters
4.7B
9.3 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors9.3 GB · 100%
How the weights are stored.
BF164.7B · 100%
From the Hugging Face model README
| Parametro | Valor |
|---|---|
| Metodo | OmniMerge v2 (OBIM + DAREx + EMR) |
| Base | Qwen/Qwen3.5-4B |
| Fonte 1 | empero-ai/Qwen3.8-4B-Distill (weight=0.6) |
| Fonte 2 | InternScience/Agents-A1-4B (weight=0.4) |
| Density | 0.53 |
| DAREx-q | 0.75 |
| PR682 Turbo | Ativado (protege camadas criticas: norm, embed, head, bias) |
| Skip Patterns | model.visual, mtp.layers |
| Seed | 42 |
| Shards | 2 (5.01 GB + 3.67 GB) |
| Total | 8.68 GB (bf16) |
| Tempo de merge | 22.9 minutos (CPU) |
Combinar a deducao logica do Qwen3.8-4B-Distill (78% em BBH Logical Deduction) com a capacidade agentica e de causalidade do Agents-A1-4B (38% em BBH Causal Judgement).
O OmniMerge v2 foi escolhido em vez do DARE-TIES puro porque adiciona tres melhorias:
| Modelo | Deducao | Causal | College Medicine | Medical Genetics |
|---|---|---|---|---|
Qwen3.8-4B-Distill | 78% | 46% | 70% | 88% |
Agents-A1-4B | 26% | 38% | 78% | 88% |
| Este merge (0.6/0.4) | a medir | a medir | a medir | a medir |
from transformers import AutoModelForCausalLM, AutoTokenizer, BitsAndBytesConfig
import torch
bnb_config = BitsAndBytesConfig(
load_in_4bit=True,
bnb_4bit_compute_dtype=torch.bfloat16,
bnb_4bit_quant_type="nf4",
bnb_4bit_use_double_quant=True,
)
model = AutoModelForCausalLM.from_pretrained(
"leandronunes/qwen3.8-4b-a1-omnimerge-m8",
quantization_config=bnb_config,
device_map="auto",
trust_remote_code=True,
attn_implementation="sdpa",
)
tokenizer = AutoTokenizer.from_pretrained(
"leandronunes/qwen3.8-4b-a1-omnimerge-m8",
trust_remote_code=True,
)
messages = [{"role": "user", "content": "Explain TGF-beta in fibrosis."}]
inputs = tokenizer.apply_chat_template(
messages,
return_tensors="pt",
add_generation_prompt=True,
enable_thinking=False, # Desativa raciocinio estendido
).to(model.device)
linear_attention (Gated DeltaNet) seguidas de 1 full_attention, repetido 8 vezes.enable_thinking=False no apply_chat_template.Qwen3.8-4B-Distill (source 1), com added_tokens_decoder corrigido para 33 tokens.python omnimergekit.py \
--base ./models/base \
--source ./models/source1 \
--source ./models/source2 \
--output ./merged-model-m8 \
--method omnimerge_v2 \
--v2-features obim,darex,emr \
--density 0.53 \
--weights 0.6,0.4 \
--darex-q 0.75 \
--pr682-turbo \
--skip-patterns "model.visual,mtp.layers" \
--seed 42 \
--device cpu
Apache 2.0 (herdada do Qwen3.5-4B).