<s> """<STR_LIT>""" <EOL> allowed_tags = ( <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" , <EOL> ) <EOL> class TagSet ( set ) : <EOL> def onSignal ( self , signal ) : <EOL> if type ( signal ) is str : <EOL> signal = signal . split ( ) <EOL> for tag in signal : <EOL> self . add ( tag ) <EOL> def check ( self , tags ) : <EOL> for tag in tags . split ( ) : <EOL> assert tag in allowed_tags , tag <EOL> if tag in self : <EOL> return True <EOL> return False <EOL> def add ( self , tag ) : <EOL> assert tag in allowed_tags , tag <EOL> set . add ( self , tag ) </s>
