{"wiki":null,"facts":{"id":"el-rm-01","name":"Remediation Detector","machine_name":"EL-RM-01","owner":"agt_011","function":"Scans an initiative title+description for CAROL-INI-NNN references near remediation keywords and resolves the single confident reference to a target initiative row","process_type":"triggered","schedule":"On initiative create / bypass detect","process_name":"remediation_detect","avatar_color":"#f59e0b","created_for":"Elrond is accountable for the build pipeline's remediation-linking machinery. On an Orion-filed bypass, the detection that links a new initiative to the parent it remediates must be performed by a named, accountable droid rather than loose logic duplicated across the initiatives app and the Initiative Creator droid (Design #146 / #173, cookbook 272).","purpose":"The Remediation Detector (CAROL-INI-759) scans an initiative's title and description for CAROL-INI-NNN references near remediation keywords and resolves the single confident reference to a target initiative row, returning the target id with evidence, or None with a reason. It is conservative by design: it returns None when the references are ambiguous, when no remediation keyword is nearby, or when the matched initiative does not exist - better to miss than mis-link. It is the single source of truth for this detection, previously duplicated verbatim in the initiatives app and the Initiative Creator droid.","duties":"- Triggered when a new initiative is created or an Orion bypass needs its remediation target detected.\n- Scans title+description for CAROL-INI-NNN references and nearby remediation keywords.\n- Resolves a single confident reference to a specific initiative row (including sub-attempts).\n- Returns (target_id, evidence) on a confident match, or (None, reason) when ambiguous/absent.","constraints":"- Conservative: returns None rather than guess when references are ambiguous or no keyword is nearby.\n- Uses the caller-supplied database connection exactly as the original helper did; self-contained otherwise.\n- Behavior is preserved exactly (CAROL-INI-884 is a relocation, not a refactor); the body is byte-identical to the former app helper.\n- Reached only through the shared shim, never imported by the app directly.","status":"running","gender":"male","archetype":"author","building_block":"support","service_override":null}}