Spaces:
Sleeping
Sleeping
Upload folder using huggingface_hub
Browse files11 unmodified lines121314151617181920212223242511 unmodified lines# ββ Additional required hackathon endpoints ββββββββββββββββββββββββββββ@app.get("/")def home():return {"message": "Welcome to the OpenEnv Code Debug Environment!","version": "1.0.0","endpoints": ["/health", "/tasks", "/reset", "/step", "/grader", "/baseline"],"docs": "https://huggingface.co/spaces/luciferai-devil/code-debug-env"}@app.get("/tasks")11 unmodified lines12131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858611 unmodified lines# ββ Additional required hackathon endpoints ββββββββββββββββββββββββββββfrom fastapi.responses import HTMLResponse@app.get("/", response_class=HTMLResponse)@app.get("/web", response_class=HTMLResponse)def home():return """<!DOCTYPE html><html><head><title>Code Debug Env | OpenEnv</title><style>@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;800&display=swap');body {font-family: 'Inter', sans-serif;background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%);color: #f8fafc;display: flex;flex-direction: column;align-items: center;justify-content: center;min-height: 100vh;margin: 0;text-align: center;}.container {background: rgba(30, 41, 59, 0.7);backdrop-filter: blur(12px);padding: 3rem;border-radius: 24px;border: 1px solid rgba(255, 255, 255, 0.1);box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);max-width: 600px;}h1 { font-size: 3rem; margin-bottom: 0.5rem; background: linear-gradient(to right, #60a5fa, #a78bfa); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }p { color: #94a3b8; font-size: 1.1rem; line-height: 1.6; }.badge { background: #334155; padding: 4px 12px; border-radius: 20px; font-size: 0.8rem; vertical-align: middle; border: 1px solid #475569; }.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 2rem; }.btn {display: block;padding: 1rem;border-radius: 12px;background: rgba(255, 255, 255, 0.05);border: 1px solid rgba(255, 255, 255, 0.1);color: #fff;text-decoration: none;transition: all 0.2s;font-weight: 600;}.btn:hover { background: rgba(255, 255, 255, 0.1); border-color: #60a5fa; transform: translateY(-2px); }footer { margin-top: 2rem; color: #64748b; font-size: 0.9rem; }</style></head><body><div class="container"><h1>Code Debug Env</h1><p>A production-grade <strong>OpenEnv</strong> for training frontier reasoning agents on code repair tasks. <span class="badge">v1.0.0</span></p><div class="grid"><a href="/health" class="btn">π‘ Server Health</a><a href="/tasks" class="btn">π Task Registry</a><a href="/baseline" class="btn">π€ Run Baseline</a><a href="https://huggingface.co/spaces/luciferai-devil/code-debug-env" class="btn">π Documentation</a></div><footer>Built for Meta & PyTorch Γ Scaler Hackathon</footer></div></body></html>"""@app.get("/tasks")
server/app.py+68-7