Instructions to use egg1234/eggAI with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use egg1234/eggAI with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="egg1234/eggAI") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("egg1234/eggAI") model = AutoModelForCausalLM.from_pretrained("egg1234/eggAI", 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=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use egg1234/eggAI with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf egg1234/eggAI:Q4_K_M # Run inference directly in the terminal: llama cli -hf egg1234/eggAI:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf egg1234/eggAI:Q4_K_M # Run inference directly in the terminal: llama cli -hf egg1234/eggAI:Q4_K_M
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf egg1234/eggAI:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama cli -hf egg1234/eggAI:Q4_K_M
Use Docker
docker model run hf.co/egg1234/eggAI:Q4_K_M
- Llama new
- LM Studio
- Jan
- vLLM
How to use egg1234/eggAI with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "egg1234/eggAI" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "egg1234/eggAI", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/egg1234/eggAI:Q4_K_M
- SGLang
How to use egg1234/eggAI 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 "egg1234/eggAI" \ --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": "egg1234/eggAI", "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 "egg1234/eggAI" \ --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": "egg1234/eggAI", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Ollama
How to use egg1234/eggAI with Ollama:
ollama run hf.co/egg1234/eggAI:Q4_K_M
- Unsloth Desktop
- Docker Model Runner
How to use egg1234/eggAI with Docker Model Runner:
docker model run hf.co/egg1234/eggAI:Q4_K_M
- Lemonade
How to use egg1234/eggAI with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull egg1234/eggAI:Q4_K_M
Run and chat with the model
lemonade run user.eggAI-Q4_K_M
List all available models
lemonade list
- Atomic Chat
首先:
原模型:Qwen3.5-0.8B
许可证:Apache-2.0
改动:二次微调权重,加强python编程能力
------------
一、这份东西是什么**
eggAI 是一个 约0.75B(由Qwen3.5-0.8B剥离多模态视觉理解得来) 参数的中文本地助手。
它只做三件事:写 Python 代码、解释报错、日常问答(闲聊、身份、简单推理)。
二、目录结构
model.safetensors(约 1.4 GB)完整权重,配合config.json/tokenizer*直接加载chat_template.jinja对话模板(极简版,含默认身份)- GGUF文件夹中还有可直接给客户端用的量化版本:
eggAI-Q4_K_M.gguf(约 505 MB)
三、使用方法
方式 1:客户端(最简单)
使用llama.cpp或类似软件直接加载GGUF文件夹中的的 eggAI-Q4_K_M.gguf。
- 建议 temperature=0.7~0.9
方式 2:llama.cpp 命令行
llama-cli -m eggAI-Q4_K_M.gguf -cnv --jinja --temp 0.3 -ngl 99
方式 3:Python(transformers)
from transformers import AutoTokenizer, AutoModelForCausalLM
tok = AutoTokenizer.from_pretrained(r".")
m = AutoModelForCausalLM.from_pretrained(r".", dtype="float32")
msgs = [{"role": "user", "content": "你是谁?"}]
pp = tok.apply_chat_template(msgs, tokenize=False, add_generation_prompt=True)
ids = tok(pp, return_tensors="pt", add_special_tokens=False)
out = m.generate(**ids, max_new_tokens=300, do_sample=False)
print(tok.decode(out[0][ids.input_ids.shape[1]:], skip_special_tokens=False))
四、训练数据构成
| 类别 | 数量 | 来源与验证方式 |
|---|---|---|
| 编程 | 316 | Alpaca 中文代码题(全部过 py_compile)+ 题库(真实执行比对输出) |
| 指令跟随 | 200 | Alpaca 中文(改写/摘要/分类/提取/解释等) |
| 数学 | 104 | 手写应用题(带 3-4 步推理)+ 题库(答案比对) |
| Windows 命令 | 28 | 手写标准 PowerShell / CMD 命令 |
| 闲聊(弱智吧) | 42 | 弱智吧题目 + 手写 eggAI 口吻回答 |
| 身份 | 30 ×4 加权 | 覆盖「你是 Qwen 吗/通义吗/ChatGPT 吗」等所有变体 |
训练采用两阶段:先只训身份(30 条 ×5 轮,lr 3e-4)把「我是 eggAI / eggking 研发」写进权重,
再以该模型为底模训全量能力(1230 条 ×3 轮,lr 1.2e-4),避免能力数据稀释身份。
五、已知限制
- 数学能力弱:0.75B 参数量决定,复杂应用题(如鸡兔同笼)会算错
- 长上下文:训练时 max_len 1024,超长输入会截断
- 知识面窄:没有注入世界知识,问事实性问题容易编
六、模型训练参数
- 底模:Qwen3.5 架构,24 层,hidden 1024
- LoRA:r=16, alpha=32, dropout=0.05,目标模块 q_proj/k_proj/v_proj/o_proj/gate_proj/up_proj/down_proj
- 学习率:身份阶段 3e-4,能力阶段 1.2e-4~1.5e-4
- 停止符:
<|im_end|>(248046) +<|endoftext|>(248044)
七、评测记录
对比原qwen3.5-0.8B模型各方面小幅度领先,对比DeepSeek-R1-Distill-Qwen-1.5B-Q5_K_M部分场景领先,代码能力在no think的情况下会更好,数学受益于长CoT思维链链路能力对比同规模模型普遍更佳。
- Downloads last month
- 54