surfacecleaningclean_year_llm
Cleaningscalar · returns integer

CLEAN_YEAR_LLM

LLM-backed year extraction (escape hatch for CLEAN_YEAR)

Per-row — runs once for each row.

cleaningllmllm-escape-hatchdate

Syntax

CLEAN_YEAR_LLM({{ text }})

Arguments

nametypedescription
textVARCHAR

About

LLM-backed escape hatch for year extraction. Use when the canonical regex path (CLEAN_YEAR) can't handle the input — typically spelled-out years ("nineteen eighty-four") or language-specific year phrasings. For standard year formats, prefer CLEAN_YEAR — much faster and fully deterministic.

Examples

Spelled-out year extracted

SELECT
  clean_year_llm ('nineteen eighty-four')

Fiscal year extracted

SELECT
  clean_year_llm ('FY2023')

Nearby rabbit holes

same domain
Climb back to The Looking Glass