diff options
| author | aarne <aarne@cs.chalmers.se> | 2006-02-08 10:18:00 +0000 |
|---|---|---|
| committer | aarne <aarne@cs.chalmers.se> | 2006-02-08 10:18:00 +0000 |
| commit | 98b24d0e33e2cb90244773f8ad7d3c4f3f73ecd0 (patch) | |
| tree | 362fc849521607bb1bb5761b50f3f17ec317ae26 /src/GF/Shell | |
| parent | 85910ef7766d70e9bb0674eb9f29ae4b05f98267 (diff) | |
command tb for creating treebanks
Diffstat (limited to 'src/GF/Shell')
| -rw-r--r-- | src/GF/Shell/HelpFile.hs | 7 | ||||
| -rw-r--r-- | src/GF/Shell/PShell.hs | 1 | ||||
| -rw-r--r-- | src/GF/Shell/ShellCommands.hs | 2 |
3 files changed, 10 insertions, 0 deletions
diff --git a/src/GF/Shell/HelpFile.hs b/src/GF/Shell/HelpFile.hs index dd03d2515..14c87e621 100644 --- a/src/GF/Shell/HelpFile.hs +++ b/src/GF/Shell/HelpFile.hs @@ -229,6 +229,13 @@ txtHelpFile = "\n examples:" ++ "\n p -lang=Cncdecimal \"123\" | at num2bin | l -- convert dec to bin" ++ "\n" ++ + "\ntb, tree_bank: tb" ++ + "\n Generate a multilingual treebank from a list of trees." ++ + "\n flags:" ++ + "\n -xml wrap the treebank with XML tags" ++ + "\n examples:" ++ + "\n gr -cat=S -number=100 | tb" ++ + "\n" ++ "\ntt, test_tokenizer: tt String" ++ "\n Show the token list sent to the parser when String is parsed." ++ "\n HINT: can be useful when debugging the parser." ++ diff --git a/src/GF/Shell/PShell.hs b/src/GF/Shell/PShell.hs index aba743503..676e54c46 100644 --- a/src/GF/Shell/PShell.hs +++ b/src/GF/Shell/PShell.hs @@ -113,6 +113,7 @@ pCommand ws = case ws of "tt" : s -> aString CTestTokenizer s "cc" : s -> aUnit $ CComputeConcrete $ unwords s "so" : s -> aUnit $ CShowOpers $ unwords s + "tb" : [] -> aUnit CTreeBank "tq" : i:o:[] -> aUnit (CTranslationQuiz (language i) (language o)) "tl":i:o:[] -> aUnit (CTranslationList (language i) (language o)) diff --git a/src/GF/Shell/ShellCommands.hs b/src/GF/Shell/ShellCommands.hs index 48eac25a5..935b0be09 100644 --- a/src/GF/Shell/ShellCommands.hs +++ b/src/GF/Shell/ShellCommands.hs @@ -48,6 +48,7 @@ data Command = | CTranslate Language Language | CGenerateRandom | CGenerateTrees + | CTreeBank | CPutTerm | CWrapTerm I.Ident | CApplyTransfer (Maybe I.Ident, I.Ident) @@ -182,6 +183,7 @@ optionsOfCommand co = case co of CGenerateRandom -> both "cf prob" "cat lang number depth" CGenerateTrees -> both "metas" "atoms depth alts cat lang number" CPutTerm -> flags "transform number" + CTreeBank -> opts "xml" CWrapTerm _ -> opts "c" CApplyTransfer _ -> flags "lang transfer" CMorphoAnalyse -> both "short" "lang" |
