def METHOD_NAME():
    logging.basicConfig(level=logging.INFO, format='%(levelname)-8s: %(message)s')
    parser = argparse.ArgumentParser(description=__doc__.strip())
    parser.add_argument('--fileordir', action='store', default=os.getcwd(),
                        help="The JSON file or directory to process")
    args = parser.parse_args()
    if path.isfile(args.fileordir):
        filenames = [args.fileordir]
    else:
        filenames = [path.join(args.fileordir, x)
                     for x in os.listdir(args.fileordir)
                     if re.search('\.json$', x)]
    for filename in filenames:
        with open(filename, 'r') as infile:
            document = json.load(infile)
        title, body = parse_Document(document)
        for item in body:
            assert len(item) == 2
        body = remove_default_fonts(body)
        body = merge_runs(body)
        output_filename = filename.replace('.json', '.md')
        with open(output_filename, 'w') as outfile:
            renderer = Renderer(outfile)
            for etype, runs in body:
                fun = getattr(renderer, etype, None)
                if fun is None:
                    print(etype)
                else:
                    for run in runs:
                        fun(run)
            # print(title, file=outfile)
            # print(pprint.pformat(body), file=outfile)