-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathmain.py
More file actions
33 lines (28 loc) · 1.45 KB
/
main.py
File metadata and controls
33 lines (28 loc) · 1.45 KB
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
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
PageIndex Chat UI - Application Entry Point
A chat interface for PDF document QA with PageIndex RAG support.
Features:
- PDF upload and indexing
- Text-based RAG with streaming responses
- Vision-based RAG with PDF page images
- Conversation memory
- Customizable model configuration (API key, base URL)
"""
from app import app, socketio
from config import config_manager
if __name__ == '__main__':
# Get configuration from config manager
host = config_manager.get_host()
port = config_manager.get_port()
debug = config_manager.get_debug()
print(f"""
╔══════════════════════════════════════════════════════════════╗
║ PageIndex Chat UI ║
╠══════════════════════════════════════════════════════════════╣
║ Server running at: http://{host}:{port} ║
║ Press Ctrl+C to stop ║
╚══════════════════════════════════════════════════════════════╝
""")
socketio.run(app, host=host, port=port, debug=debug)