public LinkedList<String> operatePhoenix(String runParse, int extractFlag, File compile) {
		LinkedList<String> phoenixOutput = new LinkedList<String>();
		  
		try {
			//compile grammar
			compile(compile);
		  
			//run parse for file input
			ProcessBuilder phoenixBuilder = new ProcessBuilder("/bin/tcsh", runParse);
			phoenixBuilder.directory(new File("resources/nlu/Phoenix/TalkingRobot"));
			phoenixBuilder.redirectInput(new File("resources/nlu/Phoenix/TalkingRobot/input"));
			Process phoenix = phoenixBuilder.start();
		  
		  
		  	BufferedReader stdin2 = new BufferedReader(new InputStreamReader(phoenix.getInputStream()));
		  	BufferedReader stderr2 = new BufferedReader(new InputStreamReader(phoenix.getErrorStream()));
		  
		  	String phoenixLine2 = null;
		  
		  	while ((phoenixLine2 = stderr2.readLine()) != null && (!phoenixLine2.equals("READY"))) {
		  		stdin2.close();
		  		stderr2.close();
		  		phoenix.destroy();
		  		compile(compile);
		  		return operatePhoenix(runParse, extractFlag, compile);
		  	}

		  	while ((phoenixLine2 = stdin2.readLine()) != null) {
		  		phoenixOutput = insertWords(extractFlag, phoenixOutput, phoenixLine2);
		  	}	  
		} catch (IOException e) {
			e.printStackTrace();
		}
		return phoenixOutput;
	}