unslothai/unsloth · error · HTTPException
AI assist failed: {scrubbed}
Error message
AI assist failed: {scrubbed} What it means
HTTP 500 from the AI-assist mapping advisor when its multi-pass LLM analysis raised an exception that fell through the mapped branches (hf_error_status, FileNotFoundError→404, ValueError→400). Like 807, the message is secret-scrubbed and both returned to the client and logged. The AI assist loads a 7B helper model, so failures are often model/runtime/resource related rather than dataset related.
Source
Thrown at studio/backend/hub/services/datasets/formatting.py:592
warning = result.get("warning"),
)
return AiAssistMappingResponse(
success = False,
warning = "AI could not determine column roles. Please assign them manually.",
)
except Exception as e:
scrubbed = download_registry.scrub_secrets(str(e), hf_token = hf_token)
status = hf_error_status(e)
if status is None and isinstance(e, FileNotFoundError):
status = 404
elif status is None and isinstance(e, ValueError):
status = 400
if status is not None:
raise HTTPException(status_code = status, detail = scrubbed)
logger.error("AI assist mapping failed: %s", scrubbed)
raise HTTPException(
status_code = 500,
detail = "AI assist failed: " + scrubbed,
)
View on GitHub (pinned to 203007d190)
Solutions
- Check the logged `AI assist mapping failed: ...` line — it carries the scrubbed root cause.
- Ensure the helper model is already cached locally (pre-download it) or that the model host is reachable from the backend.
- Free GPU/CPU memory: close other training jobs before running AI assist.
- If the underlying error is ValueError/FileNotFound from the dataset itself, fix the dataset reference first — those surface as 4xx and are actionable.
Defensive patterns
Strategy: try-catch
Validate before calling
# Pre-flight: the same dataset ref must pass a cheap format check before the expensive AI pass fmt = check_dataset_format(client, req) # if this 4xx/5xx, AI assist will fail too
Try / catch
try:
resp = run_ai_assist(client, req)
except HTTPStatusError as e:
if e.response.status_code >= 500:
disable_ai_assist_with_reason(e.response.json()["detail"]) # model/env issue, not dataset
else:
fix_dataset_ref_and_retry(e) Prevention
- Pre-download the 7B helper model on first provisioning so AI assist never needs the network at run time.
- Run AI assist without concurrent training jobs to avoid VRAM contention.
- Validate the dataset loads (format check) before invoking the advisor.
When it happens
Trigger: The helper model fails to download or load (network, disk), inference OOMs on a GPU-poor machine, the datasets-derived prompt triggers an unexpected library error, or the hub raises an unmapped error while fetching the dataset.
Common situations: First run of AI assist with no cached model and a slow/blocked model host; small VRAM boxes; proxies blocking the model download; concurrent assist runs exhausting memory.
Related errors
- The inference worker stopped unexpectedly while loading the
- Failed to export GGUF model
- deadline reached while pacing before {method} {_redact_url(u
- VirusTotal returned HTTP {status} for {_redact_url(url)}
- VirusTotal request failed after {max_attempts} attempt(s): {
AI-assisted analysis of unslothai/unsloth@203007d190 (2026-08-15).
Data as JSON: /api/errors/d31eaa0241884592.
Report an issue: GitHub.