Spaces:
Paused
Paused
Download app.py from Phoenix21/lecturelens-demo: direct link, hf CLI and curl.
- Browser
- Download file 754 Bytes
-
https://huggingface.co/spaces/Phoenix21/lecturelens-demo/resolve/main/app.py
- Command line
-
hf download hf://spaces/Phoenix21/lecturelens-demo/app.py
-
curl -L -o app.py https://huggingface.co/spaces/Phoenix21/lecturelens-demo/resolve/main/app.py
754 Bytes
| """Gradio entry point, usable from this folder or the staged Space root.""" | |
| from pathlib import Path | |
| import os | |
| import sys | |
| ROOT = Path(__file__).resolve().parent | |
| if (ROOT.parent / "lecturelens").is_dir(): | |
| sys.path.insert(0, str(ROOT.parent)) | |
| from space_app.semantic import configure | |
| configure() | |
| from space_app.local_models import configure as configure_local | |
| configure_local() | |
| from space_app.ui import create_app | |
| demo = create_app() | |
| if __name__ == "__main__": | |
| demo.queue(max_size=8, default_concurrency_limit=1).launch( | |
| server_name="0.0.0.0", server_port=int(os.environ.get("PORT", "7860")), | |
| max_file_size="100mb", show_error=False, | |
| ssr_mode=False, | |
| css=(ROOT / "styles.css").read_text(encoding="utf-8"), | |
| ) | |