[advanced logging and ppretty printing, added verbosity option, debug dumps to stdout
martin.hofmann@uni-bamberg.de**20090624103838] hunk ./src/Data/GlobalConfig.hs 5
-    Config(..), RecArgComp(..), defaultConfig
+    SCR(..), RecArgComp(..), defaultSCR
hunk ./src/Data/GlobalConfig.hs 11
-data Config = Conf
-    { cnf_debug      :: Bool
-    , cnf_simplify   :: Bool
-    , cnf_enhanced   :: Bool
-    , cnf_maxLoops   :: Integer
-    , cnf_recArgComp :: RecArgComp
-    , cnf_tgts       :: [Name]
-    , cnf_bgks       :: [Name]
+
+--------------------------------------------------------------------------------
+-- Synthesis Configuration Record (SCR)
+--------------------------------------------------------------------------------
+
+data SCR = SCR
+    { scr_debug      :: Bool
+    , scr_simplify   :: Bool
+    , scr_enhanced   :: Bool
+    , scr_verbosity  :: Priority
+    , scr_maxLoops   :: Integer
+    , scr_recArgComp :: RecArgComp
+    , scr_tgts       :: [Name]
+    , scr_bgks       :: [Name]
hunk ./src/Data/GlobalConfig.hs 30
-defaultConfig = Conf False False False (-1) Linear [] []
+defaultSCR = SCR False False False NOTICE (-1) Linear [] []
hunk ./src/Data/GlobalConfig.hs 32
-instance Pretty Config where
-    pretty c = (fill 20 (text "Targets") <+> hsep (map (squotes.pretty) (cnf_tgts c)) <$>
+instance Pretty SCR where
+    pretty c = (fill 20 (text "Targets") <+> hsep (map (squotes.pretty) (scr_tgts c)) <$>
hunk ./src/Data/GlobalConfig.hs 35
-                    (if null (cnf_bgks c) then text "<none>"
-                       else hsep (map (squotes.pretty) (cnf_bgks c))) <$>
-                fill 20 (text "Compare rec args") <+> pretty (show.cnf_recArgComp $ c) <$>
-                fill 20 (text "Debug") <+> bool (cnf_debug c) <$>                
-                fill 20 (text "Simplified") <+> bool (cnf_simplify c) <$>                              
-                fill 20 (text "Enhanced") <+> bool (cnf_enhanced c) <$>                
+                    (if null (scr_bgks c) then text "<none>"
+                       else hsep (map (squotes.pretty) (scr_bgks c))) <$>
+                fill 20 (text "Compare rec args") <+> pretty (show.scr_recArgComp $ c) <$>
+                fill 20 (text "Debug") <+> bool (scr_debug c) <$>                
+                fill 20 (text "Simplified") <+> bool (scr_simplify c) <$>                              
+                fill 20 (text "Enhanced") <+> bool (scr_enhanced c) <$>                
hunk ./src/Data/GlobalConfig.hs 42
-                    (if cnf_debug c then integer (cnf_maxLoops c) 
+                    (if scr_debug c then integer (scr_maxLoops c) 
hunk ./src/Data/GlobalConfig.hs 44
+
+
hunk ./src/Data/HypoSpace.hs 219
-                        text "Rating -> HypoID:" <^> pretty (rateIdsMap hsp) <$> 
-                        text "Rule   -> HypoID:" <^> pretty (ruleIdsMap hsp) <$> 
-                        text "ID     -> Hypo: <omitted>" -- <$> pretty (hypoIdBimap hsp)
+                        text "Rating -> Hypo:" <^> indent 2 (vcat . (prntAssocs hsp) .  M.assocs . rateIdsMap $ hsp)
+--                        text "Rating -> HypoID:" <^> pretty (rateIdsMap hsp) <$> 
+--                        text "Rule   -> HypoID:" <^> pretty (ruleIdsMap hsp) <$> 
+--                        text "ID     -> Hypo:  " <$> pretty (hypoIdBimap hsp)
hunk ./src/Data/HypoSpace.hs 224
-   
+ 
+atSnd f (a,b) = (a, f b)
+prntAssocs hsp = map (asMap . (atSnd ((mapMaybe (flip getById hsp)).  IS.toList)))
hunk ./src/Data/Hypotheses.hs 63
-	pretty h@(HH o c cs) = align $ text "Hypo:" <+> indent 2 (
-						 vsep . (map pretty) . rules2decs . allBindings $ h
+	pretty h@(HH o c cs) = text "Hypo:" <+> 
+                         (align $ vcat $ map (pretty) (rules2decs . allBindings $ h))
hunk ./src/Data/Hypotheses.hs 68
-						 )
+--						 )
hunk ./src/Data/IgorMonad.hs 40
-    , config :: Config
+    , config :: SCR
hunk ./src/Data/IgorMonad.hs 78
-initIgor :: [(Name,Rules)] -> Config -> Igor
+initIgor :: [(Name,Rules)] -> SCR -> Igor
hunk ./src/Data/IgorMonad.hs 86
-isDebug = gets $ cnf_debug.config
+isDebug = gets $ scr_debug.config
hunk ./src/Data/IgorMonad.hs 89
-inEnhanced = gets $ cnf_enhanced.config
+inEnhanced = gets $ scr_enhanced.config
hunk ./src/Data/IgorMonad.hs 97
-maxLoops = gets $ cnf_maxLoops.config
+maxLoops = gets $ scr_maxLoops.config
hunk ./src/Data/IgorMonad.hs 100
-recArgComp = gets $ cnf_recArgComp.config
+recArgComp = gets $ scr_recArgComp.config
hunk ./src/Data/IgorMonad.hs 110
-targets = gets $ cnf_tgts.config
+targets = gets $ scr_tgts.config
hunk ./src/Data/IgorMonad.hs 113
-background = gets $ cnf_bgks.config
+background = gets $ scr_bgks.config
hunk ./src/Data/IgorMonad.hs 117
-    bgk <- gets $ cnf_bgks.config
+    bgk <- gets $ scr_bgks.config
hunk ./src/Data/IgorMonad.hs 119
-    modify (\i@(Igor _ _ _ c) -> i{config=c{cnf_bgks=bgk'}})
+    modify (\i@(Igor _ _ _ c) -> i{config=c{scr_bgks=bgk'}})
hunk ./src/Data/IgorMonad.hs 123
-    bgk <- gets $ cnf_bgks.config
+    bgk <- gets $ scr_bgks.config
hunk ./src/Data/IgorMonad.hs 125
-    modify (\i@(Igor _ _ _ c) -> i{config=c{cnf_bgks=bgk'}})
+    modify (\i@(Igor _ _ _ c) -> i{config=c{scr_bgks=bgk'}})
hunk ./src/Logging/Logger.hs 5
-    runELT,  runLM, unLM, -- noLog,
-    Log, Logger, Message, Priority(..), emptyLog,
+    runLM, -- unLM, -- noLog,
+    Log, Logger, Message, Priority(..), emptyLog, verb2Int, int2Verb,
hunk ./src/Logging/Logger.hs 8
-    logDE,logIN,logNO,logWA,logER,logCR,logAL,logEM,
-    llogDE,llogIN,llogNO,llogWA,llogER,llogCR,llogAL,llogEM,
-    llogEnterDE, llogEnterIN,
+    waypointS, waypointM, waypointL,
+    waypointS', waypointM', waypointL',
+    logDE,logIN,logNO,logWA,logER,
+    llogDE,llogIN,llogNO,llogWA,llogER,
+    -- llogEnterDE, llogEnterIN,
hunk ./src/Logging/Logger.hs 16
-
-    (<^>), ($$), patternNotDef,
hunk ./src/Logging/Logger.hs 40
--- if set, all logging is directly dumped to stdout via 'trace'
-_DEBUG = False
hunk ./src/Logging/Logger.hs 41
-data Priority = DEBUG       -- ^Debug messages
-              | INFO        -- ^Information
-              | NOTICE      -- ^Normal runtime conditions
+data Priority = ERROR       -- ^General Errors
hunk ./src/Logging/Logger.hs 43
-              | ERROR       -- ^General Errors
-              | CRITICAL    -- ^Severe situations
-              | ALERT       -- ^Take immediate action
-              | EMERGENCY   -- ^System is unusable
+              | NOTICE      -- ^Normal runtime conditions
+              | INFO        -- ^Information
+              | DEBUG       -- ^Debug messages
hunk ./src/Logging/Logger.hs 48
+verb2Int :: Priority -> Integer
+verb2Int DEBUG   = 4
+verb2Int INFO    = 3
+verb2Int NOTICE  = 2
+verb2Int WARNING = 1
+verb2Int ERROR   = 0
+    
+int2Verb :: Integer ->  Priority
+int2Verb 4 = DEBUG
+int2Verb 3 = INFO
+int2Verb 2 = NOTICE
+int2Verb 1 = WARNING
+int2Verb 0 = ERROR
+
hunk ./src/Logging/Logger.hs 67
-	pretty (LE p l m) = (text (show p)) <+> text l <+> ( text ":" $$ m)
+	pretty (LE p l m) = m -- (text (show p)) <+> text l <+> ( text ": " $$ m)
hunk ./src/Logging/Logger.hs 76
-type LogState = (Priority  -- ^Priority
-				,Logger    -- ^Global Logger
-				,Logger)   -- ^Current Logger
+data LogState = LS {verbosity :: Priority  -- ^Priority
+				   ,global    :: Logger    -- ^Global Logger
+				   ,current   :: Logger    -- ^Current Logger
+                   ,debugging  :: Bool}    -- ^Debug
hunk ./src/Logging/Logger.hs 81
+mkLogState v b = LS v "" "" b
hunk ./src/Logging/Logger.hs 103
-logDE,logIN,logNO,logWA,logER,logCR,logAL,logEM   ::  Message -> LM ()        
+logDE,logIN,logNO,logWA,logER ::  Message -> LM ()        
hunk ./src/Logging/Logger.hs 109
-logCR = logging CRITICAL
-logAL = logging ALERT
-logEM = logging EMERGENCY
hunk ./src/Logging/Logger.hs 110
-llogDE,llogIN,llogNO,llogWA,llogER,llogCR,llogAL,llogEM   :: 
-    ( MonadTrans t) =>  Message -> t LM ()        
+llogDE,llogIN,llogNO,llogWA,llogER ::  ( MonadTrans t) =>  Message -> t LM ()        
hunk ./src/Logging/Logger.hs 116
-llogCR = \m -> lift (logCR m)
-llogAL = \m -> lift (logAL m)
-llogEM = \m -> lift (logEM m) 
hunk ./src/Logging/Logger.hs 117
+waypointS' s = logNO $ linebreak <> text "- -" <$> 
+               text "- -" <+> s <$> 
+               text "- -" <> linebreak
+waypointM' s = logNO $ linebreak <> 
+               text "- - - - - - - - - - - - - - - - - - - - - - - -" <$> 
+               text "- -" <+> s <+> (fill 39 (text "- -")) <$>
+               text "- - - - - - - - - - - - - - - - - - - - - - - -" <>
+               linebreak
+waypointL' s = logNO $ linebreak <> 
+               text "***********************************************" <$> 
+               text "***" <+> s <+> (fill 39 (text "***")) <$>
+               text "***********************************************"  <>
+               linebreak
+              
hunk ./src/Logging/Logger.hs 135
+waypointS, waypointM, waypointL :: (MonadTrans t) => Doc -> t LM ()
+waypointS = lift . waypointS'
+waypointM = lift . waypointM'
+waypointL = lift . waypointL'
+
+
hunk ./src/Logging/Logger.hs 152
-getPriority = gets (\(p,_,_) -> p)
+getPriority = gets verbosity
hunk ./src/Logging/Logger.hs 155
-setPriority p = modify (\(_,gll,cl) -> (p,gll,cl))
+setPriority p = modify (\l -> l{verbosity = p})
hunk ./src/Logging/Logger.hs 158
-getGlobalLogLevel = gets (\(_,gll,_) -> gll)
+getGlobalLogLevel = gets global
hunk ./src/Logging/Logger.hs 161
-setGlobalLogLevel gll = modify (\(p,_,cl) -> (p,gll,cl))
+setGlobalLogLevel gll = modify (\l -> l{global = gll})
hunk ./src/Logging/Logger.hs 164
-getCurrentLogger = gets (\(_,_,cl) -> cl)
+getCurrentLogger = gets current
hunk ./src/Logging/Logger.hs 167
-setCurrentLogger cl = modify (\(p,gll,_) -> (p,gll,cl))
+setCurrentLogger cl = modify (\l -> l{current = cl})
+
+isDebugging :: (MonadState LogState m, MonadWriter Log m) =>m Bool
+isDebugging = gets debugging
+
+setDebugging ::  (MonadState LogState m, MonadWriter Log m) =>Bool -> m ()
+setDebugging d = modify (\l -> l{debugging = d})
+
hunk ./src/Logging/Logger.hs 177
-logging p msg   = traceIfDebug msg $ 
-                  getCurrentLogger >>= \l ->
+logging p msg   = getCurrentLogger >>= \l ->
hunk ./src/Logging/Logger.hs 179
-    where
-    traceIfDebug msg  = if _DEBUG then trace (show msg) else id          
+--                        if _DEBUG then trace (show msg) else id          
hunk ./src/Logging/Logger.hs 187
-       when ((isPrefixOf gll l) && (lvl <= p)) $ tell (Log [] (Just (LE p l msg)))
-
+       if ((isPrefixOf gll l) && (p <= lvl))
+        then tell (Log [] (Just (LE p l msg))) >> 
+             isDebugging >>= traceIfDebug msg                  
+        else return() 
+    where
+    traceIfDebug msg b = when b (lift3 . putStrLn . show $ msg)
hunk ./src/Logging/Logger.hs 195
+lift3 = lift . lift . lift
hunk ./src/Logging/Logger.hs 198
-runELT :: (Monad m) => (ELT m a) -> m (Either String a, Log) 
-runELT =  \m -> (runWriterT (runErrorT (evalStateT m (DEBUG,"",""))))             
+runELT :: (Monad m) => Priority -> Bool -> (ELT m a) -> m (Either String a, Log) 
+runELT v b m =  runWriterT (runErrorT (evalStateT m (mkLogState v b)))
+
+type LM = ELT IO
+runLM :: (Monad m) =>
+          Priority -> Bool -> ELT m a -> m (Either String a, Log)
+runLM = runELT
hunk ./src/Logging/Logger.hs 206
-type LM = ELT Identity
-runLM = runIdentity.runELT
hunk ./src/Logging/Logger.hs 207
--- | Strips away the monadic ErrorLogging context. This is unsafe, because if
---   an error occurred in the Monad it is propagated.       
--- TODO: Should rather be something with `catchError`                
-unLM :: LM a -> a 
-unLM m =  
-    case fst (runLM m) of 
-        Left s  -> error s
-        Right a -> a
-        
-noLog :: (Monad m)=> LM a -> m a
-noLog m =  
-    case fst (runLM m) of 
-        Left s  -> fail s
-        Right a -> return a        
+-- DEAD CODE     
+---- | Strips away the monadic ErrorLogging context. This is unsafe, because if
+----   an error occurred in the Monad it is propagated.       
+---- TODO: Should rather be something with `catchError`                
+--unLM :: LM a -> IO a 
+--unLM m = do 
+--    r <- runLM ERROR False m
+--    case fst r of 
+--        Left s  -> fail s
+--        Right a -> return a
+--   
+-- DEAD CODE     
+--noLog :: (Monad m)=> LM a -> m a
+--noLog m =  
+--    case fst (runLM m) of 
+--        Left s  -> fail s
+--        Right a -> return a        
+
hunk ./src/Logging/Logger.hs 242
-
-                 
-
---------------------------------------------------------------------------------
--- Pretty Helpers
---------------------------------------------------------------------------------
-
-x $$ y = align (x <$> y)
-x <^> y = x <$> ( indent 2 y)
-
-patternNotDef :: [Doc] -> Doc
-patternNotDef as = text "Pattern not defined !!!" <$>
-                   vsep [ text "arg" <> int (i+1) <+> (as !! i) | i <- [0 .. (length as)-1]]
-
hunk ./src/Logging/Logger.hs 243
+     
hunk ./src/Logging/PrettyPrinter.hs 4
-    --printResult, 
+    showp, set, asMap, asRepl, 
hunk ./src/Logging/PrettyPrinter.hs 56
-    lparen <> (pretty a) <+> ((text "|->" ) <+> softbreak <> (pretty b) <> rparen)
+    lparen <> (pretty a) <+> ((text "|->" ) <> softbreak <> indent 2 (pretty b) <> rparen)
hunk ./src/Logging/PrettyPrinter.hs 59
-    lparen <> (pretty a) <+> ((text "<~" ) <+> softbreak <> (pretty b) <> rparen)
+    lparen <> (pretty a) <+> ((text "<~" ) <+> softbreak <> align (pretty b) <> rparen)
hunk ./src/Logging/PrettyPrinter.hs 78
-    pretty = text.unqual.pprint
+    pretty = vcat.(map text).fixbreaks.lines.unqual.pprint
+    
hunk ./src/Logging/PrettyPrinter.hs 81
--- Quick and dirty HACK!!
+-- Quick and dirty HACKs!!
hunk ./src/Logging/PrettyPrinter.hs 94
-    
+                    
+-- TH.pprint sometomes breaks lists in arguments, so I have to fix it
+fixbreaks [x] = [x]
+fixbreaks (x1:x2:xs)
+   | isPrefixOf "  " x2 = fixbreaks ( (x1++(dropWhile (==' ') x2)):xs)
+   | otherwise          = x1 : (fixbreaks (x2:xs))
+       
hunk ./src/RuleDevelopment/Matching.hs 35
-    llogEnterIN
-    llogIN ( text "Compute matchings for:" <^> (pretty $ cr))
-    llogIN ( text "Call Dependencies:" <^> pretty cd )
---    llogIN ( text "scope:" <^> pretty scope )
---    llogIN ( text "bgkcalls:" <^> pretty bgkcalls )
---    llogIN ( text "tgtcalls:" <^> pretty tgtcalls )
-    llogIN ( text "Allowed calls:" <^> pretty allcalls)
+    waypointS $ text "Computing matchings"
+    llogIN ( text "Try for:" <^> (pretty $ cr))
+    llogDE ( text "Call Dependencies:" <^> pretty cd )
+    llogDE ( text "scope:" <^> pretty scope )
+    llogDE ( text "bgkcalls:" <^> pretty bgkcalls )
+    llogDE ( text "tgtcalls:" <^> pretty tgtcalls )
+    llogDE ( text "Allowed calls:" <^> pretty allcalls)
hunk ./src/RuleDevelopment/Matching.hs 48
-    llogIN (indent 2 $ text "(-) Not allowed to call" <+> (squotes.text.show $ n)) >>
+    llogDE (indent 2 $ text "(-) Not allowed to call" <+> (squotes.text.show $ n)) >>
hunk ./src/RuleDevelopment/Matching.hs 72
-             text "Need to compute full matchings (C vs T)" <$>
-             (align $ text "Caller:" <+> pretty cllrs ) <$>
+             text "Need to compute full matchings (C vs T)")
+     llogDE ((align $ text "Caller:" <+> pretty cllrs ) <$>
hunk ./src/RuleDevelopment/Matching.hs 84
-     proceed m = do llogIN (text "Matchings" <$> (pretty m))
+     proceed m = do llogDE (text "Matchings" <$> (pretty m))
hunk ./src/RuleDevelopment/Matching.hs 157
-    llogIN (text "Call added:" <^> (pretty cr'))
+    llogDE (text "Call added:" <^> (pretty cr'))
hunk ./src/RuleDevelopment/Matching.hs 165
-    llogIN (text "Call added:" <^>  (pretty cr'))
+    llogDE (text "Call added:" <^>  (pretty cr'))
hunk ./src/RuleDevelopment/Matching.hs 198
-       llogIN (indent 2 $
+       llogDE (indent 2 $
hunk ./src/RuleDevelopment/Matching.hs 207
-               llogIN (indent 2 $
+               llogDE (indent 2 $
hunk ./src/RuleDevelopment/Partition.hs 29
-    llogEnterIN 
+    waypointS $ text "Partitioning"
hunk ./src/RuleDevelopment/Partition.hs 35
-    llogIN ( text "Partitioning" <^>
-    		 text "Rule:" <+> pretty rf <^>
-             text "At  :" <+> pretty partpos <^>
+    llogIN ( text "Rule:" <+> pretty rf )
+    llogDE ( text "At  :" <+> pretty partpos <^>
hunk ./src/RuleDevelopment/Subfunction.hs 15
-callSubfunction rf =
-    llogEnterIN >>             
+callSubfunction rf = do
+    waypointS $ text "Introducing Subfunction"
hunk ./src/RuleDevelopment/Subfunction.hs 19
-      else llogIN (text "Introducing Subfunction" <^>
-                   text "No Ctor at Root, return []") >> 
+      else llogIN (text "No Ctor at Root, return []") >> 
hunk ./src/RuleDevelopment/Subfunction.hs 33
-    llogIN ( text "Introducing Subfunction" <^>
-             text "Rule_old:" <+> pretty cr <^>
-             text "Rule_new:" <+> pretty rfnew <^>
-             text "abdcdIOs:" <+> pretty (zip subfnnms ios) <^>
+    llogIN ( text "Rule_old:" <+> pretty cr <^>
+             text "Rule_new:" <+> pretty rfnew)
+    llogDE ( text "abdcdIOs:" <+> pretty (zip subfnnms ios) <^>
hunk ./src/RuleDevelopment/UniProp.hs 19
-    llogEnterIN 
-    llogIN (text "Check if Universal Property of 'fold' applies to: " <^>
+    waypointS $ text "Universal Property of 'fold'"
+    llogNO (text "Check if 'fold' applies to: " <^>
hunk ./src/RuleDevelopment/UniProp.hs 25
-noFoldCall = llogIN (text "UniProp not applicable!") >> return []
+noFoldCall = llogNO (text "UniProp not applicable!") >> return []
hunk ./src/RuleDevelopment/UniProp.hs 29
-    llogIN (text "UniProp applicable!")
+    llogNO (text "UniProp applicable!")
hunk ./src/RuleDevelopment/UniProp.hs 34
-    llogIN (text "With function" <^> pretty f <$>
+    llogDE (text "With function" <^> pretty f <$>
hunk ./src/Syntax/Antiunifier.hs 20
+import Syntax.IFTemplateHaskell
hunk ./src/SynthesisEngine.hs 34
-startSynthesis :: Config -> [(Name,Rules)] -> [(Name,Rules)]
-               -> (Either String ([(Name,Int)],[[Dec]]),Log)
-startSynthesis conf tgt bgk = runLM  (synthesise conf tgt bgk) 
+startSynthesis :: SCR -> [(Name,Rules)] -> [(Name,Rules)]
+               -> IO (Either String ([(Name,Int)],[[Dec]]),Log)
+startSynthesis conf tgt bgk = runLM (scr_verbosity conf) (scr_debug conf) (synthesise conf tgt bgk) 
hunk ./src/SynthesisEngine.hs 38
-synthesise :: Config -> [(Name,Rules)] -> [(Name,Rules)] -> LM ([(Name,Int)],[[Dec]])
+synthesise :: SCR -> [(Name,Rules)] -> [(Name,Rules)] -> LM ([(Name,Int)],[[Dec]])
hunk ./src/SynthesisEngine.hs 43
-    logIN ( pretty conf <$> 
-            linebreak <>
+    waypointL' $ text "Initialising Igor"
+    logIN ( pretty conf )
+    logDE ( linebreak <>
hunk ./src/SynthesisEngine.hs 49
-    (r,l) <- (runIM (synthesiseTargets (cnf_tgts conf) >>= \r -> 
+    (r,l) <- (runIM (synthesiseTargets (scr_tgts conf) >>= \r -> 
hunk ./src/SynthesisEngine.hs 52
-    return $ (,) l $ hypos2decs (cnf_simplify conf)(cnf_tgts conf) r
+    return $ (,) l $ hypos2decs (scr_simplify conf)(scr_tgts conf) r
hunk ./src/SynthesisEngine.hs 60
-        llogEnterIN
-        llogIN $ text "STARTING SYNTHESIS for TARGET" <+> squotes (pretty n)
+        waypointL $ text "STARTING SYNTHESIS for TARGET" <+> squotes (pretty n)
hunk ./src/SynthesisEngine.hs 68
-    llogEnterIN
hunk ./src/SynthesisEngine.hs 71
-    loopCount >>= \lc -> llogIN $ text "Entering Rule-Advancement-Loop for the" <+> 
+    loopCount >>= \lc -> waypointM $ text "Entering Rule-Advancement-Loop for the" <+> 
hunk ./src/SynthesisEngine.hs 73
-    get       >>= \ig -> llogIN $ indent 2 $ pretty ig
+    get       >>= \ig -> llogDE $ indent 2 $ pretty ig
hunk ./src/SynthesisEngine.hs 81
-    --llogIN $ text "Candidate Hypos:" <^> pretty candidatehypos
-    llogIN $ text "Candidate Rules:" <^> pretty candidaterules <$>  
-             text "Candidate Hypos:" <^> pretty candidatehypos <$>  
-             text "Stopping Criteria?" <^>
+    llogIN $ text "Candidate Hypos:" <^> pretty candidatehypos
+    llogNO $ text "Candidate Rules:" <^> pretty candidaterules 
+    llogDE $ text "Stopping Criteria?" <^>
hunk ./src/SynthesisEngine.hs 96
-       llogIN $ text "STOP_WITH:" <^> pretty hs
+       llogDE $ text "STOP_WITH:" <^> pretty hs
hunk ./src/SynthesisEngine.hs 98
-       llogIN $ text "Stopped after entering loop the" <+> int lc <> text ". time."
+       llogNO $ text "Stopped after entering loop the" <+> int lc <> text ". time."
hunk ./src/SynthesisEngine.hs 119
-----    where    
+----    where   
hunk ./src/SynthesisEngine.hs 129
-    llogIN $ linebreak <^> text "Advancing" <+> pretty rf 
-    llogIN $ text "Resulted in" <+> int (length advancements) <+> 
+    llogNO $ linebreak <> text "Advancing" <^> pretty rf 
+    llogNO $ text "Resulted in" <+> int (length advancements) <+> 
hunk ./src/SynthesisEngine.hs 134
-
-
-
-
hunk ./src/UI/UIStarter.hs 59
+    , verbosity :: Priority
hunk ./src/UI/UIStarter.hs 86
+    , verbosity = NOTICE
hunk ./src/UI/UIStarter.hs 262
-            (t,res) <- time (return $ startSynthesis newConfig ts bs)
+            (res,t) <- time (startSynthesis newConfig ts bs)
hunk ./src/UI/UIStarter.hs 267
-    newConfig = Conf (debug s) (simplify s)(enhanced s) (maxLoops s) (cmpRecArg s) tgts bgks
+    newConfig = SCR (debug s) (simplify s)(enhanced s)(verbosity s)(maxLoops s) (cmpRecArg s) tgts bgks
hunk ./src/UI/UIStarter.hs 290
-printResult :: EnvState -> Config -> String
+printResult :: EnvState -> SCR -> Doc
hunk ./src/UI/UIStarter.hs 427
-            maxLoops,  \ v s -> s { maxLoops = v})
+            maxLoops,  \ v s -> s { maxLoops = v}),
+      ("verbosity",         "Set the verbosity level from 0(all) to 4 (errors only)",
+            verb2Int.verbosity,  \ v s -> s { verbosity = int2Verb v})