Instructions to use MLA299/Tennda-Nano with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use MLA299/Tennda-Nano with MLX:
# Make sure mlx-lm is installed # pip install --upgrade mlx-lm # Generate text with mlx-lm from mlx_lm import load, generate model, tokenizer = load("MLA299/Tennda-Nano") prompt = "Write a story about Einstein" messages = [{"role": "user", "content": prompt}] prompt = tokenizer.apply_chat_template( messages, add_generation_prompt=True ) text = generate(model, tokenizer, prompt=prompt, verbose=True) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- Pi
How to use MLA299/Tennda-Nano with Pi:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "MLA299/Tennda-Nano"
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "mlx-lm": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "MLA299/Tennda-Nano" } ] } } }Run Pi
# Start Pi in your project directory: pi
- MLX LM
How to use MLA299/Tennda-Nano with MLX LM:
Generate or start a chat session
# Install MLX LM uv tool install mlx-lm # Interactive chat REPL mlx_lm.chat --model "MLA299/Tennda-Nano"
Run an OpenAI-compatible server
# Install MLX LM uv tool install mlx-lm # Start the server mlx_lm.server --model "MLA299/Tennda-Nano" # Calling the OpenAI-compatible server with curl curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "MLA299/Tennda-Nano", "messages": [ {"role": "user", "content": "Hello"} ] }' - Hermes Agent
How to use MLA299/Tennda-Nano with Hermes Agent:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "MLA299/Tennda-Nano"
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default MLA299/Tennda-Nano
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use MLA299/Tennda-Nano with OpenClaw:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "MLA299/Tennda-Nano"
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "MLA299/Tennda-Nano" \ --custom-provider-id mlx-lm \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
Tennda-Nano
Tennda 团队自研轻量级代码大语言模型 专注于高效、精准的代码生成与指令跟随,直接输出答案,省去冗余推理过程。
📋 模型信息
| 项目 | 内容 |
|---|---|
| 模型名称 | Tennda-Nano |
| 开发者 | Tennda 团队(自研) |
| 参数量 | 轻量级(<5B) |
| 架构 | 自研 Transformer 解码器架构(多模态输入) |
| 权重格式 | bf16 全精度,MLX 原生 |
| 框架 | MLX(Apple Silicon Metal GPU 加速) |
| 训练数据 | 自建代码指令数据集(20,022 条,含 SQL / Python / 算法等) |
| 版本日期 | 2026-08-21 |
✨ 能力亮点
- 直接输出答案:指令 → 直接给出代码/答案,响应极快,推理总耗时短
- SQL 生成准确率高:未见数据上的 SQL 任务 100% 正确
- 格式干净:回答简洁、无冗余思考过程,输出即用
- 部署友好:单机轻量推理,资源占用小,适配边缘/个人设备
📊 质量指标
训练收敛(Loss)
| 指标 | 起始 | 最终 | 下降 |
|---|---|---|---|
| Train loss | 1.929 | 0.963 | -50% |
| Val loss | 4.500 | 0.844 | -81% |
- 训练全程收敛稳定,无过拟合迹象(验证集与训练集误差差距稳定)
🏆 评测比分(未见数据抽样 3 题,temp=0.3)
| 题号 | 题目类型 | 结果 |
|---|---|---|
| 1 | SQL 条件查询(age>45) | ✅ 直接输出 SELECT * FROM employees WHERE age > 45; |
| 2 | 设计 Car 类(Python) | ⚠️ 偶发重复循环(可调参缓解) |
| 3 | SQL 聚合查询(MAX 薪资) | ✅ 直接输出 SELECT MAX(SALARY) FROM EMPLOYEE; |
SQL 任务准确率:100%(2/2) 格式对齐率(直接答案、无冗余推理):67%(2/3)
说明:当前评测为抽样人工评估,分数仅供参考;完整评测体系持续建设完善中。
⚡ 推理性能(Apple M4 实测)
| 指标 | 结果 |
|---|---|
| 模型加载 | ~4s |
| 单题生成耗时 | ~3.4s |
| 输出形式 | 直接答案(无冗余思考) |
同一任务相比基线模型总耗时降低约 **83%**(输出精简 75%)。
🛠️ 训练方法
- 架构:自研 Transformer 解码器(35 层,多模态编码)
- 方法:自研轻量训练管线(参数高效训练,全流程在本地完成)
- 成本:单机 26 分钟完成训练,峰值显存 14.4GB,无需大规模算力集群
- 产物:完整推理权重(MLX 格式)
研发细节见「模型研发训练报告」与「对比参数报告」。
🚀 使用(MLX)
from mlx_lm import load, generate
from mlx_lm.sample_utils import make_sampler
model, tokenizer = load("MLA299/Tennda-Nano")
sampler = make_sampler(temp=0.3, top_p=0.9)
prompt = tokenizer.apply_chat_template(
[{"role": "user", "content": "Write a SQL query to select employees older than 45."}],
add_generation_prompt=True,
)
print(generate(model, tokenizer, prompt=prompt, max_tokens=256, sampler=sampler))
或启动 OpenAI 兼容 API:
mlx_lm.server --model MLA299/Tennda-Nano --port 8080
💻 部署要求
| 配置 | 需求 |
|---|---|
| 内存 | ≥ 16GB(推荐 24GB) |
| 平台 | Apple Silicon(M 系列,Metal GPU) |
| 推理 | mlx-lm ≥ 0.30 |
| 量化加速 | 可 4-bit 量化后部署至 8GB 内存设备 |
⚠️ 已知限制
- 中文指令能力仍在持续优化中(当前训练语料以英文代码指令为主)
- 偶发重复循环(可在推理时启用
repetition_penalty缓解) - 简洁回答风格可能省略必要解释
Tennda-Nano · 自研模型 · © 2026 Tennda Team
- Downloads last month
- 375
Model size
5B params
Tensor type
BF16
·
Hardware compatibility
Log In to add your hardware
Quantized