diff --git a/pom.xml b/pom.xml
index e4b88f2..b03027c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -11,11 +11,8 @@
     <artifactId>KorAP-querySerialization</artifactId>
     <version>0.0.2</version>
     <packaging>jar</packaging>
-
-
     <name>KorAP-querySerialization</name>
     <url>http://maven.apache.org</url>
-
     <dependencies>
         <dependency>
             <groupId>org.antlr</groupId>
diff --git a/src/main/java/de/ids_mannheim/korap/query/serialize/MetaQuery.java b/src/main/java/de/ids_mannheim/korap/query/serialize/MetaQuery.java
index caf7154..f7f0ec6 100644
--- a/src/main/java/de/ids_mannheim/korap/query/serialize/MetaQuery.java
+++ b/src/main/java/de/ids_mannheim/korap/query/serialize/MetaQuery.java
@@ -3,7 +3,7 @@
 import com.fasterxml.jackson.core.JsonProcessingException;
 import com.fasterxml.jackson.databind.ObjectMapper;
 
-import java.util.HashMap;
+import java.util.LinkedHashMap;
 import java.util.LinkedList;
 import java.util.List;
 import java.util.Map;
@@ -19,17 +19,17 @@
 
     public MetaQuery() {
         this.serialier = new ObjectMapper();
-        meta = new HashMap();
+        this.meta = new LinkedHashMap();
     }
 
-    public MetaQuery addContext(Object left, Object right, String type) {
-        Map map = new HashMap();
+    public MetaQuery addContext(Integer left, String leftType, Integer right, String rightType) {
+        Map map = new LinkedHashMap();
         List l = new LinkedList();
         List r = new LinkedList();
-        l.add(type);
+        l.add(leftType);
         l.add(left);
         map.put("left", l);
-        r.add(type);
+        r.add(rightType);
         r.add(right);
         map.put("right", r);
         meta.put("context", map);
@@ -41,7 +41,11 @@
         return this;
     }
 
-    public String toMeta() {
+    public Map raw() {
+        return meta;
+    }
+
+    public String toMetaString() {
         try {
             return serialier.writeValueAsString(meta);
         } catch (JsonProcessingException e) {
diff --git a/src/main/java/de/ids_mannheim/korap/query/serialize/QuerySerializer.java b/src/main/java/de/ids_mannheim/korap/query/serialize/QuerySerializer.java
index 21e0852..636888d 100644
--- a/src/main/java/de/ids_mannheim/korap/query/serialize/QuerySerializer.java
+++ b/src/main/java/de/ids_mannheim/korap/query/serialize/QuerySerializer.java
@@ -4,7 +4,6 @@
 import com.fasterxml.jackson.databind.JsonMappingException;
 import com.fasterxml.jackson.databind.ObjectMapper;
 import com.fasterxml.jackson.databind.SerializationFeature;
-
 import de.ids_mannheim.korap.util.QueryException;
 import org.slf4j.LoggerFactory;
 
@@ -49,28 +48,28 @@
 					 * & field_group
 					 */
                     "Buch",
-            		"das Buch",
-    				"das /+w1:3 Buch",
-    				"das /+w1:3,s1 Buch",
-    				"(das /+w1:3,s1 Buch) /+w5 Tisch",
-    				"(das /+w1:3,s1 Buch) /-w5 Tisch",
-    				"(das /+w1:3,s1 Buch) /+w5 (auf dem Tisch)",
-    				
-    				
-    				"Institut für Deutsche Sprache",
-    				"Institut für deutsche Sprache",
-    				"Institut für $deutsche Sprache",
-    				"Institut für &deutsch Sprache",
-    				"Institut für /+w2 Sprache",
-    				"Institut für %+w1 deutsche Sprache",
-    				"Institut für MORPH(A) Sprache",
-    				
-    				"wegen #IN(L) <s>",
-    				"$wegen #IN(L) <s>",
-    				"#BED($wegen , +sa)",
-    				"#BEG(#ELEM(S))",
-    				"MORPH(V) #IN(L) #ELEM(S)",
-    				"MORPH(V) #IN(R) #ELEM(S)",
+                    "das Buch",
+                    "das /+w1:3 Buch",
+                    "das /+w1:3,s1 Buch",
+                    "(das /+w1:3,s1 Buch) /+w5 Tisch",
+                    "(das /+w1:3,s1 Buch) /-w5 Tisch",
+                    "(das /+w1:3,s1 Buch) /+w5 (auf dem Tisch)",
+
+
+                    "Institut für Deutsche Sprache",
+                    "Institut für deutsche Sprache",
+                    "Institut für $deutsche Sprache",
+                    "Institut für &deutsch Sprache",
+                    "Institut für /+w2 Sprache",
+                    "Institut für %+w1 deutsche Sprache",
+                    "Institut für MORPH(A) Sprache",
+
+                    "wegen #IN(L) <s>",
+                    "$wegen #IN(L) <s>",
+                    "#BED($wegen , +sa)",
+                    "#BEG(#ELEM(S))",
+                    "MORPH(V) #IN(L) #ELEM(S)",
+                    "MORPH(V) #IN(R) #ELEM(S)",
 
             };
         } else {
@@ -115,9 +114,9 @@
             throws JsonGenerationException, JsonMappingException, IOException, QueryException {
         if (queryLanguage.equals("poliqarp")) {
             ast = new PoliqarpPlusTree(query);
-		} else if (queryLanguage.equals("cosmas")) {
-			ast = new CosmasTree(query);
-        } else if (queryLanguage.equals("poliqarpplus")) {
+        } else if (queryLanguage.toLowerCase().equals("cosmas2")) {
+            ast = new CosmasTree(query);
+        } else if (queryLanguage.toLowerCase().equals("poliqarpplus")) {
             ast = new PoliqarpPlusTree(query);
         } else {
             throw new QueryException(queryLanguage + " is not a supported query language!");
@@ -132,26 +131,30 @@
             throws QueryException {
         if (ql.toLowerCase().equals("poliqarp")) {
             ast = new PoliqarpPlusTree(query);
-		} else if (ql.toLowerCase().equals("cosmas")) {
-			ast = new CosmasTree(query);
+        } else if (ql.toLowerCase().equals("cosmas2")) {
+            ast = new CosmasTree(query);
         } else if (ql.toLowerCase().equals("poliqarpplus")) {
             ast = new PoliqarpPlusTree(query);
         } else {
             throw new QueryException(ql + " is not a supported query language!");
         }
+
         Map<String, Object> requestMap = ast.getRequestMap();
         CollectionQuery collectionQuery = new CollectionQuery();
         collectionQuery.addResources(parents);
 
+        MetaQuery meta = new MetaQuery();
+        meta.addContext(cls, cli, crs, cri);
+        meta.addEntry("cutOff", cutoff);
+        meta.addEntry("startPage", page);
+        meta.addEntry("count", num);
+
         try {
-            requestMap.put("meta", collectionQuery.raw());
-            requestMap = QueryUtils.addParameters(requestMap, page, num,
-                    cli, cri, cls, crs, cutoff);
-            String res = mapper.writeValueAsString(requestMap);
-            return res;
+            requestMap.put("collections", collectionQuery.raw());
+            requestMap.put("meta", meta.raw());
+            return mapper.writeValueAsString(requestMap);
         } catch (IOException e) {
-            e.printStackTrace();
-            return null;
+            return "";
         }
 
     }
