def get_available_languages():
 stopword_files = os.listdir(os.path.join(settings.STOPWORDS_DIR))
 two_dig_codes = [f.split('-')[1].split('.')[0] for f in stopword_files]
 for d in two_dig_codes:
  assert (len(d) == 2)
 return two_dig_codes

def get_available_languages ( ) : stopword_files = os . listdir ( os . path . join ( settings . STOPWORDS_DIR ) ) two_dig_codes = [ f . split ( '-' ) [ 1 ] . split ( '.' ) [ 0 ] for f in stopword_files ] for d in two_dig_codes : assert ( len ( d ) == 2 ) return two_dig_codes
returns a list of available languages and their 2 char input codes .