def METHOD_NAME(self, sig, signode):
    """Handle the initial signature of the node.
    This formats the header of the section.
    """
    raw_obj_type = "code" if len(sig) == 4 else "rule"
    obj_type = raw_obj_type.capitalize() + " "
    signode += addnodes.desc_type(obj_type, obj_type)
    signode += addnodes.desc_name(sig, sig)
    fullname = obj_type + sig
    signode["type"] = raw_obj_type
    signode["sig"] = sig
    signode["fullname"] = fullname
    return (fullname, raw_obj_type, sig)