Spaces:
Sleeping
Sleeping
Download server/app.py from gauravnetes/datacleaning-env: direct link, hf CLI and curl.
- Browser
- Download file 553 Bytes
-
https://huggingface.co/spaces/gauravnetes/datacleaning-env/resolve/main/server/app.py
- Command line
-
hf download hf://spaces/gauravnetes/datacleaning-env/server/app.py
-
curl -L -o app.py https://huggingface.co/spaces/gauravnetes/datacleaning-env/resolve/main/server/app.py
553 Bytes
| import os | |
| import sys | |
| sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) | |
| from fastapi import FastAPI | |
| from openenv.core.env_server.http_server import create_app | |
| from env.environment import DataCleaningEnv | |
| from env.models import Action, Observation | |
| # Create the FastAPI app | |
| app = create_app( | |
| DataCleaningEnv, | |
| Action, | |
| Observation, | |
| env_name="datacleaning-env", | |
| max_concurrent_envs=1, | |
| ) | |
| def main(): | |
| import uvicorn | |
| uvicorn.run(app, host="0.0.0.0", port=7860) | |
| if __name__ == "__main__": | |
| main() | |