Are you happy with your logging solution? Would you help us out by taking a 30-second survey? Click here

duckling

Deprecated in favor of https://github.com/facebook/duckling

Subscribe to updates I use duckling


Statistics on duckling

Number of watchers on Github 1283
Number of open issues 68
Average time to close an issue 18 days
Main language Clojure
Average time to merge a PR 6 days
Open pull requests 45+
Closed pull requests 20+
Last commit about 2 years ago
Repo Created over 5 years ago
Repo Last Updated over 1 year ago
Size 1.6 MB
Homepage https://duckling....
Organization / Authorwit-ai
Contributors20
Page Updated
Do you use duckling? Leave a review!
View open issues (68)
View duckling activity
View on github
Fresh, new opensource launches πŸš€πŸš€πŸš€
Trendy new open source projects in your inbox! View examples

Subscribe to our mailing list

Evaluating duckling for your project? Score Explanation
Commits Score (?)
Issues & PR Score (?)

Deprecation notice

As of May 1st, 2017 we're deprecating this repository in favor of the new Duckling. See our blog post announcement.

Thanks to all the contributors!

Duckling

Clojars Project

Duckling is a Clojure library that parses text into structured data:

the first Tuesday of October => {:value "2014-10-07T00:00:00.000-07:00"
                                   :grain :day}

You can try it out at https://duckling.wit.ai

See our blog post announcement for more context.

Getting started

To use Duckling in your project, you just need two functions: load! to load the default configuration, and parse to parse a string.

(ns myproject.core
  (:require [duckling.core :as p]))

(p/load!) ;; Load all languages

(p/parse :en$core ;; core configuration for English ; see also :fr$core, :es$core, :zh$core
         "wake me up the last Monday of January 2015 at 6am"
         [:time]) ;; We are interested in :time expressions only ; see also :duration, :temperature, etc.

;; => [{:label :time
;;        :start 15
;;        :end 49
;;        :value {:type "value", :value "2015-01-26T06:00:00.000-02:00", :grain :hour}
;;        :body "last Monday of January 2015 at 6am"}]

See the documentation for more information.

duckling open issues Ask a question     (View All Issues)
  • almost 3 years Java API
  • almost 3 years French number issue with timezone using sentences with 'et' (translation: 'and')
  • almost 3 years Korean support
  • almost 3 years duckling is too aggressive in parsing numbers to years
  • almost 3 years "afternoon thursday" parsed differently than "thursday afternoon"
  • almost 3 years IllegalFieldValueException due to daylight savings time?
  • almost 3 years [Portuguese] - keywords "prΓ³ximo" and "que vem" not interpreted
  • almost 3 years Tomorrow after [TIME] example : tomorrow after lunch
  • almost 3 years DateTime Wit understands 26 as 1/1/2026 whereas 26th as 10/26/2016
  • almost 3 years support for recognizing date time entities coming by default and from the user text
  • almost 3 years recognition of multiple date formats
  • almost 3 years Parsing breakfast/lunch/dinner to datetime
  • about 3 years Incorrectly matches "the end of <time>"
  • about 3 years return date values as either some instance of Date object (joda, raw java etc) or posix date
  • about 3 years [english] do this in 2 minutes
  • about 3 years CI checks failing
  • over 3 years Thai number not found
  • over 3 years Portuguese: "antes das 18", "depois das 15"
  • over 3 years Define a constraint between two datetime entities
  • over 3 years from and to issues
  • over 3 years issue understanding multiple dates
  • over 3 years problem understanding abbreviations
  • over 3 years Date issue
  • over 3 years Loading time and classifier persistence
  • over 3 years Decimals beyond tenth position`
  • over 3 years Defining new corpus/rules
  • almost 4 years "on monday afternoon at 230"
  • almost 4 years Wit.ai assumes future date if year not mentioned in query string
  • almost 4 years Support recurrence expressions
  • almost 4 years ArithmeticException occurs when parsing long durations
duckling open pull requests (View All Pulls)
  • add numbers in Portuguese
  • Fix matching of day 0 and month 0
  • Russian numbers (ordinal)
  • fixed #83
  • Portuguese: #98, #101, Holidays
  • Chinese: add 'nth <time> of <time>' rules
  • Italian: add new ordinal number
  • Russian numbers new
  • Irish (not ready to merge)
  • Polish date/time
  • Extend new language - Thai language. But there is some pattern to fix.
  • fix reflection
  • feat(): add some ITA numbers and ordinals
  • Fix language comments :cn$core --> :zh$core
  • Do not print to stderr
  • Fix bug in named integer (0..19)
  • fixed typo
  • Extend new language : Indonesian but need more fix
  • Various fixes in FR
  • typo cn$core ==> zh$core
  • add new Myanmar (my) language resource for numbers.
  • Add swedish language
  • Added slang words for year and quarter
  • Arabic corpus (numbers and ordinals forms)
  • Add french end of month and mid(morning|day|afternoon)
  • pl numbers
  • Added saudi,qatar,kuwaiti currency
  • Fix/de hhmm range
  • Fix/de mm dd
  • Expressions like "ein Hotel" or "ein Angebot" in German are not 1h
  • Turkish support (numbers only)
  • Fixed some italian forms and holidays
  • [FR|EN] Add early in the morning
  • [FR] Fix issue #172 (timezone conflict)
  • RO language
  • Fix DuplicateFormatFlagsException when max-iter-reached exceeded
  • More italian fixes
  • Italian communications + EN url regex improvement
  • [PT] Removing unnecessary prefix in some cycle rules (#161)
  • adding italian new time entities
  • Bug fix: finest grain not used in interval
  • [EN] More natural disambiguation of intervals
  • [PT] Adds contractions of preposition 'desse' and 'deste' (of this) as current moment
  • Updated Swedish time rules
  • Added dutch language to the time elements and modified the time eleme…
duckling list of languages used
Other projects in Clojure