class UnknownWordFinderForCsv {

  private void run(File dir, JLanguageTool lt) throws IOException {
    SpellingCheckRule spellerRule = getSpellingCheckRule(lt);
    List<Path> files = Files.walk(dir.toPath()).filter(Files::isRegularFile).collect(Collectors.toList());
    for (Path file : files) {
      handle(file, spellerRule);
    }
  }

  @NotNull
  private SpellingCheckRule getSpellingCheckRule(JLanguageTool lt) {
    SpellingCheckRule spellerRule = null;
    for (Rule rule : lt.getAllActiveRules()) {
      if (rule.isDictionaryBasedSpellingRule()) {
        if (spellerRule != null) {
          throw new RuntimeException("Found more than one spell rule: " + rule + ", " + spellerRule);
        }
        spellerRule = (SpellingCheckRule) rule;
      }
    }
    if (spellerRule == null) {
      throw new RuntimeException("No speller rule found for " + lt.getLanguage());
    }
    return spellerRule;
  }

  private void handle(Path f, SpellingCheckRule rule) throws IOException {
    int i = 0;
    if (f.toString().toLowerCase().endsWith(".csv")) {
      List<String> lines = Files.readAllLines(f);
      for (String line : lines) {
        String[] parts = line.split(",");
        String word = parts[0].replace("\"", "");
        if (rule.isMisspelled(word)) {
          System.out.println(line);
          i++;
        }
      }
    } else {
      System.out.println("Ignoring " + f + ": unknown suffix");
    }
    System.out.println("Lines printed: " + i);
  }

  public static void main(String[] args) throws IOException {<FILL_FUNCTION_BODY>}
}

    if (args.length != 2) {
      System.out.println("Usage: " + UnknownWordFinderForCsv.class.getSimpleName() +  " <langCode> <dir>");
      System.exit(1);
    }
    JLanguageTool lt = new JLanguageTool(Languages.getLanguageForShortCode(args[0]));
    new UnknownWordFinderForCsv().run(new File(args[1]), lt);
  
<no_super_class>