AumCoreAI commited on
Commit
f60be0f
·
verified ·
1 Parent(s): fc0ee9b

Update modules/orchestrator.py

Browse files
Files changed (1) hide show
  1. modules/orchestrator.py +28 -1
modules/orchestrator.py CHANGED
@@ -515,4 +515,31 @@ if __name__ == "__main__":
515
  except KeyboardInterrupt:
516
  pass
517
  except Exception as e:
518
- print(f"FATAL ERROR: {e}")
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
515
  except KeyboardInterrupt:
516
  pass
517
  except Exception as e:
518
+ print(f"FATAL ERROR: {e}")
519
+ # ==========================================
520
+ # REGISTER MODULE FUNCTION
521
+ # ==========================================
522
+ def register_module(app, client, username):
523
+ """Register orchestrator module with FastAPI app"""
524
+ from fastapi import APIRouter
525
+
526
+ router = APIRouter()
527
+
528
+ @router.get("/orchestrator/health")
529
+ async def orchestrator_health():
530
+ return {
531
+ "module": "orchestrator",
532
+ "status": "active",
533
+ "version": "2.0.1-Stable",
534
+ "endpoints": ["/orchestrator/health", "/system/task", "/system/status"]
535
+ }
536
+
537
+ # Register existing endpoints
538
+ from .orchestrator import get_system_diagnostics
539
+
540
+ @router.get("/orchestrator/diagnostics")
541
+ async def module_diagnostics():
542
+ return await get_system_diagnostics()
543
+
544
+ app.include_router(router)
545
+ print("✅ Orchestrator module registered with FastAPI")