generalized sript