Helper to extract and preprocess relevant attributes from rstudioapi::getActiveDocumentContext().

find_active_context()