QWeQ-NineBird-v1

QWeQ-NineBird-v1 是专为 WeQ 桌面端打造的超轻量级中文即时通讯(IM)多任务意图与情绪感知模型。基于 hfl/rbt3(Chinese RoBERTa-wwm-ext 3-layer)进行多任务联合微调,并导出为单文件 ONNX 格式,可在普通 CPU 上实现毫秒级推理。

模型规格 (Model Specs)

  • **参数量 (Parameters)**:39,178,274 (~39.18M / 0.039B)
  • **底座架构 (Backbone)**:hfl/rbt3 (3-layer Chinese RoBERTa, hidden_size=768)
  • **推理格式 (Format)**:ONNX (opset=17, FP32, ~147 MB)
  • **最大序列长度 (Max Length)**:128 tokens(支持多轮时效性上下文拼接)
  • **多任务联合输出 (4 Heads)**:
    1. intent_logits:17 类社交意图分类
    2. emotion_logits:15 类细粒度情绪分类
    3. intensity:情绪强度回归 (0 ~ 100)
    4. sentiment:情感极性回归 (-100 ~ +100)

支持标签体系 (Label Space)

1. 意图类别 (17 Intents)

标签 含义 标签 含义
question 提问 / 询问 chat 闲聊 / 接话
request 请求 / 拜托 boast 炫耀 / 凡尔赛
greeting 寒暄 / 打招呼 flattery 吹捧 / 彩虹屁
share 分享 / 见闻 banter 调侃 / 互怼
praise 夸赞 / 认可 perfunctory 敷衍 / 糊弄
vent 吐槽 / 倾诉 gossip 吃瓜 / 八卦
joke 玩梗 / 搞笑 coquetry 撒娇 / 讨好
plan 邀约 / 安排 other 其他
info 通知 / 陈述 - -

2. 情绪类别 (15 Emotions)

标签 含义 标签 含义
joy 开心 fatigue 疲惫
excitement 兴奋 curiosity 好奇
admiration 赞叹 shock 震惊
neutral 平静 aggrieved 委屈
sadness 难过 irony 反讽 / 阴阳
anger 生气 anticipation 期待
anxiety 焦虑 embarrassed 尴尬
affection 喜爱 / 感动 - -

输入格式约定 (Input Formatting)

模型支持单条消息或携带时效性衰减标记的前序多轮上下文:

  • 无上文: 消息: 笑死我了蚌埠住了
  • 含前序上下文(按时间间隔标记 刚刚 / 稍早 / 较远): 上文[刚刚]: 对方: 我刚把核心算法重构跑通了,性能提升100倍! [SEP] 消息: 吓哭了,这也太强了吧!

快速推理示例 (ONNX Runtime)

import json
import numpy as np
import onnxruntime as ort
from transformers import BertTokenizer

tokenizer = BertTokenizer.from_pretrained("./tokenizer")
with open("./model_config.json", "r", encoding="utf-8") as f:
    cfg = json.load(f)

sess = ort.InferenceSession("./model.onnx")

text = "上文[刚刚]: 对方: 我刚把核心算法重构跑通了,性能提升100倍! [SEP] 消息: 吓哭了,这也太强了吧!"
enc = tokenizer(text, max_length=128, padding="max_length", truncation=True, return_tensors="np")

intent_logits, emotion_logits, intensity, sentiment = sess.run(
    None,
    {
        "input_ids": enc["input_ids"].astype(np.int64),
        "attention_mask": enc["attention_mask"].astype(np.int64),
        "token_type_ids": enc["token_type_ids"].astype(np.int64),
    },
)

intent = cfg["intent_labels"][int(np.argmax(intent_logits[0]))]
emotion = cfg["emotion_labels"][int(np.argmax(emotion_logits[0]))]
print(f"Intent: {intent}, Emotion: {emotion}, Intensity: {intensity[0]:.1f}, Sentiment: {sentiment[0]:.1f}")
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for N1n3Bird/QWeQ-NineBird

Base model

hfl/rbt3
Quantized
(2)
this model