fix class name, derive all classes from base class, add support for instance-ids