auto gen script orig version