Instructions to use MoYoYoTech/VoiceDialogue with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use MoYoYoTech/VoiceDialogue with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-to-speech", model="MoYoYoTech/VoiceDialogue") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("MoYoYoTech/VoiceDialogue", dtype="auto") - llama-cpp-python
How to use MoYoYoTech/VoiceDialogue with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="MoYoYoTech/VoiceDialogue", filename="assets/models/llm/qwen/Qwen3-8B-Q6_K.gguf", )
llm.create_chat_completion( messages = "\"The answer to the universe is 42\"" )
- Notebooks
- Google Colab
- Kaggle
- Local Apps
- llama.cpp
How to use MoYoYoTech/VoiceDialogue with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf MoYoYoTech/VoiceDialogue:Q6_K # Run inference directly in the terminal: llama-cli -hf MoYoYoTech/VoiceDialogue:Q6_K
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf MoYoYoTech/VoiceDialogue:Q6_K # Run inference directly in the terminal: llama-cli -hf MoYoYoTech/VoiceDialogue:Q6_K
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 MoYoYoTech/VoiceDialogue:Q6_K # Run inference directly in the terminal: ./llama-cli -hf MoYoYoTech/VoiceDialogue:Q6_K
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 MoYoYoTech/VoiceDialogue:Q6_K # Run inference directly in the terminal: ./build/bin/llama-cli -hf MoYoYoTech/VoiceDialogue:Q6_K
Use Docker
docker model run hf.co/MoYoYoTech/VoiceDialogue:Q6_K
- LM Studio
- Jan
- Ollama
How to use MoYoYoTech/VoiceDialogue with Ollama:
ollama run hf.co/MoYoYoTech/VoiceDialogue:Q6_K
- Unsloth Studio new
How to use MoYoYoTech/VoiceDialogue 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 MoYoYoTech/VoiceDialogue 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 MoYoYoTech/VoiceDialogue to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for MoYoYoTech/VoiceDialogue to start chatting
- Pi new
How to use MoYoYoTech/VoiceDialogue with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf MoYoYoTech/VoiceDialogue:Q6_K
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "MoYoYoTech/VoiceDialogue:Q6_K" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent new
How to use MoYoYoTech/VoiceDialogue with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf MoYoYoTech/VoiceDialogue:Q6_K
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 MoYoYoTech/VoiceDialogue:Q6_K
Run Hermes
hermes
- Docker Model Runner
How to use MoYoYoTech/VoiceDialogue with Docker Model Runner:
docker model run hf.co/MoYoYoTech/VoiceDialogue:Q6_K
- Lemonade
How to use MoYoYoTech/VoiceDialogue with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull MoYoYoTech/VoiceDialogue:Q6_K
Run and chat with the model
lemonade run user.VoiceDialogue-Q6_K
List all available models
lemonade list
Update LLM response generator and system prompts
Browse files- Add "/no_think" directive to English and Chinese system prompts.
- Handle `<think>` and `</think>` tags in response chunk processing.
- Update LLM model file to `Qwen3-8B-Q6_K.gguf`.
- Adjust model parameters: increase context length, modify temperature, top_p, and top_k, and include `presence_penalty`.
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:cb042ccd76795a8830d6be6bd4165245847cc68e41797b13bd61aed4c2cfbce6
|
| 3 |
+
size 6725899040
|
|
@@ -12,15 +12,21 @@ from voice_dialogue.models.voice_task import VoiceTask, QuestionDisplayMessage
|
|
| 12 |
from voice_dialogue.services.text.processor import preprocess_sentence_text, \
|
| 13 |
create_langchain_chat_llamacpp_instance, create_langchain_pipeline, warmup_langchain_pipeline
|
| 14 |
|
| 15 |
-
CHINESE_SYSTEM_PROMPT = (
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24 |
|
| 25 |
|
| 26 |
class LLMResponseGenerator(BaseThread):
|
|
@@ -144,6 +150,9 @@ class LLMResponseGenerator(BaseThread):
|
|
| 144 |
for chunk in pipeline.stream(input={'input': user_question}, config=config):
|
| 145 |
if not chunk.content.strip():
|
| 146 |
continue
|
|
|
|
|
|
|
|
|
|
| 147 |
chunk_content = f'{chunk.content}'
|
| 148 |
|
| 149 |
sentence_end_mark, remain_content = self._process_chunk_content(chunk_content)
|
|
@@ -181,17 +190,18 @@ class LLMResponseGenerator(BaseThread):
|
|
| 181 |
self._send_sentence_to_queue(voice_task, sentence, answer_index)
|
| 182 |
|
| 183 |
def run(self):
|
| 184 |
-
model_path = paths.LLM_MODELS_PATH / 'qwen' / '
|
| 185 |
model_params = {
|
| 186 |
'streaming': True,
|
| 187 |
-
'
|
| 188 |
-
'
|
| 189 |
-
'
|
| 190 |
-
'
|
| 191 |
-
'
|
| 192 |
-
|
| 193 |
-
|
| 194 |
-
|
|
|
|
| 195 |
}
|
| 196 |
self.model_instance = create_langchain_chat_llamacpp_instance(
|
| 197 |
local_model_path=model_path, model_params=model_params
|
|
|
|
| 12 |
from voice_dialogue.services.text.processor import preprocess_sentence_text, \
|
| 13 |
create_langchain_chat_llamacpp_instance, create_langchain_pipeline, warmup_langchain_pipeline
|
| 14 |
|
| 15 |
+
CHINESE_SYSTEM_PROMPT = (
|
| 16 |
+
"你是善于模拟真实的思考过程的AI助手。"
|
| 17 |
+
"回答时,必须首先生成一个不超过5个字的简短句子,"
|
| 18 |
+
"比如:\"让我想一下\"、\"在我看来\"、\"稍等我理一理\"、\"不错的问题\"、\"稍等片刻\"等,然后再进行正式回答,"
|
| 19 |
+
"保持中文口语化表达,禁用emoji和系统相关描述,确保衔接词与内容存在合理逻辑关联。"
|
| 20 |
+
"/no_think"
|
| 21 |
+
)
|
| 22 |
+
|
| 23 |
+
ENGLISH_SYSTEM_PROMPT = (
|
| 24 |
+
"You are an AI assistant skilled at simulating authentic thinking processes. "
|
| 25 |
+
"When responding, you must first generate a brief phrase of no more than 5 words, "
|
| 26 |
+
"such as: 'Let me think', 'I see', 'Let me process this', 'Good question', 'One moment', etc., then proceed with your formal response. "
|
| 27 |
+
"Maintain natural conversational English expression, avoid emojis and system-related descriptions, and ensure logical coherence between transitional phrases and content."
|
| 28 |
+
"/no_think"
|
| 29 |
+
)
|
| 30 |
|
| 31 |
|
| 32 |
class LLMResponseGenerator(BaseThread):
|
|
|
|
| 150 |
for chunk in pipeline.stream(input={'input': user_question}, config=config):
|
| 151 |
if not chunk.content.strip():
|
| 152 |
continue
|
| 153 |
+
elif chunk.content.strip() in {'<think>', '</think>'}:
|
| 154 |
+
continue
|
| 155 |
+
|
| 156 |
chunk_content = f'{chunk.content}'
|
| 157 |
|
| 158 |
sentence_end_mark, remain_content = self._process_chunk_content(chunk_content)
|
|
|
|
| 190 |
self._send_sentence_to_queue(voice_task, sentence, answer_index)
|
| 191 |
|
| 192 |
def run(self):
|
| 193 |
+
model_path = paths.LLM_MODELS_PATH / 'qwen' / 'Qwen3-8B-Q6_K.gguf'
|
| 194 |
model_params = {
|
| 195 |
'streaming': True,
|
| 196 |
+
'n_ctx': 32768,
|
| 197 |
+
'temperature': 0.7,
|
| 198 |
+
'top_p': 0.9,
|
| 199 |
+
'top_k': 20,
|
| 200 |
+
'model_kwargs': {
|
| 201 |
+
'mini_p': 0,
|
| 202 |
+
'presence_penalty': 1.5
|
| 203 |
+
},
|
| 204 |
+
'verbose': False,
|
| 205 |
}
|
| 206 |
self.model_instance = create_langchain_chat_llamacpp_instance(
|
| 207 |
local_model_path=model_path, model_params=model_params
|