summaryrefslogtreecommitdiff
path: root/src/compiler/GF/Command/Commands.hs
diff options
context:
space:
mode:
authorkr.angelov <kr.angelov@gmail.com>2013-11-06 10:21:46 +0000
committerkr.angelov <kr.angelov@gmail.com>2013-11-06 10:21:46 +0000
commit2483dc772897eb0909664f1a88cc7f8ec50ebd5b (patch)
tree4ecb223fc246458a9a5997a4b65329b6039ce309 /src/compiler/GF/Command/Commands.hs
parent84ef5fa5fa976569370c58bed855f2ab1de5588c (diff)
the content of ParseEngAbs3.probs is now merged with ParseEngAbs.probs. The later is now retrained. Once the grammar is compiled with the .probs file now it doesn't need anything more to do robust parsing. The robustness itself is controlled by the flags 'heuristic_search_factor', 'meta_prob' and 'meta_token_prob' in ParseEngAbs.gf
Diffstat (limited to 'src/compiler/GF/Command/Commands.hs')
-rw-r--r--src/compiler/GF/Command/Commands.hs12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/compiler/GF/Command/Commands.hs b/src/compiler/GF/Command/Commands.hs
index 6769b283d..58e485768 100644
--- a/src/compiler/GF/Command/Commands.hs
+++ b/src/compiler/GF/Command/Commands.hs
@@ -1134,15 +1134,19 @@ allCommands = Map.fromList [
case arg of
[EFun id] -> case Map.lookup id (funs (abstract pgf)) of
Just fd -> do putStrLn $ render (ppFun id fd)
- putStrLn ("Probability: "++show (probTree pgf (EFun id)))
+ let (_,_,_,prob,_) = fd
+ putStrLn ("Probability: "++show prob)
return void
Nothing -> case Map.lookup id (cats (abstract pgf)) of
- Just hyps -> do putStrLn $
- render (ppCat id hyps $$
+ Just cd -> do putStrLn $
+ render (ppCat id cd $$
if null (functionsToCat pgf id)
then empty
else space $$
- vcat [ppFun fid (ty,0,Just [],0,0) | (fid,ty) <- functionsToCat pgf id])
+ vcat [ppFun fid (ty,0,Just [],0,0) | (fid,ty) <- functionsToCat pgf id] $$
+ space)
+ let (_,_,prob,_) = cd
+ putStrLn ("Probability: "++show prob)
return void
Nothing -> do putStrLn ("unknown category of function identifier "++show id)
return void