public static ArrayList convertIOB(ArrayList sentences) {
		ArrayList<String> iob = new ArrayList<String>();

		for (int i = 0; i < sentences.size(); i++) {
			String sentence = (String) sentences.get(i);
			String[] tokens = sentence.trim().split("[\t ]+");

			for (int j = 0; j < tokens.length; j++) {
				String[] features = tokens[j].split("\\|\\|");
				if (features.length != 2) {
					System.err.println("err: mal-formatted data");
					System.exit(0);
				}
				String word = features[0].split("\\|")[0];
				String label = features[1];

				iob.add(word + "\t" + label);
			}

			iob.add("O" + "\t" + "O"); // empty line
		}

		// for (int i = 0; i < iob.size(); i++)
		// System.out.println (iob.get(i));

		return iob;
	}