mirror of
https://github.com/Paillat-dev/viralfactory.git
synced 2026-01-02 09:16:19 +00:00
Refactor UI module and add launcher function
This commit is contained in:
5
main.py
5
main.py
@@ -1,4 +1,4 @@
|
|||||||
from ui import GenerateUI
|
from ui import launch
|
||||||
from dotenv import load_dotenv
|
from dotenv import load_dotenv
|
||||||
from src.models import init_db
|
from src.models import init_db
|
||||||
|
|
||||||
@@ -6,5 +6,4 @@ load_dotenv()
|
|||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
init_db()
|
init_db()
|
||||||
ui_generator = GenerateUI()
|
launch()
|
||||||
ui_generator.launch_ui()
|
|
||||||
@@ -1 +1,2 @@
|
|||||||
from .gradio_ui import GenerateUI
|
from .gradio_ui import GenerateUI
|
||||||
|
from .launcher import launch
|
||||||
4
ui/launcher.py
Normal file
4
ui/launcher.py
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
from . import GenerateUI
|
||||||
|
def launch():
|
||||||
|
ui_generator = GenerateUI()
|
||||||
|
ui_generator.launch_ui()
|
||||||
Reference in New Issue
Block a user