Index: trunk/autoquest-ui-core-alignment/src/main/java/de/ugoe/cs/autoquest/commands/usability/CMDgenerateTaskTree.java
===================================================================
--- trunk/autoquest-ui-core-alignment/src/main/java/de/ugoe/cs/autoquest/commands/usability/CMDgenerateTaskTree.java	(revision 1705)
+++ trunk/autoquest-ui-core-alignment/src/main/java/de/ugoe/cs/autoquest/commands/usability/CMDgenerateTaskTree.java	(revision 1707)
@@ -28,7 +28,7 @@
 /**
  * <p>
- * This command generates a task tree based on the provided sequences. It uses the
- * {@link TaskTreeManager} for this purpose. Please consult the documentation of the task tree
- * manager for more details.
+ * This command generates a task tree based on the provided sequences. It uses
+ * the {@link TaskTreeManager} for this purpose. Please consult the
+ * documentation of the task tree manager for more details.
  * </p>
  * 
@@ -38,57 +38,77 @@
 public class CMDgenerateTaskTree implements Command {
 
-    /*
-     * (non-Javadoc)
-     * 
-     * @see de.ugoe.cs.util.console.Command#help()
-     */
-    @Override
-    public String help() {
-        return "generateTaskTree <sequences> {<tasktree>}";
-    }
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see de.ugoe.cs.util.console.Command#help()
+	 */
+	@Override
+	public String help() {
+		return "generateTaskTree <sequences> {<tasktree>} {<boolean: harmonize sequences or not (true or false)>} {<integer: number of threads>}";
+	}
 
-    /*
-     * (non-Javadoc)
-     * 
-     * @see de.ugoe.cs.util.console.Command#run(java.util.List)
-     */
-    @SuppressWarnings("unchecked")
-    @Override
-    public void run(List<Object> parameters) {
-        String sequencesName;
-        String tasktreeName;
-        try {
-            sequencesName = (String) parameters.get(0);
-            if (parameters.size() > 1) {
-                tasktreeName = (String) parameters.get(1);
-            }
-            else {
-                tasktreeName = "tasktree";
-            }
-        }
-        catch (Exception e) {
-            throw new IllegalArgumentException("must provide a sequences name");
-        }
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see de.ugoe.cs.util.console.Command#run(java.util.List)
+	 */
+	@SuppressWarnings("unchecked")
+	@Override
+	public void run(List<Object> parameters) {
+		String sequencesName;
+		String tasktreeName;
+		try {
+			sequencesName = (String) parameters.get(0);
+			if (parameters.size() > 1) {
+				tasktreeName = (String) parameters.get(1);
+			} else {
+				tasktreeName = "tasktree";
+			}
+		} catch (Exception e) {
+			throw new IllegalArgumentException("must provide a sequences name");
+		}
+		if (parameters.size() > 2) {
+			String harmonize = (String) parameters.get(2);
+			de.ugoe.cs.autoquest.tasktrees.temporalrelation.SequenceForTaskDetectionRuleAlignment.harmonizeSequences = true;
+			System.out.println(harmonize);
+			if (harmonize.equals("false")) {
+				System.out.println("Not harmonizing");
+				de.ugoe.cs.autoquest.tasktrees.temporalrelation.SequenceForTaskDetectionRuleAlignment.harmonizeSequences = false;
+			}
+		}
+		if (parameters.size() > 3) {
+			String threadCount = (String) parameters.get(3);
+			de.ugoe.cs.autoquest.tasktrees.temporalrelation.SequenceForTaskDetectionRuleAlignment.nThreads = 1;
+			try {
+				int tmp = Integer.parseInt(threadCount);
+				de.ugoe.cs.autoquest.tasktrees.temporalrelation.SequenceForTaskDetectionRuleAlignment.nThreads = tmp;
+			} catch (Exception e) {
+				throw new IllegalArgumentException(
+						"The fourth parameter must be an integer. Did you forget to name the tasktree?");
+			}
+		}
 
-        Collection<List<Event>> sequences = null;
-        Object dataObject = GlobalDataContainer.getInstance().getData(sequencesName);
-        if (dataObject == null) {
-            CommandHelpers.objectNotFoundMessage(sequencesName);
-            return;
-        }
-        if (!SequenceInstanceOf.isCollectionOfSequences(dataObject)) {
-            CommandHelpers.objectNotType(sequencesName, "Collection<List<Event<?>>>");
-            return;
-        }
+		Collection<List<Event>> sequences = null;
+		Object dataObject = GlobalDataContainer.getInstance().getData(
+				sequencesName);
+		if (dataObject == null) {
+			CommandHelpers.objectNotFoundMessage(sequencesName);
+			return;
+		}
+		if (!SequenceInstanceOf.isCollectionOfSequences(dataObject)) {
+			CommandHelpers.objectNotType(sequencesName,
+					"Collection<List<Event<?>>>");
+			return;
+		}
 
-        sequences = (Collection<List<Event>>) dataObject;
-        
-        ITaskModel taskModel = new TaskTreeManager().createTaskModel(sequences);
-        
-        if (GlobalDataContainer.getInstance().addData(tasktreeName, taskModel)) {
-            CommandHelpers.dataOverwritten(sequencesName);
-        }
-        
-    }
+		sequences = (Collection<List<Event>>) dataObject;
+
+		ITaskModel taskModel = new TaskTreeManager().createTaskModel(sequences);
+
+		if (GlobalDataContainer.getInstance().addData(tasktreeName, taskModel)) {
+			CommandHelpers.dataOverwritten(sequencesName);
+		}
+
+	}
 
 }
