Refactor KSO Builder to use jQuery