Adding linked references, some cleanup