You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is it possible to use amotoen to parse non-strings?
For example, I may want to have a tokenizer, which splits an input text (natural language) into a seq of tokens (record instances). Now I would like to recognize patterns in those token seqs.
Example:
"Date is 27.03.2008. It will cost 15$."
This gets tokenized to
Now I may wish to replace the "27", ".", "03", ".", "2008" token seq with one single token {:value #<java.util.Date 2008-03-12] :type :date}.
And the "15", "$" should become a token {:value 15 :type :amount :currency :dollar}.
I would like to describe a grammar that describes how dates look. A grammar how amounts of money look, etc.
The input wouldn’t be Strings, but sequences of my (defrecord Token […]).
Can amotoen currently do that? Would it be difficult to extend it?
The text was updated successfully, but these errors were encountered:
Is it possible to use amotoen to parse non-strings?
For example, I may want to have a tokenizer, which splits an input text (natural language) into a seq of tokens (record instances). Now I would like to recognize patterns in those token seqs.
Example:
"Date is 27.03.2008. It will cost 15$."
This gets tokenized to
Now I may wish to replace the "27", ".", "03", ".", "2008" token seq with one single token
{:value #<java.util.Date 2008-03-12] :type :date}
.And the "15", "$" should become a token
{:value 15 :type :amount :currency :dollar}
.I would like to describe a grammar that describes how dates look. A grammar how amounts of money look, etc.
The input wouldn’t be Strings, but sequences of my
(defrecord Token […])
.Can amotoen currently do that? Would it be difficult to extend it?
The text was updated successfully, but these errors were encountered: