further optimize context loading