Spaces:
Running on CPU Upgrade
Running on CPU Upgrade
Upload 6 files
Browse files
app.py
CHANGED
|
@@ -19,7 +19,7 @@ from src.jobs import (
|
|
| 19 |
launch_universal_model_card_job,
|
| 20 |
launch_validate_existing_space_job,
|
| 21 |
)
|
| 22 |
-
from src.runs import make_run_id, validate_run_id
|
| 23 |
from src.progress import progress_from_events
|
| 24 |
from src.view_models import build_run_view_model, find_latest_resumable_run
|
| 25 |
from src.security import redact
|
|
@@ -151,7 +151,7 @@ def register_custom_routes(fastapi_app: FastAPI) -> None:
|
|
| 151 |
return JSONResponse(
|
| 152 |
{
|
| 153 |
"name": "Agentic Space Factory",
|
| 154 |
-
"version": "
|
| 155 |
"bucket_default": settings.bucket_name,
|
| 156 |
"workflows": ["build_from_model_card", "validate_existing_space", "runs_explorer"],
|
| 157 |
"custom_ui_status": "root_custom_ui",
|
|
@@ -225,7 +225,7 @@ def register_custom_routes(fastapi_app: FastAPI) -> None:
|
|
| 225 |
raise _json_error(exc) from exc
|
| 226 |
result["job_url"] = _job_url_from_result(result, ctx["username"])
|
| 227 |
result["created_by"] = ctx["username"]
|
| 228 |
-
result["created_at"] = result.get("created_at") or
|
| 229 |
result["links"] = _api_links(
|
| 230 |
run_id=result.get("run_id"),
|
| 231 |
bucket_source=result.get("bucket_source"),
|
|
@@ -271,7 +271,7 @@ def register_custom_routes(fastapi_app: FastAPI) -> None:
|
|
| 271 |
raise _json_error(exc) from exc
|
| 272 |
result["job_url"] = _job_url_from_result(result, ctx["username"])
|
| 273 |
result["created_by"] = ctx["username"]
|
| 274 |
-
result["created_at"] = result.get("created_at") or
|
| 275 |
result["links"] = _api_links(
|
| 276 |
run_id=result.get("run_id"),
|
| 277 |
bucket_source=result.get("bucket_source"),
|
|
@@ -397,6 +397,7 @@ def register_custom_routes(fastapi_app: FastAPI) -> None:
|
|
| 397 |
"generation_smoke": bundle.get("generation_smoke") or {},
|
| 398 |
"hardware_strategy": bundle.get("hardware_strategy") or {},
|
| 399 |
"technical_blockers": bundle.get("technical_blockers") or {},
|
|
|
|
| 400 |
"events": events[-20:],
|
| 401 |
"view": view,
|
| 402 |
"links": view.get("links") or _api_links(
|
|
|
|
| 19 |
launch_universal_model_card_job,
|
| 20 |
launch_validate_existing_space_job,
|
| 21 |
)
|
| 22 |
+
from src.runs import make_run_id, utc_now_iso, validate_run_id
|
| 23 |
from src.progress import progress_from_events
|
| 24 |
from src.view_models import build_run_view_model, find_latest_resumable_run
|
| 25 |
from src.security import redact
|
|
|
|
| 151 |
return JSONResponse(
|
| 152 |
{
|
| 153 |
"name": "Agentic Space Factory",
|
| 154 |
+
"version": "v57-live-pi-traces",
|
| 155 |
"bucket_default": settings.bucket_name,
|
| 156 |
"workflows": ["build_from_model_card", "validate_existing_space", "runs_explorer"],
|
| 157 |
"custom_ui_status": "root_custom_ui",
|
|
|
|
| 225 |
raise _json_error(exc) from exc
|
| 226 |
result["job_url"] = _job_url_from_result(result, ctx["username"])
|
| 227 |
result["created_by"] = ctx["username"]
|
| 228 |
+
result["created_at"] = result.get("created_at") or utc_now_iso()
|
| 229 |
result["links"] = _api_links(
|
| 230 |
run_id=result.get("run_id"),
|
| 231 |
bucket_source=result.get("bucket_source"),
|
|
|
|
| 271 |
raise _json_error(exc) from exc
|
| 272 |
result["job_url"] = _job_url_from_result(result, ctx["username"])
|
| 273 |
result["created_by"] = ctx["username"]
|
| 274 |
+
result["created_at"] = result.get("created_at") or utc_now_iso()
|
| 275 |
result["links"] = _api_links(
|
| 276 |
run_id=result.get("run_id"),
|
| 277 |
bucket_source=result.get("bucket_source"),
|
|
|
|
| 397 |
"generation_smoke": bundle.get("generation_smoke") or {},
|
| 398 |
"hardware_strategy": bundle.get("hardware_strategy") or {},
|
| 399 |
"technical_blockers": bundle.get("technical_blockers") or {},
|
| 400 |
+
"pi_live_log": (bundle.get("pi_live_log") or bundle.get("pi_output_log") or "")[-12000:],
|
| 401 |
"events": events[-20:],
|
| 402 |
"view": view,
|
| 403 |
"links": view.get("links") or _api_links(
|