def extend_with_language_model(BaseModel):
    '添加下三角的Attention Mask（语言模型用）\n    '

    class LanguageModel(LM_Mask, BaseModel):
        '带下三角Attention Mask的派生模型\n        '

        def __init__(self, *args, **kwargs):
            super(LanguageModel, self).__init__(*args, **kwargs)
            self.with_mlm = (self.with_mlm or True)
    return LanguageModel
添加下三角的Attention Mask（语言模型用）
def extend_with_language_model(BaseModel):
    '\n    '

    class LanguageModel(LM_Mask, BaseModel):
        '带下三角Attention Mask的派生模型\n        '

        def __init__(self, *args, **kwargs):
            super(LanguageModel, self).__init__(*args, **kwargs)
            self.with_mlm = (self.with_mlm or True)
    return LanguageModel