18 lines
623 B
Python
18 lines
623 B
Python
"""Start the optional, loopback-only Grok adapter without a console window."""
|
|
import json
|
|
import logging
|
|
from pathlib import Path
|
|
|
|
import uvicorn
|
|
|
|
from bridge import create_app
|
|
|
|
|
|
if __name__ == "__main__":
|
|
root = Path(__file__).resolve().parent
|
|
logging.basicConfig(filename=root / "grok-bridge.log", level=logging.WARNING,
|
|
format="%(asctime)s %(levelname)s %(message)s")
|
|
config = json.loads((root / "grok-client.json").read_text(encoding="utf-8"))
|
|
uvicorn.run(create_app(config), host="127.0.0.1", port=18793, access_log=False,
|
|
log_config=None, log_level="warning")
|