Spaces:
Sleeping
Sleeping
Commit
Β·
0c91d86
1
Parent(s):
9a54a21
π§ CRITICAL FIX: Resolve missing llm_service attribute
Browse filesERROR FIXED: 'GroqWebSocketHandler' object has no attribute 'llm_service'
β
SOLUTION:
- Added self.llm_service = self.hybrid_llm alias for compatibility
- Maintains backward compatibility while using enhanced HybridLLMService
- Resolves query processing errors in Rajasthan Rule Assistant
Now text clients can properly:
- Process impact analysis queries
- Generate charts and visualizations
- Use role-based responses (citizen, officer, etc.)
- Get Hindi language responses
- Export evidence packs
Test ready: 'show impact of pension policies' should now work! π―
groq_websocket_handler.py
CHANGED
|
@@ -30,6 +30,7 @@ class GroqWebSocketHandler:
|
|
| 30 |
self.active_connections: Dict[str, WebSocket] = {}
|
| 31 |
self.user_sessions: Dict[str, Dict] = {}
|
| 32 |
self.hybrid_llm = HybridLLMService()
|
|
|
|
| 33 |
self.chart_generator = PolicyChartGenerator()
|
| 34 |
self.rajasthan_formatter = rajasthan_formatter
|
| 35 |
|
|
|
|
| 30 |
self.active_connections: Dict[str, WebSocket] = {}
|
| 31 |
self.user_sessions: Dict[str, Dict] = {}
|
| 32 |
self.hybrid_llm = HybridLLMService()
|
| 33 |
+
self.llm_service = self.hybrid_llm # Add alias for compatibility
|
| 34 |
self.chart_generator = PolicyChartGenerator()
|
| 35 |
self.rajasthan_formatter = rajasthan_formatter
|
| 36 |
|