| Algorithm 1 LTA-Alignment with LLM Arbiter |
|
Input: Candidate entity pair (ei,ej), Total linear length Ltotal, Semantic threshold [τlow,τhigh], Gaussian tolerance σ. Output: Alignment decision D∈{Merge,Reject} 1: Phase 1: Gaussian Topological Penalty Computation 2: Extract semantic embeddings vi,vj for ei,ej 3: Simsem ← CosineSimilarity(vi,vj) 4: Extract absolute physical distances li,lj for ei,ej 5: 6: 7: 8: 9: Phase 2: Grey-Zone Arbitration Logic 10: if S < τlow then 11: (Short-circuit rejection) 12: else if S > τhigh then 13: (Direct unconditional merge) 14: else (Grey-Zone triggered) 15: Cctx ← ExtractContext(ei,ej) (e.g., timestamps, worker logs) 16: Pprompt ← ConstructPrompt(ei,ej,Cctx) 17: decision_result ← LLM_Arbiter(Pprompt) 18: if decision_result == “Yes” then 19: 20: else 21: 22: end if 23: end if 24: return: |