#!/usr/local/bin/python2 class AutoNaming(type): def __init__(cls, name, bases, namespace): if 'name' not in namespace and getattr(cls, '_automates_naming', True): cls.name = name[0].lower() + name[1:] class CustomClass(object): __metaclass__ = AutoNaming print C.name