File size: 1,085 Bytes
66dbebd |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 |
# intent_protocols.py
INTENT_RECOGNITION_PROTOCOL = {
"input_spec": {
"user_input": "string_required",
"conversation_history": "array_optional",
"user_profile": "object_optional",
"timestamp": "iso_string_required"
},
"output_spec": {
"primary_intent": {
"type": "string",
"allowed_values": ["information", "task", "creative", "analysis", "conversation", "support"],
"required": True
},
"secondary_intents": {
"type": "array",
"max_items": 3,
"required": True
},
"confidence_scores": {
"type": "object",
"required": True,
"validation": "scores_between_0_1"
},
"reasoning_chain": {
"type": "array",
"required": True,
"description": "Step-by-step CoT reasoning"
}
},
"quality_thresholds": {
"min_confidence": 0.6,
"max_processing_time": 2000, # ms
"fallback_intent": "conversation"
}
}
|