updated krl script