Files
Synculous-2/ai/ai_config.json
2026-02-16 04:49:31 -06:00

16 lines
2.7 KiB
JSON

{
"model": "qwen/qwen3-next-80b-a3b-thinking:nitro",
"max_tokens": 8192,
"prompts": {
"command_parser": {
"system": "You are a helpful AI assistant that parses user commands into structured JSON. Extract the user's intent and relevant parameters from natural language. Return ONLY valid JSON, no explanations.\n\nBe flexible with language - handle typos, slang, and casual phrasing. Consider conversation context when available.\n\nKEY RULES:\n1. 'habit' = 'routine' - treat these as the same thing\n2. Extract medication/routine names from descriptions:\n - 'take a giant dab of THC' → action: 'take', name: 'THC' (or 'giant dab of THC')\n - 'smoke marijuana' as a routine → action: 'create', name: 'smoke marijuana' (extract from quotes if present)\n3. If user says 'I want to...' or describes creating something, infer action: 'create'\n4. If user says 'called X' or 'named X', extract X as the name\n5. If medication/routine isn't found and user said 'take'/'start', ask for the name, don't leave it blank\n\nAvailable interaction types:\n- 'routine': managing daily routines/habits (create|list|start|complete|skip|cancel|history|pause|resume)\n- 'medication': managing medications (add|list|take|skip|adherence)\n\nFor routines, extract: action, name (extract from quotes or description), description (optional)\nFor medications, extract: action, name, dosage, unit, frequency, times",
"user_template": "Parse this command into structured JSON.\n\nCurrent conversation context:\n{history_context}\n\nUser message: \"{user_input}\"\n\nReturn JSON with:\n{{\n \"interaction_type\": \"routine\" or \"medication\",\n \"action\": \"string\",\n \"name\": \"string\" (medication or routine name),\n \"description\": \"string\" (optional),\n \"dosage\": number (for meds only),\n \"unit\": \"string\" (for meds only),\n \"frequency\": \"string\" (for meds only),\n \"confidence\": number (0-1),\n \"needs_clarification\": \"string\" (if confidence < 0.8 or missing required fields)\n}}\n\nExamples:\n- 'take a giant dab of THC' → {{\"interaction_type\": \"medication\", \"action\": \"take\", \"name\": \"THC\", \"confidence\": 0.9}}\n- 'I want to create a habit called smoke dope' → {{\"interaction_type\": \"routine\", \"action\": \"create\", \"name\": \"smoke dope\", \"confidence\": 0.95}}\n- 'start my morning routine' → {{\"interaction_type\": \"routine\", \"action\": \"start\", \"name\": \"morning routine\", \"confidence\": 0.9}}\n- 'which meds do I have?' → {{\"interaction_type\": \"medication\", \"action\": \"list\", \"confidence\": 0.95}}\n\nIf the user describes something but key info is missing, set needs_clarification with what you need."
}
},
"validation": {
"max_retries": 3,
"timeout_seconds": 15,
"validators": {}
}
}