from demo_code_plugin.demo_code import pump, sdl, balance from demo_code_plugin.plugin import source_code import os if __name__ == "__main__": import ivoryos from ivoryos.config import DemoConfig _conf = DemoConfig() _conf.OUTPUT_FOLDER = '/tmp/ivoryos_data' # Just use absolute path directly os.makedirs(_conf.OUTPUT_FOLDER, exist_ok=True) _conf.CSV_FOLDER = os.path.join(_conf.OUTPUT_FOLDER, 'config_csv/') _conf.SCRIPT_FOLDER = os.path.join(_conf.OUTPUT_FOLDER, 'scripts/') _conf.DATA_FOLDER = os.path.join(_conf.OUTPUT_FOLDER, 'results/') _conf.DUMMY_DECK = os.path.join(_conf.OUTPUT_FOLDER, 'pseudo_deck/') _conf.LLM_OUTPUT = os.path.join(_conf.OUTPUT_FOLDER, 'llm_output/') _conf.DECK_HISTORY = os.path.join(_conf.OUTPUT_FOLDER, 'deck_history.txt') _conf.SQLALCHEMY_DATABASE_URI = f"sqlite:///{os.path.join(_conf.OUTPUT_FOLDER, 'ivoryos.db')}" _conf.SESSION_COOKIE_SECURE = True _conf.SESSION_COOKIE_SAMESITE = "None" _conf.SESSION_COOKIE_HTTPONLY = True _conf.SECRET_KEY = "demo-secret-key" # ✅ MUST HAVE THIS ivoryos.run(__name__, config=_conf, blueprint_plugins=source_code, port=7860) # # USE CASE 2 - start OS using current module and enable LLM with Ollama # ivoryos.run(__name__, model="llama3.1", llm_server='localhost')