2017-03-08 21:33:55 +03:00
|
|
|
-- Copyright (c) 2016-present, Facebook, Inc.
|
|
|
|
-- All rights reserved.
|
|
|
|
--
|
|
|
|
-- This source code is licensed under the BSD-style license found in the
|
|
|
|
-- LICENSE file in the root directory of this source tree. An additional grant
|
|
|
|
-- of patent rights can be found in the PATENTS file in the same directory.
|
|
|
|
|
|
|
|
-----------------------------------------------------------------
|
|
|
|
-- Auto-generated by regenClassifiers
|
|
|
|
--
|
|
|
|
-- DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
|
|
|
-- @generated
|
|
|
|
-----------------------------------------------------------------
|
|
|
|
{-# LANGUAGE OverloadedStrings #-}
|
|
|
|
module Duckling.Ranking.Classifiers.EN (classifiers) where
|
|
|
|
import Prelude
|
|
|
|
import Duckling.Ranking.Types
|
|
|
|
import qualified Data.HashMap.Strict as HashMap
|
|
|
|
import Data.String
|
|
|
|
|
|
|
|
classifiers :: Classifiers
|
|
|
|
classifiers
|
|
|
|
= HashMap.fromList
|
|
|
|
[("<integer> to|till|before <hour-of-day>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -1.791759469228055, unseen = -1.791759469228055,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("integer (numeric)noon|midnight|EOD|end of day",
|
|
|
|
-0.916290731874155),
|
|
|
|
("hour", -0.916290731874155)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -0.1823215567939546, unseen = -2.639057329615259,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("hour", -0.7731898882334817),
|
|
|
|
("integer (numeric)time-of-day (latent)", -0.7731898882334817)],
|
|
|
|
n = 5}}),
|
|
|
|
("<time> timezone",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.4849066497880004,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("at <time-of-day>", -1.7047480922384253),
|
|
|
|
("<time-of-day> am|pm", -1.7047480922384253),
|
|
|
|
("hh:mm", -1.7047480922384253), ("hour", -1.2992829841302609),
|
|
|
|
("minute", -1.7047480922384253)],
|
|
|
|
n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.791759469228055,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("Thursday",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.995732273553991,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 18},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("integer (numeric)",
|
|
|
|
Classifier{okData =
|
2017-07-20 21:04:13 +03:00
|
|
|
ClassData{prior = -0.8649974374866046,
|
2017-06-23 16:50:04 +03:00
|
|
|
unseen = -5.0369526024136295,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 152},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-07-20 21:04:13 +03:00
|
|
|
ClassData{prior = -0.5465437063680699, unseen = -5.351858133476067,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 209}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<duration> hence|ago",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -3.784189633918261,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("week", -1.563975538357343), ("day", -1.8152899666382492),
|
|
|
|
("year", -2.662587827025453),
|
|
|
|
("<integer> <unit-of-duration>", -1.0531499145913523),
|
|
|
|
("a <unit-of-duration>", -2.662587827025453),
|
|
|
|
("month", -2.662587827025453),
|
|
|
|
("fortnight", -2.662587827025453)],
|
|
|
|
n = 18},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -2.0794415416798357,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("noon|midnight|EOD|end of day",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.9459101490553135,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 5},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("quarter to|till|before <hour-of-day>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("noon|midnight|EOD|end of day", -0.6931471805599453),
|
|
|
|
("hour", -0.6931471805599453)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("Father's Day",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<cycle> after|before <time>",
|
|
|
|
Classifier{okData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.5596157879354228, unseen = -2.772588722239781,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("day (grain)tomorrow", -1.6094379124341003),
|
|
|
|
("dayday", -1.0986122886681098),
|
|
|
|
("day (grain)yesterday", -1.6094379124341003)],
|
2017-03-08 21:33:55 +03:00
|
|
|
n = 4},
|
|
|
|
koData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.8472978603872037, unseen = -2.639057329615259,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("dayhour", -1.466337068793427),
|
|
|
|
("year (grain)Christmas", -1.8718021769015913),
|
|
|
|
("day (grain)intersect", -1.466337068793427),
|
|
|
|
("yearday", -1.8718021769015913)],
|
|
|
|
n = 3}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Martin Luther King's Day",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.1972245773362196,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 7},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("integer (20..90)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
2017-07-20 21:04:13 +03:00
|
|
|
("mm/yyyy",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -0.6931471805599453,
|
|
|
|
unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -0.6931471805599453,
|
|
|
|
unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("integer after|past <hour-of-day>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.3025850929940455,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("hour", -0.8109302162163288),
|
|
|
|
("integer (numeric)time-of-day (latent)", -1.0986122886681098),
|
|
|
|
("integer (20..90)time-of-day (latent)", -1.5040773967762742)],
|
|
|
|
n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.3862943611198906,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<day-of-month> (ordinal or number) <named-month>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -0.916290731874155, unseen = -2.3978952727983707,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("ordinal (digits)February", -1.6094379124341003),
|
|
|
|
("integer (numeric)April", -1.6094379124341003),
|
|
|
|
("month", -1.2039728043259361)],
|
|
|
|
n = 2},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -0.5108256237659907,
|
|
|
|
unseen = -2.5649493574615367,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("integer (numeric)August", -1.791759469228055),
|
|
|
|
("ordinal (digits)April", -1.791759469228055),
|
|
|
|
("month", -1.0986122886681098),
|
|
|
|
("integer (numeric)July", -1.791759469228055)],
|
|
|
|
n = 3}}),
|
|
|
|
("<time> <part-of-day>",
|
|
|
|
Classifier{okData =
|
2017-06-09 19:21:03 +03:00
|
|
|
ClassData{prior = -9.844007281325252e-2,
|
|
|
|
unseen = -4.430816798843313,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("<day-of-month> (ordinal)in|during the <part-of-day>",
|
2017-06-09 19:21:03 +03:00
|
|
|
-3.7256934272366524),
|
|
|
|
("dayhour", -1.5284688499004333),
|
|
|
|
("Mondayearly morning", -3.3202283191284883),
|
|
|
|
("time-of-day (latent)tonight", -3.3202283191284883),
|
|
|
|
("hourhour", -2.339399066116762),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<time-of-day> o'clockin|during the <part-of-day>",
|
2017-06-09 19:21:03 +03:00
|
|
|
-3.7256934272366524),
|
|
|
|
("todaypart of days", -3.7256934272366524),
|
|
|
|
("minutehour", -2.627081138568543),
|
2017-03-08 21:33:55 +03:00
|
|
|
("at <time-of-day>in|during the <part-of-day>",
|
2017-06-09 19:21:03 +03:00
|
|
|
-3.3202283191284883),
|
|
|
|
("time-of-day (latent)this <part-of-day>", -3.7256934272366524),
|
|
|
|
("Mondayin|during the <part-of-day>", -3.7256934272366524),
|
|
|
|
("intersectpart of days", -3.7256934272366524),
|
|
|
|
("intersectin|during the <part-of-day>", -3.7256934272366524),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<day-of-month> (ordinal or number) of <named-month>in|during the <part-of-day>",
|
2017-06-09 19:21:03 +03:00
|
|
|
-3.7256934272366524),
|
2017-03-08 21:33:55 +03:00
|
|
|
("the <day-of-month> (ordinal)in|during the <part-of-day>",
|
2017-06-09 19:21:03 +03:00
|
|
|
-3.7256934272366524),
|
|
|
|
("tomorrowpart of days", -2.339399066116762),
|
|
|
|
("hh:mmin|during the <part-of-day>", -3.0325462466767075),
|
2017-03-08 21:33:55 +03:00
|
|
|
("time-of-day (latent)in|during the <part-of-day>",
|
2017-06-09 19:21:03 +03:00
|
|
|
-3.7256934272366524),
|
2017-03-08 21:33:55 +03:00
|
|
|
("hhmm (latent)in|during the <part-of-day>",
|
2017-06-09 19:21:03 +03:00
|
|
|
-3.7256934272366524),
|
|
|
|
("yesterdaypart of days", -3.7256934272366524),
|
|
|
|
("Mondaypart of days", -3.7256934272366524)],
|
|
|
|
n = 29},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-06-09 19:21:03 +03:00
|
|
|
ClassData{prior = -2.367123614131617, unseen = -3.4657359027997265,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("yearhour", -2.740840023925201),
|
|
|
|
("monthhour", -2.740840023925201),
|
|
|
|
("hourhour", -2.740840023925201),
|
2017-03-08 21:33:55 +03:00
|
|
|
("past year (latent)in|during the <part-of-day>",
|
2017-03-14 14:50:10 +03:00
|
|
|
-2.740840023925201),
|
|
|
|
("Februaryin|during the <part-of-day>", -2.740840023925201),
|
2017-03-08 21:33:55 +03:00
|
|
|
("time-of-day (latent)in|during the <part-of-day>",
|
2017-03-14 14:50:10 +03:00
|
|
|
-2.740840023925201)],
|
2017-03-08 21:33:55 +03:00
|
|
|
n = 3}}),
|
|
|
|
("today",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.9459101490553135,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 5},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("mm/dd",
|
|
|
|
Classifier{okData =
|
2017-06-22 13:39:45 +03:00
|
|
|
ClassData{prior = -1.3862943611198906,
|
|
|
|
unseen = -2.0794415416798357,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 6},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-06-22 13:39:45 +03:00
|
|
|
ClassData{prior = -0.2876820724517809, unseen = -2.995732273553991,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 18}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("at <time-of-day>",
|
|
|
|
Classifier{okData =
|
2017-04-06 20:50:34 +03:00
|
|
|
ClassData{prior = -0.10919929196499197,
|
|
|
|
unseen = -4.7535901911063645,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-04-06 20:50:34 +03:00
|
|
|
[("noon|midnight|EOD|end of day", -3.6463198396951406),
|
|
|
|
("integer after|past <hour-of-day>", -3.6463198396951406),
|
|
|
|
("half after|past <hour-of-day>", -4.051784947803305),
|
|
|
|
("time-of-day (latent)", -1.8004931491968097),
|
|
|
|
("hhmm (latent)", -3.3586377672433594),
|
|
|
|
("<time-of-day> am|pm", -1.749199854809259),
|
|
|
|
("hh:mm", -3.1354942159291497),
|
|
|
|
("about|exactly <time-of-day>", -3.6463198396951406),
|
|
|
|
("hour", -1.16141318990714),
|
|
|
|
("<time-of-day> sharp|exactly", -4.051784947803305),
|
|
|
|
("minute", -1.8545603704670852)],
|
|
|
|
n = 52},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-04-06 20:50:34 +03:00
|
|
|
ClassData{prior = -2.268683541318364, unseen = -3.1780538303479458,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-04-06 20:50:34 +03:00
|
|
|
[("time-of-day (latent)", -1.1895840668738362),
|
|
|
|
("hour", -1.1895840668738362)],
|
|
|
|
n = 6}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("absorption of , after named day",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -3.332204510175204,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("on <date>", -2.1972245773362196),
|
|
|
|
("Wednesday", -2.6026896854443837),
|
|
|
|
("Saturday", -2.6026896854443837),
|
|
|
|
("Monday", -2.1972245773362196),
|
|
|
|
("Friday", -1.9095425048844386), ("day", -0.8979415932059586),
|
|
|
|
("Sunday", -2.6026896854443837)],
|
|
|
|
n = 10},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -2.0794415416798357,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("September",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.791759469228055,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 4},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("tonight",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.791759469228055,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 4},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("the ides of <named-month>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("March", -0.6931471805599453), ("month", -0.6931471805599453)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("on <date>",
|
|
|
|
Classifier{okData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.1670540846631662, unseen = -4.007333185232471,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("Thursday", -1.791759469228055), ("mm/dd", -3.295836866004329),
|
|
|
|
("absorption of , after named day", -2.890371757896165),
|
|
|
|
("intersect", -2.890371757896165),
|
|
|
|
("Saturday", -2.6026896854443837),
|
|
|
|
("Friday", -3.295836866004329), ("day", -0.8979415932059586),
|
|
|
|
("the <day-of-month> (ordinal)", -2.890371757896165),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"",
|
2017-03-14 14:50:10 +03:00
|
|
|
-2.6026896854443837),
|
|
|
|
("hour", -3.295836866004329)],
|
|
|
|
n = 22},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -1.8718021769015913,
|
|
|
|
unseen = -2.9444389791664407,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("intersect", -1.791759469228055), ("day", -1.2809338454620642),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"",
|
2017-03-14 14:50:10 +03:00
|
|
|
-1.791759469228055)],
|
|
|
|
n = 4}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("integer (0..19)",
|
|
|
|
Classifier{okData =
|
2017-06-27 17:13:55 +03:00
|
|
|
ClassData{prior = -2.469261259037152e-2,
|
|
|
|
unseen = -3.7376696182833684,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 40},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-06-27 17:13:55 +03:00
|
|
|
ClassData{prior = -3.713572066704308, unseen = -1.0986122886681098,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1}}),
|
|
|
|
("between <time-of-day> and <time-of-day> (interval)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -0.6931471805599453,
|
|
|
|
unseen = -2.3978952727983707,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("minuteminute", -0.916290731874155),
|
|
|
|
("hh:mmhh:mm", -0.916290731874155)],
|
|
|
|
n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -0.6931471805599453,
|
|
|
|
unseen = -2.3978952727983707,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("hh:mmtime-of-day (latent)", -0.916290731874155),
|
|
|
|
("minutehour", -0.916290731874155)],
|
|
|
|
n = 3}}),
|
|
|
|
("Halloween",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
2017-06-27 22:21:14 +03:00
|
|
|
("from <month> dd-dd (interval)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("July", -0.6931471805599453), ("month", -0.6931471805599453)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("October",
|
|
|
|
Classifier{okData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -2.833213344056216,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 15},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("month (grain)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.3978952727983707,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 9},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<integer> more <unit-of-duration>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("integer (numeric)minute (grain)", -0.6931471805599453),
|
|
|
|
("minute", -0.6931471805599453)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<time-of-day> o'clock",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.1972245773362196,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("time-of-day (latent)", -0.6931471805599453),
|
|
|
|
("hour", -0.6931471805599453)],
|
|
|
|
n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("in|within|after <duration>",
|
|
|
|
Classifier{okData =
|
2017-06-27 17:13:55 +03:00
|
|
|
ClassData{prior = -4.652001563489282e-2,
|
|
|
|
unseen = -4.61512051684126,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-27 17:13:55 +03:00
|
|
|
[("week", -3.2188758248682006),
|
|
|
|
("<integer> more <unit-of-duration>", -3.912023005428146),
|
|
|
|
("three-quarters of an hour", -2.995732273553991),
|
|
|
|
("<integer> + '\"", -3.2188758248682006),
|
|
|
|
("number.number hours", -3.912023005428146),
|
|
|
|
("second", -3.506557897319982), ("day", -3.2188758248682006),
|
|
|
|
("half an hour", -2.995732273553991),
|
|
|
|
("<integer> <unit-of-duration>", -1.6094379124341003),
|
|
|
|
("a <unit-of-duration>", -2.995732273553991),
|
|
|
|
("quarter of an hour", -2.995732273553991),
|
|
|
|
("hour", -2.5257286443082556),
|
|
|
|
("about|exactly <duration>", -3.912023005428146),
|
|
|
|
("<integer> and an half hour", -3.912023005428146),
|
|
|
|
("minute", -1.2729656758128873)],
|
|
|
|
n = 42},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -3.0910424533583156, unseen = -3.044522437723423,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("quarter", -1.8971199848858813),
|
|
|
|
("<integer> <unit-of-duration>", -2.3025850929940455),
|
|
|
|
("a <unit-of-duration>", -2.3025850929940455)],
|
|
|
|
n = 2}}),
|
|
|
|
("three-quarters of an hour",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.791759469228055,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 4},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("Wednesday",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.3025850929940455,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 8},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("half after|past <hour-of-day>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.9459101490553135,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("time-of-day (latent)", -0.6931471805599453),
|
|
|
|
("hour", -0.6931471805599453)],
|
|
|
|
n = 2},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<integer> + '\"",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods = HashMap.fromList [("integer (numeric)", 0.0)],
|
|
|
|
n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("half <integer> (UK style hour-of-day)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("time-of-day (latent)", -0.6931471805599453),
|
|
|
|
("hour", -0.6931471805599453)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("July",
|
|
|
|
Classifier{okData =
|
2017-06-27 22:21:14 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -2.70805020110221,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 13},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("hour (grain)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -0.8209805520698302,
|
|
|
|
unseen = -2.5649493574615367,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 11},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -0.579818495252942, unseen = -2.772588722239781,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 14}}),
|
|
|
|
("<ordinal> quarter",
|
|
|
|
Classifier{okData =
|
2017-03-13 21:38:34 +03:00
|
|
|
ClassData{prior = -0.4700036292457356, unseen = -2.639057329615259,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-13 21:38:34 +03:00
|
|
|
[("ordinal (digits)quarter (grain)", -1.1786549963416462),
|
2017-03-08 21:33:55 +03:00
|
|
|
("ordinals (first..twentieth,thirtieth,...)quarter (grain)",
|
2017-03-13 21:38:34 +03:00
|
|
|
-1.466337068793427),
|
|
|
|
("quarter", -0.7731898882334817)],
|
|
|
|
n = 5},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-03-13 21:38:34 +03:00
|
|
|
ClassData{prior = -0.9808292530117262,
|
|
|
|
unseen = -2.3025850929940455,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("ordinal (digits)quarter (grain)", -0.8109302162163288),
|
|
|
|
("quarter", -0.8109302162163288)],
|
|
|
|
n = 3}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("one twenty two",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0},
|
|
|
|
koData =
|
2017-06-22 13:39:45 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList [("integer (numeric)integer (numeric)", 0.0)],
|
2017-06-22 13:39:45 +03:00
|
|
|
n = 3}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect",
|
|
|
|
Classifier{okData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -0.4563567154045537, unseen = -6.124683390894205,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("<datetime> - <datetime> (interval)on <date>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.513054897080286),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<time-of-day> - <time-of-day> (interval)on <date>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.513054897080286),
|
|
|
|
("hourday", -3.724597536716016),
|
|
|
|
("dayhour", -3.1780538303479458),
|
|
|
|
("daymonth", -5.429345628954441),
|
|
|
|
("monthday", -5.0238805208462765),
|
|
|
|
("monthyear", -3.8199077165203406),
|
|
|
|
("Tuesdaythe <day-of-month> (ordinal)", -5.429345628954441),
|
|
|
|
("Christmasyear", -5.429345628954441),
|
|
|
|
("houryear", -5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("this|next <day-of-week>hh(:mm) - <time-of-day> am|pm",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.429345628954441),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("<time-of-day> am|pmintersect by \",\", \"of\", \"from\", \"'s\"",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.736198448394496),
|
|
|
|
("<time-of-day> am|pmintersect", -4.176582660459073),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"year",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.429345628954441),
|
|
|
|
("Marchyear", -5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<named-month>|<named-day> <day-of-month> (ordinal)year",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.0238805208462765),
|
|
|
|
("intersect<time-of-day> am|pm", -5.429345628954441),
|
|
|
|
("Thursdayhh(:mm) - <time-of-day> am|pm", -5.429345628954441),
|
|
|
|
("monthhour", -5.0238805208462765),
|
|
|
|
("last <day-of-week> of <time>year", -5.429345628954441),
|
|
|
|
("todayat <time-of-day>", -5.429345628954441),
|
|
|
|
("Thursday<time> timezone", -5.0238805208462765),
|
|
|
|
("this <time>hh(:mm) - <time-of-day> am|pm",
|
|
|
|
-5.429345628954441),
|
|
|
|
("dayday", -3.414442608412176),
|
|
|
|
("Thanksgiving Dayyear", -5.0238805208462765),
|
|
|
|
("<time> <part-of-day>at <time-of-day>", -5.429345628954441),
|
|
|
|
("Tuesdayin <named-month>", -5.429345628954441),
|
|
|
|
("mm/ddat <time-of-day>", -5.429345628954441),
|
|
|
|
("tonightat <time-of-day>", -5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<time-of-day> am|pmabsorption of , after named day",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.736198448394496),
|
|
|
|
("today<time-of-day> am|pm", -5.429345628954441),
|
|
|
|
("Februarythe <day-of-month> (ordinal)", -5.0238805208462765),
|
|
|
|
("at <time-of-day><time> <part-of-day>", -5.429345628954441),
|
|
|
|
("mm/dd<time-of-day> am|pm", -5.429345628954441),
|
|
|
|
("hourhour", -4.176582660459073),
|
|
|
|
("<time-of-day> am|pmon <date>", -3.414442608412176),
|
|
|
|
("Wednesdaythis|last|next <cycle>", -5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect<named-month> <day-of-month> (non ordinal)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-3.925268232178167),
|
|
|
|
("dayyear", -3.2321210516182215),
|
|
|
|
("last weekend of <named-month>year", -5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<time-of-day> o'clockin|during the <part-of-day>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.429345628954441),
|
|
|
|
("<time-of-day> am|pmtomorrow", -4.736198448394496),
|
|
|
|
("minutehour", -4.513054897080286),
|
|
|
|
("Mother's Dayyear", -5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("at <time-of-day>in|during the <part-of-day>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.0238805208462765),
|
2017-03-08 21:33:55 +03:00
|
|
|
("absorption of , after named day<named-month> <day-of-month> (non ordinal)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-3.724597536716016),
|
|
|
|
("tomorrow<time-of-day> sharp|exactly", -5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Thursdayfrom <datetime> - <datetime> (interval)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.513054897080286),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("on <date><named-month> <day-of-month> (non ordinal)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.0238805208462765),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Thursdayfrom <time-of-day> - <time-of-day> (interval)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.513054897080286),
|
|
|
|
("Mondayin|during the <part-of-day>", -5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("tomorrowfrom <time-of-day> - <time-of-day> (interval)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.0238805208462765),
|
|
|
|
("intersectin|during the <part-of-day>", -5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<day-of-month> (ordinal or number) of <named-month>in|during the <part-of-day>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("from <time-of-day> - <time-of-day> (interval)on <date>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.736198448394496),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"<time-of-day> am|pm",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.513054897080286),
|
|
|
|
("at <time-of-day>intersect", -5.0238805208462765),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<time-of-day> - <time-of-day> (interval)tomorrow",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.429345628954441),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("at <time-of-day>intersect by \",\", \"of\", \"from\", \"'s\"",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.429345628954441),
|
|
|
|
("dayminute", -3.126760535960395),
|
2017-03-08 21:33:55 +03:00
|
|
|
("from <datetime> - <datetime> (interval)on <date>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.0238805208462765),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<datetime> - <datetime> (interval)tomorrow",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.429345628954441),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("absorption of , after named dayintersect by \",\", \"of\", \"from\", \"'s\"",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.0238805208462765),
|
|
|
|
("<ordinal> <cycle> of <time>year", -5.429345628954441),
|
|
|
|
("minuteday", -2.0281482472922856),
|
|
|
|
("absorption of , after named dayintersect",
|
|
|
|
-5.429345628954441),
|
|
|
|
("Octoberyear", -4.176582660459073),
|
2017-03-08 21:33:55 +03:00
|
|
|
("the <day-of-month> (ordinal)in|during the <part-of-day>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("at <time-of-day>absorption of , after named day",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<day-of-month> (ordinal or number) <named-month>year",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.429345628954441),
|
|
|
|
("year<time-of-day> am|pm", -5.429345628954441),
|
|
|
|
("Septemberyear", -5.0238805208462765),
|
|
|
|
("at <time-of-day>on <date>", -4.330733340286331),
|
2017-03-08 21:33:55 +03:00
|
|
|
("between <time-of-day> and <time-of-day> (interval)on <date>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.736198448394496),
|
|
|
|
("Halloweenyear", -5.429345628954441),
|
|
|
|
("dayweek", -5.429345628954441),
|
|
|
|
("weekyear", -5.0238805208462765),
|
|
|
|
("hh:mmin|during the <part-of-day>", -4.736198448394496),
|
|
|
|
("Father's Dayyear", -5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<cycle> after|before <time><time-of-day> am|pm",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.0238805208462765),
|
|
|
|
("February<time> <part-of-day>", -5.429345628954441),
|
|
|
|
("Martin Luther King's Dayyear", -5.0238805208462765),
|
|
|
|
("tomorrowat <time-of-day>", -4.736198448394496),
|
|
|
|
("between <time> and <time>on <date>", -4.736198448394496),
|
|
|
|
("at <time-of-day>tomorrow", -5.0238805208462765),
|
|
|
|
("tomorrow<time-of-day> am|pm", -5.429345628954441),
|
2017-03-08 21:33:55 +03:00
|
|
|
("in|during the <part-of-day>at <time-of-day>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.429345628954441),
|
|
|
|
("Labor Dayyear", -5.429345628954441),
|
|
|
|
("Februaryintersect", -5.429345628954441),
|
|
|
|
("last <cycle> of <time>year", -4.736198448394496),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<named-month> <day-of-month> (non ordinal)year",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.429345628954441),
|
|
|
|
("yearminute", -5.429345628954441)],
|
|
|
|
n = 166},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -1.0039963122932607, unseen = -5.75890177387728,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-23 16:50:04 +03:00
|
|
|
[("in <named-month>year", -5.062595033026967),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<time-of-day> - <time-of-day> (interval)on <date>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.062595033026967),
|
|
|
|
("hourday", -5.062595033026967),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<named-month> <day-of-month> (non ordinal)July",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.062595033026967),
|
|
|
|
("dayhour", -3.270835563798912),
|
|
|
|
("daymonth", -3.047692012484702),
|
|
|
|
("monthday", -4.657129924918802),
|
|
|
|
("monthyear", -4.3694478524670215),
|
|
|
|
("intersecthh:mm", -5.062595033026967),
|
|
|
|
("houryear", -5.062595033026967),
|
|
|
|
("until <time-of-day><time-of-day> am|pm", -5.062595033026967),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<time-of-day> am|pmintersect by \",\", \"of\", \"from\", \"'s\"",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.3694478524670215),
|
|
|
|
("<time-of-day> am|pmintersect", -3.809832064531599),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"year",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.146304301152812),
|
|
|
|
("Tuesdayafter <time-of-day>", -5.062595033026967),
|
2017-03-08 21:33:55 +03:00
|
|
|
("July<day-of-month> (ordinal or number) <named-month>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.062595033026967),
|
|
|
|
("absorption of , after named dayJuly", -4.657129924918802),
|
|
|
|
("monthhour", -4.657129924918802),
|
|
|
|
("hourmonth", -5.062595033026967),
|
|
|
|
("todayat <time-of-day>", -5.062595033026967),
|
|
|
|
("dayday", -4.657129924918802),
|
|
|
|
("mm/ddat <time-of-day>", -4.657129924918802),
|
|
|
|
("<time-of-day> am|pmon <date>", -3.809832064531599),
|
|
|
|
("dayyear", -4.146304301152812),
|
|
|
|
("Thursdaymm/dd", -5.062595033026967),
|
|
|
|
("Thursdayat <time-of-day>", -5.062595033026967),
|
|
|
|
("August<time-of-day> am|pm", -5.062595033026967),
|
|
|
|
("monthminute", -5.062595033026967),
|
|
|
|
("<time-of-day> am|pmtomorrow", -5.062595033026967),
|
|
|
|
("Thursdayhh:mm", -5.062595033026967),
|
2017-03-08 21:33:55 +03:00
|
|
|
("August<day-of-month> (ordinal or number) <named-month>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.062595033026967),
|
|
|
|
("minutemonth", -3.5585176362506927),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Thursdayfrom <datetime> - <datetime> (interval)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.657129924918802),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Thursdayfrom <time-of-day> - <time-of-day> (interval)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.657129924918802),
|
|
|
|
("Aprilyear", -5.062595033026967),
|
2017-03-08 21:33:55 +03:00
|
|
|
("mm/dd<time-of-day> - <time-of-day> (interval)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.657129924918802),
|
2017-03-08 21:33:55 +03:00
|
|
|
("tomorrowfrom <time-of-day> - <time-of-day> (interval)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.062595033026967),
|
|
|
|
("yesterday<time-of-day> am|pm", -5.062595033026967),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"hh:mm",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.146304301152812),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<named-month> <day-of-month> (non ordinal)August",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.062595033026967),
|
|
|
|
("until <time-of-day>on <date>", -4.3694478524670215),
|
|
|
|
("at <time-of-day>intersect", -4.657129924918802),
|
2017-03-08 21:33:55 +03:00
|
|
|
("at <time-of-day>intersect by \",\", \"of\", \"from\", \"'s\"",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.062595033026967),
|
|
|
|
("dayminute", -3.1166848839716534),
|
|
|
|
("intersectSeptember", -3.5585176362506927),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("absorption of , after named dayintersect by \",\", \"of\", \"from\", \"'s\"",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.062595033026967),
|
|
|
|
("minuteday", -2.259234652120432),
|
2017-03-14 14:50:10 +03:00
|
|
|
("absorption of , after named dayintersect",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.062595033026967),
|
|
|
|
("Februaryin|during the <part-of-day>", -5.062595033026967),
|
|
|
|
("week-endin <named-month>", -5.062595033026967),
|
|
|
|
("Octoberyear", -5.062595033026967),
|
|
|
|
("yearhh:mm", -5.062595033026967),
|
|
|
|
("hh:mmon <date>", -3.5585176362506927),
|
|
|
|
("absorption of , after named daySeptember",
|
|
|
|
-4.146304301152812),
|
|
|
|
("on <date>September", -4.657129924918802),
|
|
|
|
("at <time-of-day>on <date>", -4.657129924918802),
|
|
|
|
("absorption of , after named dayFebruary", -4.146304301152812),
|
2017-03-08 21:33:55 +03:00
|
|
|
("July<integer> to|till|before <hour-of-day>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-5.062595033026967),
|
|
|
|
("tomorrowat <time-of-day>", -5.062595033026967),
|
|
|
|
("tomorrow<time-of-day> am|pm", -5.062595033026967),
|
|
|
|
("after <time-of-day><time-of-day> am|pm", -5.062595033026967),
|
|
|
|
("after <time-of-day>year", -5.062595033026967),
|
|
|
|
("yearminute", -5.062595033026967)],
|
|
|
|
n = 96}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("after lunch/work/school",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.3862943611198906,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 2},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("early morning",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("in <number> (implicit minutes)",
|
|
|
|
Classifier{okData =
|
2017-06-27 17:13:55 +03:00
|
|
|
ClassData{prior = -1.041453874828161, unseen = -2.70805020110221,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-27 17:13:55 +03:00
|
|
|
[("integer (numeric)", -0.5596157879354228),
|
|
|
|
("integer (0..19)", -0.8472978603872037)],
|
|
|
|
n = 12},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-06-27 17:13:55 +03:00
|
|
|
ClassData{prior = -0.4353180712578455,
|
2017-03-08 21:33:55 +03:00
|
|
|
unseen = -3.2188758248682006,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("integer (numeric)", -0.3448404862917295),
|
|
|
|
("integer (0..19)", -1.2321436812926323)],
|
|
|
|
n = 22}}),
|
|
|
|
("<ordinal> <cycle> of <time>",
|
|
|
|
Classifier{okData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -2.772588722239781,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("daymonth", -2.0149030205422647),
|
|
|
|
("quarteryear", -2.0149030205422647),
|
2017-03-08 21:33:55 +03:00
|
|
|
("ordinals (first..twentieth,thirtieth,...)day (grain)October",
|
2017-03-14 14:50:10 +03:00
|
|
|
-2.0149030205422647),
|
2017-03-08 21:33:55 +03:00
|
|
|
("ordinals (first..twentieth,thirtieth,...)week (grain)intersect",
|
2017-03-14 14:50:10 +03:00
|
|
|
-2.0149030205422647),
|
|
|
|
("weekmonth", -1.6094379124341003),
|
|
|
|
("ordinal (digits)quarter (grain)year", -2.0149030205422647),
|
2017-03-08 21:33:55 +03:00
|
|
|
("ordinals (first..twentieth,thirtieth,...)week (grain)October",
|
2017-03-14 14:50:10 +03:00
|
|
|
-2.0149030205422647)],
|
|
|
|
n = 4},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -infinity, unseen = -2.0794415416798357,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("year (grain)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -3.0910424533583156,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 20},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("from <datetime> - <datetime> (interval)",
|
|
|
|
Classifier{okData =
|
2017-06-27 22:21:14 +03:00
|
|
|
ClassData{prior = -0.916290731874155, unseen = -3.2188758248682006,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-27 22:21:14 +03:00
|
|
|
[("minuteminute", -1.5686159179138452),
|
|
|
|
("hh:mmhh:mm", -1.5686159179138452),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<time-of-day> am|pmtime-of-day (latent)",
|
2017-06-27 22:21:14 +03:00
|
|
|
-2.4849066497880004),
|
|
|
|
("hourhour", -2.0794415416798357),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<time-of-day> am|pm<time-of-day> am|pm",
|
2017-06-27 22:21:14 +03:00
|
|
|
-2.4849066497880004)],
|
2017-03-08 21:33:55 +03:00
|
|
|
n = 6},
|
|
|
|
koData =
|
2017-06-27 22:21:14 +03:00
|
|
|
ClassData{prior = -0.5108256237659907,
|
|
|
|
unseen = -3.4339872044851463,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-27 22:21:14 +03:00
|
|
|
[("dayhour", -2.70805020110221),
|
|
|
|
("hh:mmtime-of-day (latent)", -1.791759469228055),
|
|
|
|
("minuteminute", -2.3025850929940455),
|
|
|
|
("time-of-day (latent)time-of-day (latent)", -2.70805020110221),
|
|
|
|
("hourhour", -2.3025850929940455),
|
|
|
|
("minutehour", -1.791759469228055),
|
|
|
|
("hh:mmintersect", -2.3025850929940455),
|
|
|
|
("time-of-day (latent)<time-of-day> am|pm", -2.70805020110221),
|
|
|
|
("<named-month> <day-of-month> (non ordinal)time-of-day (latent)",
|
|
|
|
-2.70805020110221)],
|
|
|
|
n = 9}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Saturday",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.0794415416798357,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 6},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("the <cycle> of <time>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.890371757896165,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("week (grain)<named-month>|<named-day> <day-of-month> (ordinal)",
|
|
|
|
-1.7346010553881064),
|
|
|
|
("weekmonth", -1.7346010553881064),
|
|
|
|
("week (grain)October", -1.7346010553881064),
|
|
|
|
("week (grain)<named-month> <day-of-month> (non ordinal)",
|
|
|
|
-1.7346010553881064),
|
|
|
|
("weekday", -1.2237754316221157)],
|
|
|
|
n = 6},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.791759469228055,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("number.number hours",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("from <time-of-day> - <time-of-day> (interval)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -0.6359887667199967,
|
|
|
|
unseen = -3.4339872044851463,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("minuteminute", -1.6094379124341003),
|
|
|
|
("hh:mmhh:mm", -1.6094379124341003),
|
|
|
|
("<time-of-day> am|pmtime-of-day (latent)", -2.70805020110221),
|
|
|
|
("hourhour", -2.3025850929940455),
|
|
|
|
("hourminute", -2.3025850929940455),
|
|
|
|
("time-of-day (latent)<time-of-day> sharp|exactly",
|
|
|
|
-2.70805020110221),
|
|
|
|
("time-of-day (latent)hh:mm", -2.70805020110221),
|
|
|
|
("<time-of-day> am|pm<time-of-day> am|pm", -2.70805020110221)],
|
|
|
|
n = 9},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -0.7537718023763802, unseen = -3.367295829986474,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("hh:mmtime-of-day (latent)", -1.540445040947149),
|
|
|
|
("time-of-day (latent)time-of-day (latent)",
|
|
|
|
-2.2335922215070942),
|
|
|
|
("hourhour", -1.9459101490553135),
|
|
|
|
("minutehour", -1.540445040947149),
|
|
|
|
("time-of-day (latent)<time-of-day> am|pm",
|
|
|
|
-2.639057329615259)],
|
|
|
|
n = 8}}),
|
|
|
|
("integer 21..99",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.3862943611198906,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList [("integer (numeric)integer (numeric)", 0.0)],
|
|
|
|
n = 2}}),
|
|
|
|
("last|next n <cycle>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -4.430816798843313,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("week", -2.627081138568543),
|
|
|
|
("integer (0..19)year (grain)", -3.3202283191284883),
|
|
|
|
("integer (numeric)day (grain)", -3.0325462466767075),
|
|
|
|
("integer (0..19)second (grain) ", -3.3202283191284883),
|
|
|
|
("integer (0..19)hour (grain)", -3.3202283191284883),
|
|
|
|
("second", -2.8094026953624978),
|
|
|
|
("integer (numeric)second (grain) ", -3.3202283191284883),
|
|
|
|
("integer (numeric)year (grain)", -3.3202283191284883),
|
|
|
|
("day", -2.472930458741285), ("year", -2.8094026953624978),
|
|
|
|
("integer (numeric)week (grain)", -3.0325462466767075),
|
|
|
|
("integer (0..19)month (grain)", -3.3202283191284883),
|
|
|
|
("hour", -2.8094026953624978), ("month", -2.8094026953624978),
|
|
|
|
("integer (numeric)minute (grain)", -3.3202283191284883),
|
|
|
|
("integer (0..19)minute (grain)", -3.3202283191284883),
|
|
|
|
("integer (numeric)month (grain)", -3.3202283191284883),
|
|
|
|
("minute", -2.8094026953624978),
|
|
|
|
("integer (numeric)hour (grain)", -3.3202283191284883),
|
|
|
|
("integer (0..19)day (grain)", -3.0325462466767075),
|
|
|
|
("integer (0..19)week (grain)", -3.3202283191284883)],
|
|
|
|
n = 31},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -3.0910424533583156,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("yyyy-mm-dd",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.3862943611198906,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 2},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("mm/dd/yyyy",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.9459101490553135,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 5},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("Memorial Day",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -0.2231435513142097, unseen = -1.791759469228055,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 4},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -1.6094379124341003,
|
|
|
|
unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1}}),
|
|
|
|
("Monday",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.639057329615259,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 12},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("yesterday",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.791759469228055,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 4},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<ordinal> quarter <year>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.9459101490553135,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("quarteryear", -0.6931471805599453),
|
|
|
|
("ordinal (digits)quarter (grain)year", -0.6931471805599453)],
|
|
|
|
n = 2},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("hh:mm:ss",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<hour-of-day> <integer>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("about|exactly <time-of-day>integer (numeric)",
|
|
|
|
-0.6931471805599453),
|
|
|
|
("hour", -0.6931471805599453)],
|
|
|
|
n = 1}}),
|
|
|
|
("nth <time> of <time>",
|
|
|
|
Classifier{okData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.4700036292457356, unseen = -2.833213344056216,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-13 21:38:34 +03:00
|
|
|
[("daymonth", -0.9808292530117262),
|
2017-03-08 21:33:55 +03:00
|
|
|
("ordinals (first..twentieth,thirtieth,...)Tuesdayintersect",
|
2017-03-13 21:38:34 +03:00
|
|
|
-2.0794415416798357),
|
2017-03-08 21:33:55 +03:00
|
|
|
("ordinals (first..twentieth,thirtieth,...)Wednesdayintersect",
|
2017-03-14 14:50:10 +03:00
|
|
|
-1.6739764335716716),
|
2017-03-08 21:33:55 +03:00
|
|
|
("ordinals (first..twentieth,thirtieth,...)TuesdayOctober",
|
2017-03-14 14:50:10 +03:00
|
|
|
-1.6739764335716716)],
|
|
|
|
n = 5},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.9808292530117262,
|
|
|
|
unseen = -2.5649493574615367,
|
2017-03-13 21:38:34 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("daymonth", -1.0986122886681098),
|
2017-03-13 21:38:34 +03:00
|
|
|
("ordinals (first..twentieth,thirtieth,...)TuesdaySeptember",
|
2017-03-14 14:50:10 +03:00
|
|
|
-1.791759469228055),
|
2017-03-13 21:38:34 +03:00
|
|
|
("ordinals (first..twentieth,thirtieth,...)WednesdayOctober",
|
2017-03-14 14:50:10 +03:00
|
|
|
-1.3862943611198906)],
|
2017-03-13 21:38:34 +03:00
|
|
|
n = 3}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Valentine's Day",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.3862943611198906,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 2},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("April",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("end of month",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("week (grain)",
|
|
|
|
Classifier{okData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -8.004270767353637e-2,
|
2017-03-08 21:33:55 +03:00
|
|
|
unseen = -3.6375861597263857,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 36},
|
|
|
|
koData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -2.5649493574615367,
|
|
|
|
unseen = -1.6094379124341003,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 3}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<part-of-day> of <time>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.3978952727983707,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("part of daysintersect by \",\", \"of\", \"from\", \"'s\"",
|
|
|
|
-1.6094379124341003),
|
|
|
|
("hourday", -0.916290731874155),
|
|
|
|
("part of daysthe <day-of-month> (ordinal)",
|
|
|
|
-1.6094379124341003),
|
|
|
|
("part of daysthe <day-of-month> (number)",
|
|
|
|
-1.6094379124341003)],
|
|
|
|
n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.6094379124341003,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("past year (latent)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("integer (numeric)", 0.0)],
|
|
|
|
n = 1}}),
|
|
|
|
("now",
|
|
|
|
Classifier{okData =
|
2017-07-26 21:30:14 +03:00
|
|
|
ClassData{prior = -0.15415067982725836,
|
|
|
|
unseen = -2.0794415416798357,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 6},
|
|
|
|
koData =
|
2017-07-26 21:30:14 +03:00
|
|
|
ClassData{prior = -1.9459101490553135,
|
|
|
|
unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<day-of-month> (ordinal or number) of <named-month>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -0.13353139262452263,
|
|
|
|
unseen = -3.0910424533583156,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("ordinal (digits)July", -2.3513752571634776),
|
|
|
|
("ordinals (first..twentieth,thirtieth,...)March",
|
|
|
|
-2.3513752571634776),
|
|
|
|
("ordinal (digits)February", -2.3513752571634776),
|
|
|
|
("integer (numeric)February", -1.9459101490553135),
|
|
|
|
("month", -0.9650808960435872),
|
|
|
|
("ordinal (digits)March", -2.3513752571634776),
|
|
|
|
("integer (numeric)July", -2.3513752571634776)],
|
|
|
|
n = 7},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -2.0794415416798357,
|
|
|
|
unseen = -2.3025850929940455,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("ordinal (digits)February", -1.5040773967762742),
|
|
|
|
("month", -1.5040773967762742)],
|
|
|
|
n = 1}}),
|
|
|
|
("this <part-of-day>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.1972245773362196,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("hour", -0.6931471805599453),
|
|
|
|
("part of days", -0.6931471805599453)],
|
|
|
|
n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("Friday",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.3978952727983707,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 9},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("in|during the <part-of-day>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -8.701137698962981e-2,
|
|
|
|
unseen = -3.258096538021482,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("early morning", -2.5257286443082556),
|
|
|
|
("hour", -0.7339691750802004),
|
|
|
|
("part of days", -0.8209805520698302)],
|
|
|
|
n = 11},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -2.4849066497880004, unseen = -1.791759469228055,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("hour", -0.916290731874155),
|
|
|
|
("part of days", -0.916290731874155)],
|
|
|
|
n = 1}}),
|
|
|
|
("tomorrow",
|
|
|
|
Classifier{okData =
|
2017-06-09 19:21:03 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -2.9444389791664407,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 17},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("hh(:mm) - <time-of-day> am|pm",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.70805020110221,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("time-of-day (latent)", -0.6931471805599453),
|
|
|
|
("hour", -0.6931471805599453)],
|
|
|
|
n = 6},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("this|last|next <cycle>",
|
|
|
|
Classifier{okData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -0.16251892949777494,
|
2017-03-08 21:33:55 +03:00
|
|
|
unseen = -4.3694478524670215,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("week", -1.5234954826333758),
|
|
|
|
("month (grain)", -2.9704144655697013),
|
|
|
|
("year (grain)", -1.8718021769015913),
|
|
|
|
("week (grain)", -1.5234954826333758),
|
|
|
|
("quarter", -2.7472709142554916), ("year", -1.8718021769015913),
|
|
|
|
("month", -2.9704144655697013),
|
|
|
|
("quarter (grain)", -2.7472709142554916)],
|
|
|
|
n = 34},
|
|
|
|
koData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -1.8971199848858813,
|
|
|
|
unseen = -3.1354942159291497,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-23 16:50:04 +03:00
|
|
|
[("week", -1.4816045409242156),
|
|
|
|
("week (grain)", -1.4816045409242156),
|
|
|
|
("day", -1.9924301646902063),
|
|
|
|
("day (grain)", -1.9924301646902063)],
|
|
|
|
n = 6}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Mother's Day",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.791759469228055,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 4},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("New Year's Eve",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.3862943611198906,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 2},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("the <ordinal> <cycle> of <time>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("quarteryear", -0.6931471805599453),
|
|
|
|
("ordinal (digits)quarter (grain)year", -0.6931471805599453)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("by <time>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.9444389791664407,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("noon|midnight|EOD|end of day", -2.1972245773362196),
|
|
|
|
("end of month", -2.1972245773362196),
|
|
|
|
("time-of-day (latent)", -2.1972245773362196),
|
|
|
|
("<time-of-day> am|pm", -2.1972245773362196),
|
|
|
|
("hh:mm", -2.1972245773362196), ("hour", -1.791759469228055),
|
|
|
|
("month", -2.1972245773362196), ("minute", -1.791759469228055)],
|
|
|
|
n = 5},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -2.1972245773362196,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("half an hour",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.9459101490553135,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 5},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("the <day-of-month> (ordinal)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -0.2006706954621511,
|
|
|
|
unseen = -2.4849066497880004,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("ordinals (first..twentieth,thirtieth,...)",
|
|
|
|
-1.7047480922384253),
|
|
|
|
("ordinal (digits)", -0.2006706954621511)],
|
|
|
|
n = 9},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -1.7047480922384253,
|
|
|
|
unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList [("ordinal (digits)", -0.2876820724517809)],
|
|
|
|
n = 2}}),
|
2017-06-23 16:50:04 +03:00
|
|
|
("last weekend of <named-month>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.639057329615259,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("October", -0.9555114450274363), ("July", -1.8718021769015913),
|
|
|
|
("month", -0.7731898882334817)],
|
|
|
|
n = 5},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.3862943611198906,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("the <day-of-month> (number)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("integer (numeric)", 0.0)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
2017-05-10 16:51:58 +03:00
|
|
|
("fractional number",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0},
|
|
|
|
koData =
|
2017-07-20 21:04:13 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -2.9444389791664407,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 17}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Sunday",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.3025850929940455,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 8},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("February",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.70805020110221,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 13},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("minute (grain)",
|
|
|
|
Classifier{okData =
|
2017-06-27 17:13:55 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -2.833213344056216,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 15},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("the <ordinal> quarter",
|
|
|
|
Classifier{okData =
|
2017-03-13 21:38:34 +03:00
|
|
|
ClassData{prior = -0.6931471805599453,
|
|
|
|
unseen = -1.6094379124341003,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("ordinal (digits)quarter (grain)", -0.6931471805599453),
|
|
|
|
("quarter", -0.6931471805599453)],
|
2017-03-13 21:38:34 +03:00
|
|
|
n = 1},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-03-13 21:38:34 +03:00
|
|
|
ClassData{prior = -0.6931471805599453,
|
|
|
|
unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("ordinal (digits)quarter (grain)", -0.6931471805599453),
|
|
|
|
("quarter", -0.6931471805599453)],
|
|
|
|
n = 1}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("time-of-day (latent)",
|
|
|
|
Classifier{okData =
|
2017-06-27 22:21:14 +03:00
|
|
|
ClassData{prior = -0.5108256237659907, unseen = -4.143134726391533,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("integer (numeric)", -0.10178269430994236),
|
|
|
|
("integer (0..19)", -2.3353749158170367)],
|
|
|
|
n = 60},
|
|
|
|
koData =
|
2017-06-27 22:21:14 +03:00
|
|
|
ClassData{prior = -0.916290731874155, unseen = -3.7612001156935624,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
2017-06-27 22:21:14 +03:00
|
|
|
HashMap.fromList [("integer (numeric)", -2.409755157906053e-2)],
|
|
|
|
n = 40}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("year",
|
|
|
|
Classifier{okData =
|
2017-07-20 21:04:13 +03:00
|
|
|
ClassData{prior = -0.24362208265775043,
|
2017-06-23 16:50:04 +03:00
|
|
|
unseen = -3.4339872044851463,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods = HashMap.fromList [("integer (numeric)", 0.0)],
|
2017-06-23 16:50:04 +03:00
|
|
|
n = 29},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-07-20 21:04:13 +03:00
|
|
|
ClassData{prior = -1.5314763709643884,
|
|
|
|
unseen = -2.3025850929940455,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods = HashMap.fromList [("integer (numeric)", 0.0)],
|
2017-07-20 21:04:13 +03:00
|
|
|
n = 8}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("last <day-of-week> of <time>",
|
|
|
|
Classifier{okData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -2.3978952727983707,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("daymonth", -0.916290731874155),
|
|
|
|
("SundayMarch", -1.6094379124341003),
|
|
|
|
("MondayMarch", -1.6094379124341003),
|
|
|
|
("Sundayintersect", -1.6094379124341003)],
|
|
|
|
n = 3},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -infinity, unseen = -1.6094379124341003,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<integer> <unit-of-duration>",
|
|
|
|
Classifier{okData =
|
2017-06-27 17:13:55 +03:00
|
|
|
ClassData{prior = -0.758529939822797, unseen = -4.584967478670572,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-27 17:13:55 +03:00
|
|
|
[("week", -2.3774864011671633),
|
|
|
|
("integer (0..19)year (grain)", -3.188416617383492),
|
|
|
|
("integer (numeric)day (grain)", -2.62880082944807),
|
|
|
|
("integer (0..19)second (grain) ", -3.8815637979434374),
|
|
|
|
("integer (0..19)hour (grain)", -2.782951509275328),
|
|
|
|
("second", -3.8815637979434374),
|
|
|
|
("integer (numeric)year (grain)", -3.8815637979434374),
|
|
|
|
("day", -2.62880082944807), ("year", -2.9652730660692823),
|
|
|
|
("integer (numeric)week (grain)", -2.9652730660692823),
|
|
|
|
("integer (0..19)month (grain)", -3.4760986898352733),
|
|
|
|
("hour", -2.495269436823547), ("month", -3.4760986898352733),
|
|
|
|
("integer (numeric)minute (grain)", -2.9652730660692823),
|
|
|
|
("integer (0..19)minute (grain)", -2.782951509275328),
|
|
|
|
("minute", -2.2721258855093374),
|
|
|
|
("integer (numeric)hour (grain)", -3.4760986898352733),
|
|
|
|
("integer (0..19)week (grain)", -2.9652730660692823)],
|
|
|
|
n = 37},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -0.6317782341836533, unseen = -4.68213122712422,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("week", -2.8810693652338513),
|
|
|
|
("integer (0..19)year (grain)", -3.5742165457937967),
|
|
|
|
("integer (numeric)day (grain)", -3.2865344733420154),
|
|
|
|
("integer (0..19)second (grain) ", -3.5742165457937967),
|
|
|
|
("integer (0..19)hour (grain)", -3.5742165457937967),
|
|
|
|
("second", -3.0633909220278057),
|
|
|
|
("integer (numeric)second (grain) ", -3.5742165457937967),
|
|
|
|
("integer (numeric)year (grain)", -3.5742165457937967),
|
|
|
|
("day", -2.7269186854065928), ("quarter", -3.979681653901961),
|
|
|
|
("year", -3.0633909220278057),
|
|
|
|
("integer (numeric)week (grain)", -3.2865344733420154),
|
|
|
|
("integer (0..19)month (grain)", -3.5742165457937967),
|
|
|
|
("hour", -1.9647786333596962), ("month", -3.0633909220278057),
|
|
|
|
("integer (numeric)minute (grain)", -3.5742165457937967),
|
|
|
|
("integer (0..19)minute (grain)", -3.5742165457937967),
|
|
|
|
("integer (numeric)month (grain)", -3.5742165457937967),
|
|
|
|
("minute", -3.0633909220278057),
|
|
|
|
("integer (numeric)hour (grain)", -2.1078794770003695),
|
|
|
|
("integer (0..19)day (grain)", -3.2865344733420154),
|
|
|
|
("integer (0..19)week (grain)", -3.5742165457937967),
|
|
|
|
("integer (0..19)quarter (grain)", -3.979681653901961)],
|
|
|
|
n = 42}}),
|
|
|
|
("hhmm (latent)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.0794415416798357,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 6},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<time-of-day> am|pm",
|
|
|
|
Classifier{okData =
|
2017-04-06 20:50:34 +03:00
|
|
|
ClassData{prior = -0.29354719190417905,
|
|
|
|
unseen = -5.231108616854587,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("integer after|past <hour-of-day>", -3.8394523125933104),
|
|
|
|
("at <time-of-day>", -2.2300144001592104),
|
|
|
|
("<time-of-day> o'clock", -4.127134385045092),
|
|
|
|
("half after|past <hour-of-day>", -4.127134385045092),
|
|
|
|
("time-of-day (latent)", -1.7600107709134747),
|
|
|
|
("hhmm (latent)", -4.532599493153256),
|
|
|
|
("hh:mm", -2.181224235989778),
|
|
|
|
("quarter after|past <hour-of-day>", -4.532599493153256),
|
|
|
|
("about|exactly <time-of-day>", -4.532599493153256),
|
|
|
|
("until <time-of-day>", -3.8394523125933104),
|
|
|
|
("hour", -1.2939210409888755),
|
|
|
|
("<time-of-day> sharp|exactly", -4.532599493153256),
|
|
|
|
("minute", -1.6422277352570913),
|
|
|
|
("after <time-of-day>", -4.532599493153256)],
|
|
|
|
n = 85},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -1.3689026184080213, unseen = -4.31748811353631,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("<integer> to|till|before <hour-of-day>", -3.20545280453606),
|
|
|
|
("<hour-of-day> <integer>", -3.6109179126442243),
|
|
|
|
("time-of-day (latent)", -1.0459685551826876),
|
|
|
|
("hour", -1.0082282271998406), ("minute", -2.917770732084279),
|
|
|
|
("after <time-of-day>", -3.6109179126442243)],
|
|
|
|
n = 29}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Thanksgiving Day",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.1972245773362196,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 7},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
2017-06-16 21:46:04 +03:00
|
|
|
("part of <named-month>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.1972245773362196,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("March", -0.6931471805599453), ("month", -0.6931471805599453)],
|
|
|
|
n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("a <unit-of-duration>",
|
|
|
|
Classifier{okData =
|
2017-07-26 21:30:14 +03:00
|
|
|
ClassData{prior = -0.5753641449035618,
|
|
|
|
unseen = -3.4965075614664802,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-07-26 21:30:14 +03:00
|
|
|
[("week", -2.0794415416798357),
|
|
|
|
("year (grain)", -2.772588722239781),
|
|
|
|
("second", -2.772588722239781),
|
|
|
|
("week (grain)", -2.0794415416798357),
|
|
|
|
("day", -2.0794415416798357),
|
|
|
|
("minute (grain)", -2.772588722239781),
|
|
|
|
("year", -2.772588722239781),
|
|
|
|
("second (grain) ", -2.772588722239781),
|
|
|
|
("minute", -2.772588722239781),
|
|
|
|
("day (grain)", -2.0794415416798357)],
|
|
|
|
n = 9},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-07-26 21:30:14 +03:00
|
|
|
ClassData{prior = -0.8266785731844679, unseen = -3.367295829986474,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("hour (grain)", -1.7227665977411035),
|
|
|
|
("quarter", -1.9459101490553135), ("hour", -1.7227665977411035),
|
|
|
|
("quarter (grain)", -1.9459101490553135)],
|
|
|
|
n = 7}}),
|
|
|
|
("hh:mm",
|
|
|
|
Classifier{okData =
|
2017-04-06 20:50:34 +03:00
|
|
|
ClassData{prior = -5.406722127027582e-2,
|
|
|
|
unseen = -4.02535169073515,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 54},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-04-06 20:50:34 +03:00
|
|
|
ClassData{prior = -2.9444389791664407,
|
|
|
|
unseen = -1.6094379124341003,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 3}}),
|
|
|
|
("quarter of an hour",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.791759469228055,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 4},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("second (grain) ",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.0794415416798357,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 6},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("ordinals (first..twentieth,thirtieth,...)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -6.899287148695143e-2,
|
|
|
|
unseen = -2.772588722239781,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 14},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -2.70805020110221, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1}}),
|
|
|
|
("quarter after|past <hour-of-day>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("time-of-day (latent)", -0.6931471805599453),
|
|
|
|
("hour", -0.6931471805599453)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("the <cycle> after|before <time>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.0794415416798357,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("day (grain)tomorrow", -1.252762968495368),
|
|
|
|
("dayday", -0.8472978603872037),
|
|
|
|
("day (grain)yesterday", -1.252762968495368)],
|
|
|
|
n = 2},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.3862943611198906,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("about|exactly <time-of-day>",
|
|
|
|
Classifier{okData =
|
2017-06-22 13:39:45 +03:00
|
|
|
ClassData{prior = -0.2231435513142097, unseen = -3.367295829986474,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-22 13:39:45 +03:00
|
|
|
[("week", -2.639057329615259),
|
|
|
|
("hh(:mm) - <time-of-day> am|pm", -2.639057329615259),
|
|
|
|
("this|last|next <cycle>", -2.639057329615259),
|
|
|
|
("day", -2.2335922215070942),
|
|
|
|
("time-of-day (latent)", -2.639057329615259),
|
|
|
|
("hhmm (latent)", -2.2335922215070942),
|
|
|
|
("<time-of-day> am|pm", -2.639057329615259),
|
|
|
|
("hour", -1.9459101490553135),
|
|
|
|
("next <time>", -2.639057329615259),
|
|
|
|
("this|next <day-of-week>", -2.639057329615259),
|
|
|
|
("minute", -2.2335922215070942)],
|
2017-03-08 21:33:55 +03:00
|
|
|
n = 8},
|
|
|
|
koData =
|
2017-06-22 13:39:45 +03:00
|
|
|
ClassData{prior = -1.6094379124341003, unseen = -2.833213344056216,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-22 13:39:45 +03:00
|
|
|
[("mm/dd", -2.0794415416798357), ("day", -2.0794415416798357),
|
|
|
|
("time-of-day (latent)", -2.0794415416798357),
|
|
|
|
("hour", -2.0794415416798357)],
|
|
|
|
n = 2}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"",
|
|
|
|
Classifier{okData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -0.4769240720903093, unseen = -5.147494476813453,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("Wednesday<named-month> <day-of-month> (non ordinal)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.448516375942715),
|
|
|
|
("dayhour", -3.1957534074473464),
|
|
|
|
("daymonth", -3.1957534074473464),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<named-month> <day-of-month> (non ordinal)Friday",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.448516375942715),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("Friday<named-month> <day-of-month> (non ordinal)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-3.7553691953827695),
|
|
|
|
("Wednesdayintersect", -4.448516375942715),
|
|
|
|
("Labor Daythis|last|next <cycle>", -4.448516375942715),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"year",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.448516375942715),
|
|
|
|
("<part-of-day> of <time>February", -4.448516375942715),
|
|
|
|
("Saturday<time-of-day> am|pm", -4.448516375942715),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Martin Luther King's Daythis|last|next <cycle>",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.448516375942715),
|
|
|
|
("on <date><time-of-day> am|pm", -4.448516375942715),
|
|
|
|
("hourmonth", -4.448516375942715),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"intersect",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.448516375942715),
|
|
|
|
("dayday", -2.576714199041123),
|
|
|
|
("the <day-of-month> (ordinal)February", -4.04305126783455),
|
|
|
|
("WednesdayOctober", -4.448516375942715),
|
|
|
|
("Wednesdaythis|last|next <cycle>", -4.04305126783455),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect<named-month> <day-of-month> (non ordinal)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-3.5322256440685593),
|
|
|
|
("dayyear", -2.9444389791664407),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("Saturday<named-month> <day-of-month> (non ordinal)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.448516375942715),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("<named-month> <day-of-month> (non ordinal)intersect",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.448516375942715),
|
|
|
|
("Thursdayhh:mm", -4.04305126783455),
|
|
|
|
("Thanksgiving Daythis|last|next <cycle>", -4.448516375942715),
|
|
|
|
("Memorial Daythis|last|next <cycle>", -4.448516375942715),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("on <date><named-month> <day-of-month> (non ordinal)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.04305126783455),
|
|
|
|
("TuesdayOctober", -4.448516375942715),
|
|
|
|
("the <day-of-month> (ordinal)March", -4.448516375942715),
|
|
|
|
("Mondaythis|last|next <cycle>", -4.448516375942715),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("Fridayintersect by \",\", \"of\", \"from\", \"'s\"",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.04305126783455),
|
|
|
|
("Fridayintersect", -4.448516375942715),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Thursday<datetime> - <datetime> (interval)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-3.7553691953827695),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Thursday<time-of-day> - <time-of-day> (interval)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-3.5322256440685593),
|
|
|
|
("Tuesdaythis|last|next <cycle>", -4.448516375942715),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Sunday<named-month> <day-of-month> (non ordinal)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.448516375942715),
|
|
|
|
("dayminute", -2.6567569067146595),
|
|
|
|
("intersectyear", -4.448516375942715),
|
|
|
|
("minuteday", -3.5322256440685593),
|
|
|
|
("this|last|next <cycle>Sunday", -4.448516375942715),
|
|
|
|
("Sundaythis|last|next <cycle>", -4.448516375942715),
|
|
|
|
("intersectintersect", -4.448516375942715),
|
|
|
|
("weekday", -4.448516375942715),
|
|
|
|
("dayweek", -3.349904087274605),
|
|
|
|
("Thursday<time-of-day> am|pm", -4.448516375942715),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Monday<named-month> <day-of-month> (non ordinal)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.04305126783455),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<named-month> <day-of-month> (non ordinal)year",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.04305126783455)],
|
2017-03-14 14:50:10 +03:00
|
|
|
n = 54},
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
koData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -0.9694005571881036, unseen = -4.867534450455582,
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-23 16:50:04 +03:00
|
|
|
[("week-endJuly", -4.1666652238017265),
|
|
|
|
("week-endOctober", -3.4735180432417816),
|
|
|
|
("daymonth", -1.9694406464655074),
|
|
|
|
("TuesdaySeptember", -4.1666652238017265),
|
|
|
|
("Wednesdayintersect", -4.1666652238017265),
|
|
|
|
("hourmonth", -3.068052935133617),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"intersect",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.1666652238017265),
|
|
|
|
("SundayFebruary", -4.1666652238017265),
|
|
|
|
("WednesdayOctober", -4.1666652238017265),
|
|
|
|
("week-endintersect", -4.1666652238017265),
|
|
|
|
("FridayJuly", -3.7612001156935624),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("<named-month> <day-of-month> (non ordinal)intersect",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.1666652238017265),
|
|
|
|
("FridaySeptember", -4.1666652238017265),
|
|
|
|
("WednesdayFebruary", -4.1666652238017265),
|
|
|
|
("minutemonth", -3.250374491927572),
|
|
|
|
("SundayMarch", -4.1666652238017265),
|
Optimize simple time predicates
Summary:
This is the next step for:
https://fb.facebook.com/groups/527352907463243/permalink/600056483526218/
This:
* changes the time language to be able to track contradictions (`EmptyPredicate`)
* changes the time language to be able to collect non-contradicting pieces, like month and hour and unify them
* provides an efficient way to convert those pieces into (past,future) time series
* adds AMPM predicate runner - there's a bit of overlap with is12H, but it basically works
* changes a test case that was wrong before
* regenerates classifiers, I'm not sure why they changed exactly
Before:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(15.50 secs, 6,171,188,928 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(110.82 secs, 44,031,569,512 bytes)
```
After:
```
res <- H.io $ let sentence = "10am thurs 4.30 thurs 12pm sat" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(1.24 secs, 703,020,912 bytes)
res <- H.io $ let sentence = "I have 9 am 12 pm 1 pm 2pm 4 pm 3 pm on Saturday" in (debugTokens sentence $ analyze sentence (testContext {lang = EN}) HashSet.empty)
(9.51 secs, 5,891,109,592 bytes)
```
Reviewed By: JonCoens
Differential Revision: D4676812
fbshipit-source-id: 9810203
2017-03-14 02:49:47 +03:00
|
|
|
("Fridayintersect by \",\", \"of\", \"from\", \"'s\"",
|
2017-06-23 16:50:04 +03:00
|
|
|
-4.1666652238017265),
|
|
|
|
("MondayFebruary", -3.7612001156935624),
|
|
|
|
("Fridayintersect", -4.1666652238017265),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Thursday<time-of-day> - <time-of-day> (interval)",
|
2017-06-23 16:50:04 +03:00
|
|
|
-3.7612001156935624),
|
|
|
|
("dayminute", -2.780370862681836),
|
|
|
|
("SaturdaySeptember", -4.1666652238017265),
|
|
|
|
("intersectSeptember", -3.250374491927572),
|
|
|
|
("MondayMarch", -4.1666652238017265),
|
|
|
|
("on <date>September", -3.7612001156935624),
|
|
|
|
("intersectintersect", -4.1666652238017265),
|
|
|
|
("Tuesdayintersect", -4.1666652238017265),
|
|
|
|
("Sundayintersect", -4.1666652238017265)],
|
|
|
|
n = 33}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("last <time>",
|
|
|
|
Classifier{okData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -1.0986122886681098, unseen = -3.295836866004329,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-23 16:50:04 +03:00
|
|
|
[("Father's Day", -2.5649493574615367),
|
|
|
|
("Martin Luther King's Day", -2.5649493574615367),
|
|
|
|
("Memorial Day", -2.5649493574615367),
|
|
|
|
("Mother's Day", -2.5649493574615367),
|
|
|
|
("day", -1.3121863889661687), ("Sunday", -2.5649493574615367),
|
|
|
|
("hour", -2.5649493574615367), ("Tuesday", -2.5649493574615367),
|
|
|
|
("week-end", -2.5649493574615367)],
|
2017-03-08 21:33:55 +03:00
|
|
|
n = 7},
|
|
|
|
koData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -0.40546510810816444,
|
|
|
|
unseen = -3.713572066704308,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-23 16:50:04 +03:00
|
|
|
[("intersect", -2.995732273553991),
|
|
|
|
("Monday", -2.995732273553991), ("day", -2.0794415416798357),
|
|
|
|
("Sunday", -2.995732273553991),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"",
|
2017-06-23 16:50:04 +03:00
|
|
|
-1.742969305058623),
|
|
|
|
("hour", -1.2909841813155656),
|
|
|
|
("week-end", -1.8971199848858813)],
|
|
|
|
n = 14}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("March",
|
|
|
|
Classifier{okData =
|
2017-06-16 21:46:04 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -2.9444389791664407,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 17},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<named-month>|<named-day> <day-of-month> (ordinal)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -3.0910424533583156,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("Octoberordinal (digits)", -1.9459101490553135),
|
|
|
|
("Thursdayordinal (digits)", -2.3513752571634776),
|
|
|
|
("day", -1.9459101490553135),
|
|
|
|
("Marchordinals (first..twentieth,thirtieth,...)",
|
|
|
|
-1.9459101490553135),
|
|
|
|
("Tuesdayordinal (digits)", -2.3513752571634776),
|
|
|
|
("month", -1.252762968495368),
|
|
|
|
("Marchordinal (digits)", -2.3513752571634776)],
|
|
|
|
n = 7},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -2.0794415416798357,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("Labor Day weekend",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<day-of-month> (ordinal)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("ordinal (digits)", 0.0)], n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("Christmas",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.0794415416798357,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 6},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("until <time-of-day>",
|
|
|
|
Classifier{okData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.9808292530117262, unseen = -3.044522437723423,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("time-of-day (latent)", -2.3025850929940455),
|
|
|
|
("<time-of-day> am|pm", -1.6094379124341003),
|
|
|
|
("hh:mm", -1.8971199848858813), ("hour", -1.8971199848858813),
|
|
|
|
("minute", -1.3862943611198906)],
|
2017-03-08 21:33:55 +03:00
|
|
|
n = 6},
|
|
|
|
koData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.4700036292457356, unseen = -3.367295829986474,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("intersect", -1.7227665977411035),
|
|
|
|
("yesterday", -2.2335922215070942),
|
|
|
|
("day", -2.2335922215070942), ("hh:mm", -1.7227665977411035),
|
|
|
|
("hour", -2.639057329615259), ("minute", -1.252762968495368)],
|
|
|
|
n = 10}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<duration> after|before|from <time>",
|
|
|
|
Classifier{okData =
|
2017-07-26 21:30:14 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -3.258096538021482,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-07-26 21:30:14 +03:00
|
|
|
[("a <unit-of-duration>now", -2.5257286443082556),
|
|
|
|
("a <unit-of-duration>Christmas", -2.5257286443082556),
|
|
|
|
("<integer> <unit-of-duration>today", -2.5257286443082556),
|
|
|
|
("daysecond", -2.5257286443082556),
|
|
|
|
("a <unit-of-duration>right now", -2.5257286443082556),
|
|
|
|
("minutenograin", -2.5257286443082556),
|
|
|
|
("<integer> <unit-of-duration>Christmas", -2.5257286443082556),
|
|
|
|
("secondnograin", -2.5257286443082556),
|
|
|
|
("yearday", -1.8325814637483102),
|
|
|
|
("daynograin", -2.5257286443082556),
|
|
|
|
("<integer> <unit-of-duration>now", -2.120263536200091)],
|
|
|
|
n = 7},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-07-26 21:30:14 +03:00
|
|
|
ClassData{prior = -infinity, unseen = -2.4849066497880004,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("Independence Day",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("decimal number",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1}}),
|
|
|
|
("next <time>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -3.5263605246161616,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("Martin Luther King's Day", -2.803360380906535),
|
|
|
|
("Halloween", -2.803360380906535),
|
|
|
|
("Wednesday", -2.803360380906535),
|
|
|
|
("Memorial Day", -2.803360380906535),
|
|
|
|
("Monday", -2.803360380906535),
|
|
|
|
("Mother's Day", -2.803360380906535),
|
|
|
|
("day", -1.0986122886681098),
|
|
|
|
("Thanksgiving Day", -2.803360380906535),
|
|
|
|
("March", -2.803360380906535), ("month", -2.803360380906535),
|
|
|
|
("Tuesday", -2.1102132003465894)],
|
|
|
|
n = 11},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -2.4849066497880004,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<time-of-day> sharp|exactly",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.890371757896165,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("at <time-of-day>", -2.1400661634962708),
|
|
|
|
("time-of-day (latent)", -2.1400661634962708),
|
|
|
|
("hhmm (latent)", -2.1400661634962708),
|
|
|
|
("<time-of-day> am|pm", -2.1400661634962708),
|
|
|
|
("hh:mm", -2.1400661634962708), ("hour", -1.7346010553881064),
|
|
|
|
("minute", -1.4469189829363254)],
|
|
|
|
n = 5},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -2.0794415416798357,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("Memorial Day Weekend",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("negative numbers",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0},
|
|
|
|
koData =
|
2017-06-27 22:21:14 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -3.1354942159291497,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods = HashMap.fromList [("integer (numeric)", 0.0)],
|
2017-06-27 22:21:14 +03:00
|
|
|
n = 21}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("about|exactly <duration>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("half an hour", -0.6931471805599453),
|
|
|
|
("minute", -0.6931471805599453)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<time> before last|after next",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.639057329615259,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("Wednesday", -1.8718021769015913),
|
|
|
|
("Friday", -1.466337068793427), ("day", -1.1786549963416462),
|
|
|
|
("March", -1.8718021769015913), ("month", -1.8718021769015913)],
|
|
|
|
n = 4},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.791759469228055,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("by the end of <time>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("this|last|next <cycle>", -0.6931471805599453),
|
|
|
|
("month", -0.6931471805599453)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("hhmm (military) am|pm",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<datetime> - <datetime> (interval)",
|
|
|
|
Classifier{okData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.48550781578170077,
|
|
|
|
unseen = -3.891820298110627,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("minuteminute", -1.4733057381095205),
|
|
|
|
("hh:mmhh:mm", -1.6739764335716716),
|
|
|
|
("dayday", -2.772588722239781),
|
|
|
|
("hourhour", -2.2617630984737906),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<named-month> <day-of-month> (non ordinal)<named-month> <day-of-month> (non ordinal)",
|
2017-03-14 14:50:10 +03:00
|
|
|
-2.772588722239781),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"hh:mm",
|
2017-03-14 14:50:10 +03:00
|
|
|
-2.772588722239781),
|
2017-03-08 21:33:55 +03:00
|
|
|
("intersect by \",\", \"of\", \"from\", \"'s\"<time-of-day> am|pm",
|
2017-03-14 14:50:10 +03:00
|
|
|
-3.1780538303479458),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<time-of-day> am|pm<time-of-day> am|pm",
|
2017-03-14 14:50:10 +03:00
|
|
|
-2.4849066497880004)],
|
2017-03-08 21:33:55 +03:00
|
|
|
n = 16},
|
|
|
|
koData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.9555114450274363,
|
|
|
|
unseen = -3.6109179126442243,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("<named-month> <day-of-month> (non ordinal)July",
|
2017-03-14 14:50:10 +03:00
|
|
|
-2.890371757896165),
|
|
|
|
("daymonth", -2.4849066497880004),
|
|
|
|
("<time-of-day> am|pmintersect", -2.890371757896165),
|
|
|
|
("hh:mm<time-of-day> am|pm", -2.4849066497880004),
|
|
|
|
("minuteminute", -1.9740810260220096),
|
2017-03-08 21:33:55 +03:00
|
|
|
("hourhour", -2.4849066497880004),
|
2017-03-14 14:50:10 +03:00
|
|
|
("minutehour", -2.4849066497880004),
|
|
|
|
("hh:mmintersect", -1.9740810260220096),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<named-month> <day-of-month> (non ordinal)August",
|
2017-03-14 14:50:10 +03:00
|
|
|
-2.890371757896165),
|
2017-03-08 21:33:55 +03:00
|
|
|
("about|exactly <time-of-day><time-of-day> am|pm",
|
2017-03-14 14:50:10 +03:00
|
|
|
-2.890371757896165)],
|
|
|
|
n = 10}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("Tuesday",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.639057329615259,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 12},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("New Year's Day",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -0.6931471805599453,
|
|
|
|
unseen = -1.3862943611198906,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 2},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -0.6931471805599453,
|
|
|
|
unseen = -1.3862943611198906,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 2}}),
|
|
|
|
("fortnight",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.3862943611198906,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 2},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<integer> and an half hour",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("integer (numeric)", 0.0)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("in <named-month>",
|
|
|
|
Classifier{okData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -0.6931471805599453,
|
2017-03-08 21:33:55 +03:00
|
|
|
unseen = -2.0794415416798357,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("October", -1.252762968495368), ("March", -1.252762968495368),
|
|
|
|
("month", -0.8472978603872037)],
|
|
|
|
n = 2},
|
|
|
|
koData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -0.6931471805599453,
|
|
|
|
unseen = -2.0794415416798357,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-23 16:50:04 +03:00
|
|
|
[("October", -0.8472978603872037),
|
|
|
|
("month", -0.8472978603872037)],
|
|
|
|
n = 2}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<time-of-day> - <time-of-day> (interval)",
|
|
|
|
Classifier{okData =
|
2017-04-06 20:50:34 +03:00
|
|
|
ClassData{prior = -0.8873031950009028,
|
2017-03-08 21:33:55 +03:00
|
|
|
unseen = -3.7376696182833684,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("minuteminute", -1.5163474893680884),
|
|
|
|
("hh:mmhh:mm", -1.5163474893680884),
|
|
|
|
("<time-of-day> am|pmtime-of-day (latent)", -2.327277705584417),
|
|
|
|
("hourhour", -1.7676619176489945),
|
|
|
|
("<time-of-day> am|pm<time-of-day> am|pm", -2.327277705584417)],
|
|
|
|
n = 14},
|
|
|
|
koData =
|
2017-04-06 20:50:34 +03:00
|
|
|
ClassData{prior = -0.5306282510621704,
|
|
|
|
unseen = -3.9889840465642745,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("about|exactly <time-of-day>time-of-day (latent)",
|
2017-04-06 20:50:34 +03:00
|
|
|
-3.2771447329921766),
|
|
|
|
("hh:mmtime-of-day (latent)", -1.5723966407537513),
|
|
|
|
("hh:mm<time-of-day> am|pm", -2.871679624884012),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<time-of-day> am|pmtime-of-day (latent)",
|
2017-04-06 20:50:34 +03:00
|
|
|
-3.2771447329921766),
|
|
|
|
("at <time-of-day><time-of-day> am|pm", -3.2771447329921766),
|
|
|
|
("hourhour", -2.0243817644968085),
|
|
|
|
("minutehour", -1.262241712449912),
|
2017-03-08 21:33:55 +03:00
|
|
|
("about|exactly <time-of-day><time-of-day> am|pm",
|
2017-04-06 20:50:34 +03:00
|
|
|
-3.2771447329921766),
|
|
|
|
("at <time-of-day>time-of-day (latent)", -2.871679624884012),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<integer> to|till|before <hour-of-day>time-of-day (latent)",
|
2017-04-06 20:50:34 +03:00
|
|
|
-2.871679624884012)],
|
|
|
|
n = 20}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("nth <time> after <time>",
|
|
|
|
Classifier{okData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.6931471805599453, unseen = -1.791759469228055,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("dayday", -0.916290731874155),
|
2017-03-08 21:33:55 +03:00
|
|
|
("ordinals (first..twentieth,thirtieth,...)Tuesdayintersect",
|
2017-03-14 14:50:10 +03:00
|
|
|
-0.916290731874155)],
|
|
|
|
n = 1},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.6931471805599453, unseen = -1.791759469228055,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("dayday", -0.916290731874155),
|
2017-03-08 21:33:55 +03:00
|
|
|
("ordinals (first..twentieth,thirtieth,...)TuesdayChristmas",
|
2017-03-14 14:50:10 +03:00
|
|
|
-0.916290731874155)],
|
2017-03-08 21:33:55 +03:00
|
|
|
n = 1}}),
|
|
|
|
("<named-month> <day-of-month> (non ordinal)",
|
|
|
|
Classifier{okData =
|
2017-06-27 22:21:14 +03:00
|
|
|
ClassData{prior = -0.2876820724517809,
|
2017-03-08 21:33:55 +03:00
|
|
|
unseen = -3.9318256327243257,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("Augustinteger (numeric)", -2.5257286443082556),
|
|
|
|
("Marchinteger (numeric)", -2.8134107167600364),
|
|
|
|
("Aprilinteger (numeric)", -3.2188758248682006),
|
|
|
|
("month", -0.8209805520698302),
|
|
|
|
("Februaryinteger (numeric)", -1.9661128563728327),
|
|
|
|
("Septemberinteger (numeric)", -2.8134107167600364),
|
|
|
|
("Octoberinteger (numeric)", -2.8134107167600364),
|
|
|
|
("Julyinteger (numeric)", -2.120263536200091)],
|
|
|
|
n = 21},
|
|
|
|
koData =
|
2017-06-27 22:21:14 +03:00
|
|
|
ClassData{prior = -1.3862943611198906,
|
|
|
|
unseen = -3.1354942159291497,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-27 22:21:14 +03:00
|
|
|
[("Marchinteger (numeric)", -2.3978952727983707),
|
|
|
|
("Aprilinteger (numeric)", -2.3978952727983707),
|
|
|
|
("month", -1.0116009116784799),
|
|
|
|
("Julyinteger (numeric)", -1.2992829841302609)],
|
|
|
|
n = 7}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("this|next <day-of-week>",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -2.995732273553991,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("Thursday", -2.2512917986064953),
|
|
|
|
("Wednesday", -2.2512917986064953),
|
|
|
|
("Monday", -1.845826690498331), ("day", -0.8649974374866046),
|
|
|
|
("Tuesday", -1.55814461804655)],
|
|
|
|
n = 7},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.791759469228055,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("ordinal (digits)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -3.1780538303479458,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 22},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("quarter (grain)",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -0.2876820724517809, unseen = -2.639057329615259,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 12},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -1.3862943611198906, unseen = -1.791759469228055,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 4}}),
|
|
|
|
("last <cycle> of <time>",
|
|
|
|
Classifier{okData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -2.9444389791664407,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("day (grain)October", -1.791759469228055),
|
|
|
|
("daymonth", -1.2809338454620642),
|
|
|
|
("day (grain)intersect", -1.791759469228055),
|
|
|
|
("weekmonth", -1.791759469228055),
|
|
|
|
("week (grain)intersect", -2.1972245773362196),
|
|
|
|
("week (grain)September", -2.1972245773362196)],
|
|
|
|
n = 6},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -infinity, unseen = -1.9459101490553135,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("seasons",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("<day-of-month>(ordinal) <named-month> year",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("ordinal (digits)April", -0.6931471805599453),
|
|
|
|
("month", -0.6931471805599453)],
|
|
|
|
n = 1},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("Labor Day",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = -0.2876820724517809,
|
|
|
|
unseen = -1.6094379124341003,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -1.3862943611198906,
|
|
|
|
unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1}}),
|
|
|
|
("week-end",
|
|
|
|
Classifier{okData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -1.5040773967762742,
|
2017-03-08 21:33:55 +03:00
|
|
|
unseen = -1.3862943611198906,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 2},
|
|
|
|
koData =
|
2017-06-23 16:50:04 +03:00
|
|
|
ClassData{prior = -0.25131442828090605,
|
|
|
|
unseen = -2.1972245773362196,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 7}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("after <time-of-day>",
|
|
|
|
Classifier{okData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -1.6094379124341003,
|
|
|
|
unseen = -2.4849066497880004,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("time-of-day (latent)", -1.7047480922384253),
|
|
|
|
("<time-of-day> am|pm", -1.7047480922384253),
|
|
|
|
("hour", -1.2992829841302609)],
|
2017-03-08 21:33:55 +03:00
|
|
|
n = 2},
|
|
|
|
koData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.2231435513142097,
|
|
|
|
unseen = -3.1780538303479458,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("intersect", -2.03688192726104),
|
|
|
|
("tomorrow", -2.03688192726104), ("day", -1.3437347467010947),
|
|
|
|
("time-of-day (latent)", -2.4423470353692043),
|
|
|
|
("<time-of-day> am|pm", -2.4423470353692043),
|
|
|
|
("Christmas", -2.03688192726104), ("hour", -1.749199854809259)],
|
|
|
|
n = 8}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("day (grain)",
|
|
|
|
Classifier{okData =
|
2017-07-26 21:30:14 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -3.1780538303479458,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 22},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("right now",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 3},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("between <time> and <time>",
|
|
|
|
Classifier{okData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -1.0986122886681098,
|
|
|
|
unseen = -2.4849066497880004,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("minuteminute", -1.0116009116784799),
|
|
|
|
("hh:mmhh:mm", -1.0116009116784799)],
|
2017-03-08 21:33:55 +03:00
|
|
|
n = 3},
|
|
|
|
koData =
|
2017-03-14 14:50:10 +03:00
|
|
|
ClassData{prior = -0.40546510810816444,
|
|
|
|
unseen = -2.890371757896165,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-03-14 14:50:10 +03:00
|
|
|
[("hh:mmtime-of-day (latent)", -1.4469189829363254),
|
|
|
|
("minuteminute", -1.4469189829363254),
|
|
|
|
("minutehour", -1.4469189829363254),
|
|
|
|
("hh:mmintersect", -1.4469189829363254)],
|
|
|
|
n = 6}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("<month> dd-dd (interval)",
|
|
|
|
Classifier{okData =
|
2017-06-27 22:21:14 +03:00
|
|
|
ClassData{prior = 0.0, unseen = -2.5649493574615367,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("July", -0.6931471805599453), ("month", -0.6931471805599453)],
|
2017-06-27 22:21:14 +03:00
|
|
|
n = 5},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}}),
|
|
|
|
("part of days",
|
|
|
|
Classifier{okData =
|
2017-06-09 19:21:03 +03:00
|
|
|
ClassData{prior = -4.0821994520255166e-2,
|
|
|
|
unseen = -3.258096538021482,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 24},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-06-09 19:21:03 +03:00
|
|
|
ClassData{prior = -3.2188758248682006,
|
2017-03-08 21:33:55 +03:00
|
|
|
unseen = -1.0986122886681098,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 1}}),
|
|
|
|
("this <time>",
|
|
|
|
Classifier{okData =
|
2017-06-22 13:39:45 +03:00
|
|
|
ClassData{prior = -0.10536051565782628,
|
|
|
|
unseen = -3.332204510175204,
|
2017-03-08 21:33:55 +03:00
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
2017-06-22 00:41:33 +03:00
|
|
|
[("Thursday", -2.6026896854443837),
|
|
|
|
("Martin Luther King's Day", -2.6026896854443837),
|
|
|
|
("intersect", -2.6026896854443837),
|
|
|
|
("Monday", -2.6026896854443837), ("day", -1.2163953243244932),
|
|
|
|
("Thanksgiving Day", -2.6026896854443837),
|
|
|
|
("hour", -2.1972245773362196), ("seasons", -1.9095425048844386),
|
|
|
|
("week-end", -2.6026896854443837)],
|
|
|
|
n = 9},
|
2017-03-08 21:33:55 +03:00
|
|
|
koData =
|
2017-06-22 13:39:45 +03:00
|
|
|
ClassData{prior = -2.3025850929940455,
|
|
|
|
unseen = -2.4849066497880004,
|
|
|
|
likelihoods =
|
|
|
|
HashMap.fromList
|
|
|
|
[("intersect", -1.7047480922384253),
|
|
|
|
("day", -1.7047480922384253)],
|
|
|
|
n = 1}}),
|
2017-03-08 21:33:55 +03:00
|
|
|
("August",
|
|
|
|
Classifier{okData =
|
|
|
|
ClassData{prior = 0.0, unseen = -1.6094379124341003,
|
|
|
|
likelihoods = HashMap.fromList [("", 0.0)], n = 3},
|
|
|
|
koData =
|
|
|
|
ClassData{prior = -infinity, unseen = -0.6931471805599453,
|
|
|
|
likelihoods = HashMap.fromList [], n = 0}})]
|