code: public static void merge(String source, String target) throws IOException{
          final AtomicLong count = new AtomicLong();
          final AtomicLong lines = new AtomicLong();
          try(BufferedWriter writer = new BufferedWriter(new OutputStreamWriter(new FileOutputStream(target),"utf-8"))){
              Files.walkFileTree(Paths.get(source), new SimpleFileVisitor<Path>(){
  
                      @Override
                      public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) throws IOException {
                          LOGGER.info("处理文件："+file);
                          try(BufferedReader reader = new BufferedReader(new InputStreamReader(new FileInputStream(file.toFile()),"utf-8"));){
                              String line;
                              while( (line = reader.readLine()) != null ){
                                  count.addAndGet(line.length());
                                  lines.incrementAndGet();
                                  writer.write(line+"\n");
                              }
                          }
                          return FileVisitResult.CONTINUE;
                      }
                      
                  });
          }
          LOGGER.info("语料库行数："+lines.get());
          LOGGER.info("语料库字符数目："+count.get());
      }
docs: 将多个语料库文件合并为一个
  @param source 目录，可多级嵌套
  @param target 目标文件
  @throws IOException