Instructions to use Tbata7/FortuneQwen3_4b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use Tbata7/FortuneQwen3_4b 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 Tbata7/FortuneQwen3_4b:Q8_0 # Run inference directly in the terminal: llama cli -hf Tbata7/FortuneQwen3_4b:Q8_0
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf Tbata7/FortuneQwen3_4b:Q8_0 # Run inference directly in the terminal: llama cli -hf Tbata7/FortuneQwen3_4b:Q8_0
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf Tbata7/FortuneQwen3_4b:Q8_0 # Run inference directly in the terminal: ./llama-cli -hf Tbata7/FortuneQwen3_4b:Q8_0
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf Tbata7/FortuneQwen3_4b:Q8_0 # Run inference directly in the terminal: ./build/bin/llama-cli -hf Tbata7/FortuneQwen3_4b:Q8_0
Use Docker
docker model run hf.co/Tbata7/FortuneQwen3_4b:Q8_0
- LM Studio
- Jan
- vLLM
How to use Tbata7/FortuneQwen3_4b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Tbata7/FortuneQwen3_4b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Tbata7/FortuneQwen3_4b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Tbata7/FortuneQwen3_4b:Q8_0
- Ollama
How to use Tbata7/FortuneQwen3_4b with Ollama:
ollama run hf.co/Tbata7/FortuneQwen3_4b:Q8_0
- Unsloth Studio
How to use Tbata7/FortuneQwen3_4b with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for Tbata7/FortuneQwen3_4b to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for Tbata7/FortuneQwen3_4b to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for Tbata7/FortuneQwen3_4b to start chatting
- Atomic Chat new
- Docker Model Runner
How to use Tbata7/FortuneQwen3_4b with Docker Model Runner:
docker model run hf.co/Tbata7/FortuneQwen3_4b:Q8_0
- Lemonade
How to use Tbata7/FortuneQwen3_4b with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull Tbata7/FortuneQwen3_4b:Q8_0
Run and chat with the model
lemonade run user.FortuneQwen3_4b-Q8_0
List all available models
lemonade list
这是一个基于 Qwen3 架构微调的 4B 参数模型,专门用于算命/占卜(Fortune Telling)任务。本仓库同时提供了合并后的 Safetensors 权重、GGUF 量化文件以及 Ollama 使用的 Modelfile。
关于本仓库 (About This Repository)
本仓库包含以下三种格式的模型文件,您可以根据需要选择使用:
- GGUF 量化模型 (Recommended):
- 文件名:
FortuneQwen3_4b_q8_0.gguf(或其他量化版本) - 说明: 已经预先转换好的 GGUF 格式 (Int8 量化),可直接用于
llama.cpp或Ollama。
- 文件名:
- Modelfile:
- 文件名:
Modelfile - 说明: 用于导入 Ollama 的配置文件,定义了系统提示词和参数。
- 文件名:
- Hugging Face Safetensors:
- 文件名:
model.safetensors等 - 说明: 已经合并了 LoRA 权重的完整模型参数,适用于基于 Transformers 的推理或进一步微调,也可以用于导出自定义的 GGUF。
- 文件名:
快速使用 (Quick Start)
选项 1: 使用 Ollama (推荐)
您可以使用本仓库中已经转换好的 GGUF 文件快速创建 Ollama 模型。
克隆本仓库:
git clone https://huggingface.co/Tbata7/FortuneQwen3_4b cd FortuneQwen3_4b创建模型:
# 这一步会使用目录下的 Modelfile 和 GGUF 文件 ollama create FortuneQwen3_q8:4b -f Modelfile运行模型:
ollama run FortuneQwen3_q8:4b
选项 2: 使用 llama.cpp
如果您想直接使用 GGUF 文件:
./llama-cli -m FortuneQwen3_4b_q8_0.gguf -p "你的占卜问题..." -n 512
高级用法:导出自定义 GGUF (Advanced Usage)
如果您希望使用不同的量化精度(如 q4_k, q6_k, fp16 等),可以使用 llama.cpp 自行从 Safetensors 权重导出。
准备环境: 确保您已经安装了
llama.cpp的 python 依赖。转换模型: 使用
convert_hf_to_gguf.py脚本进行转换。您需要指定--outtype参数来控制输出类型。导出为 FP16 (不量化):
python llama.cpp/convert_hf_to_gguf.py ./FortuneQwen3_4b --outfile FortuneQwen3_4b_fp16.gguf --outtype f16导出为 Int8 (q8_0):
python llama.cpp/convert_hf_to_gguf.py ./FortuneQwen3_4b --outfile FortuneQwen3_4b_q8_0.gguf --outtype q8_0其他量化: 您可以先导出为 f16,然后使用
llama-quantize工具进一步量化:./llama-quantize FortuneQwen3_4b_fp16.gguf FortuneQwen3_4b_q4_k_m.gguf q4_k_m
模型信息 (Model Information)
- 基础架构 (Base Architecture): Qwen3:4B
- 任务 (Task): 算命 / 占卜 / 易经解读
- 上下文长度 (Context Window): 32768
- 微调框架: LLaMA-Factory
声明
本模型仅供娱乐和研究使用,算命结果仅供参考,请相信科学。
- Downloads last month
- 57