create subclasses and refine structure