43 lines
1.2 KiB
Haskell
43 lines
1.2 KiB
Haskell
{-# LANGUAGE TypeSynonymInstances #-}
|
|
{-# LANGUAGE FlexibleInstances #-}
|
|
|
|
module Main (
|
|
module ParserW,
|
|
module Parse,
|
|
module Step,
|
|
module G1,
|
|
module PoliMorf,
|
|
module Data.ADTTag.IPITag.PoliMorf,
|
|
module PL1,
|
|
main
|
|
) where
|
|
|
|
|
|
import ParserW
|
|
import Parse
|
|
import Step
|
|
import G1
|
|
import Data.ADTTag.IPITag.PoliMorf
|
|
import PoliMorf
|
|
import PL1
|
|
import Weighted
|
|
|
|
instance Show (WeightedList IPITag) where
|
|
show = show . runWeightedT
|
|
|
|
main = do
|
|
pm <- readPoliMorfHead1 200000 "pm.sorted.uniq.tsv"
|
|
let l = length (parse' pm pl1' "dom" :: WeightedList (Parse Role (WeightedList IPITag)))
|
|
putStrLn $ "READY (" ++ show l ++ ")"
|
|
input <- getLine
|
|
let WeightedT parses = parseA' pm pl1' input :: WeightedList (Parse Role (WeightedList IPITag))
|
|
parselist = zip [1..] parses
|
|
-- sequence_ $ map (\(n,p) -> do
|
|
-- putStrLn $ "*** [" ++ show n ++ "] ***"
|
|
-- putStrLn $ show p
|
|
-- ) parselist
|
|
|
|
putStrLn $ "PARSES: " ++ show (length parselist)
|
|
putStrLn $ "COMPLE: " ++ show (length (filter ((== 1) . trees . bare . snd) parselist))
|
|
|