first working version with sb format