code: public void generateProfile() {
          File directory = new File(arglist.get(0));
          String lang = arglist.get(1);
          File file = searchFile(directory, lang + "wiki-.*-abstract\\.xml.*");
          if (file == null) {
              System.err.println("Not Found text file : lang = " + lang);
              return;
          }
  
          try(FileOutputStream outputStream = new FileOutputStream(new File(lang))) {
              LangProfile profile = GenProfile.load(lang, file);
              profile.omitLessFreq();
              new LangProfileWriter().write(profile, outputStream);
          } catch (IOException e) {
              e.printStackTrace();
          }
      }
docs: Generate Language Profile from a text file.
  
  <pre>
  usage: --genprofile [text file] [language name]
  </pre>