inital version exma
[itlast1617.git] / exam / q2.tex
diff --git a/exam/q2.tex b/exam/q2.tex
new file mode 100644 (file)
index 0000000..ecd1781
--- /dev/null
@@ -0,0 +1,47 @@
+\begin{enumerate}
+       % Question 2a
+       \item This can be achieved by adding disfluency rules to the \textsc{CFG}.
+               This has to be done for all rules that can possible produce
+               disfluencies. Most likely only the lowest level of rules (unit
+               productions) need such disfluency structures. For example, if we would
+               do it for the rule that transforms a \texttt{Noun} into a word it would
+               look like this:
+
+               \begin{lstlisting}
+Noun -> TrueNoun | EditNoun TrueNoun
+TrueNoun -> flight | ...
+
+EditNoun -> TrueNoun EditWord
+EditWord -> uh | ...
+               \end{lstlisting}
+
+               With feature structures this can be generalized and have less
+               ambiguitiy. Features can for example force the \emph{Reparandum} to be
+               of the same \texttt{CAT} as the \emph{Repair} and disfluencies might
+               have some constraints that can also be expressed with features.
+
+       % Question 2b
+       \item Standard \textsc{CKY} parsing only works for grammars in
+               \emph{Chomsky Normal Form} (\textsc{CNF}). This means that the tree
+               returned will not exactly represent the \textsc{CFG} since it possibly
+               had to be converted to \textsc{CNF}. To adapt \textsc{CKY} in a
+               fundamental way so that it correctly parses repair structures would be
+               very difficult, albeit impossible. It basically means that, in the
+               deepest loop, you have to build in functionality that is similar to the
+               grammar that recognizes such structures and behave accordingly. While
+               this is probably theoretically possible, it will result in a different
+               algorithm that has a hard-coded sub-grammar in itself.
+
+       % Question 2c
+       \item Similar to the previous sub-question; while it is possible to make the
+               \emph{Predictor} more smart and add disfluency structures to the chart
+               it would change the \emph{Earley} algorithm significantly. The change
+               of the algorithm would also be very specific to certain disfluency
+               structures and makes it possibly unusable for languages that do not
+               have such structures. Note that it is more easy to add this to an
+               \emph{Earley} parser compared to adding it to an \emph{CKY} parser. For
+               an \emph{Earley} parser it just means hard-coding some extra grammar
+               rules in the \emph{Predictor}. For \emph{CKY} it means transforming
+               the rules to specific transformations in the table which might not be
+               trivial.
+\end{enumerate}