James puppet code