Switch from voice_ask to ask_wellnuo_ai API function

As requested - same parameters, same response format.
Changed in both:
- chat.tsx (text chat)
- agent.py (voice agent)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Sergei 2026-01-19 21:16:52 -08:00
parent 122f521af6
commit bbc59e61ce
2 changed files with 4 additions and 2 deletions

View File

@ -248,11 +248,12 @@ export default function ChatScreen() {
const normalizedQuestion = normalizeQuestion(trimmedInput);
// Call API with EXACT same params as voice agent
// Using ask_wellnuo_ai instead of voice_ask (same params, same response format)
const response = await fetch(API_URL, {
method: 'POST',
headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
body: new URLSearchParams({
function: 'voice_ask',
function: 'ask_wellnuo_ai',
clientId: 'MA_001',
user_name: WELLNUO_USER,
token: token,

View File

@ -191,8 +191,9 @@ class WellNuoLLM(llm.LLM):
token = await self._ensure_token()
async with aiohttp.ClientSession() as session:
# Using ask_wellnuo_ai instead of voice_ask (same params, same response)
data = {
"function": "voice_ask",
"function": "ask_wellnuo_ai",
"clientId": "MA_001",
"user_name": WELLNUO_USER,
"token": token,