coding for base framework