}
}
private static JSAP initArgsParser() throws JSAPException
{
JSAP jsap = new JSAP();
FlaggedOption opt1 = new FlaggedOption(Config.DOCUMENT_PATH.toString()).setStringParser(FileStringParser.getParser())
.setRequired(true)
.setShortFlag('p')
.setLongFlag("peer");
opt1.setHelp("The path to the peer summaries.");
jsap.registerParameter(opt1);
FlaggedOption opt2 = new FlaggedOption(Config.GOLD_STANDARD_PATH.toString()).setStringParser(FileStringParser.getParser())
.setRequired(true)
.setShortFlag('g')
.setLongFlag("goldstandard");
opt2.setHelp("The path to the gold standard summaries.");
jsap.registerParameter(opt2);
FlaggedOption opt3 = new FlaggedOption(Config.GRAM_SIZE.toString()).setStringParser(JSAP.INTEGER_PARSER)
.setRequired(true)
.setShortFlag('n')
.setLongFlag(JSAP.NO_LONGFLAG);
opt3.setHelp("The size of the gram to use.");
jsap.registerParameter(opt3);
FlaggedOption opt4 = new FlaggedOption(Config.WORD_LIMIT.toString()).setStringParser(JSAP.INTEGER_PARSER)
.setRequired(false)
.setDefault(Integer.MAX_VALUE + "")
.setShortFlag('l')
.setLongFlag(JSAP.NO_LONGFLAG);
opt4.setHelp("The number of words to use from the texts.");
jsap.registerParameter(opt4);
FlaggedOption opt5 = new FlaggedOption(Config.BYTE_LIMIT.toString()).setStringParser(JSAP.INTEGER_PARSER)
.setRequired(false)
.setDefault(Integer.MAX_VALUE + "")
.setShortFlag('b')
.setLongFlag(JSAP.NO_LONGFLAG);
opt5.setHelp("The number of bytes to use from each text.");
jsap.registerParameter(opt5);
FlaggedOption opt6 = new FlaggedOption(Config.ALPHA.toString()).setStringParser(JSAP.DOUBLE_PARSER)
.setRequired(false)
.setDefault("0.5")
.setShortFlag('a')
.setLongFlag(JSAP.NO_LONGFLAG);
opt6.setHelp("The alpha value used to calculate F metric");
jsap.registerParameter(opt6);
FlaggedOption opt7 = new FlaggedOption(Config.METHOD.toString()).setStringParser(JSAP.CHARACTER_PARSER)
.setRequired(false)
.setDefault("A")
.setShortFlag('m')
.setLongFlag(JSAP.NO_LONGFLAG);
opt7.setHelp("The method used to calculate the metrics. Use 'A' for average, use 'B' for best.");
jsap.registerParameter(opt7);
Switch opt8 = new Switch(Config.VERBOSE.toString()).setDefault("false")
.setShortFlag('v')
.setLongFlag(JSAP.NO_LONGFLAG);
opt8.setHelp("Show verbose data during run.");
jsap.registerParameter(opt8);
QualifiedSwitch opt9 = (QualifiedSwitch) new QualifiedSwitch(Config.CONFIDENCE.toString()).setShortFlag('c')
.setLongFlag("confidence")
.setList(JSAP.NOT_LIST)
.setStringParser(JSAP.DOUBLE_PARSER)
.setRequired(false);
opt9.setHelp("Calculate and show confidence intervals");
jsap.registerParameter(opt9);
return jsap;
}