File size: 871 Bytes
1482718
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
#!/usr/bin/env python3
"""
OWL (Optimized Workforce Learning) - Main Entry Point
This module initializes the agent society and manages the overall workflow.
"""

import os
from dotenv import load_dotenv
from owl.ui.app import create_app
from owl.agents.agent import OwlRolePlaying

# Load environment variables
load_dotenv()

def main():
    """Main entry point for the OWL application."""
    try:
        # Initialize the Gradio web interface
        app = create_app()
        
        # Start the web interface
        app.launch(
            server_name="0.0.0.0",  # Allow external access
            server_port=int(os.getenv("PORT", 7860)),  # Default Gradio port
            share=False  # Set to True to create a public URL
        )
    except Exception as e:
        print(f"Error starting OWL: {str(e)}")
        raise

if __name__ == "__main__":
    main()