Year extraction not parsed correctly
- Dominant language
- Haskell
- Stars
- 4.3k
- Forks
- 740
- PR merge metrics
- No merged PRs in 30d
Description
Is there a way to check and ignore numerals that have text surrounding them? For example in "from 10 - 16:00 in 650EK" parses 650 as a year -
```
[
{
"body" : "from 10 - 16:00 in 650",
"dim" : "time",
"end" : 22,
"latent" : false,
"start" : 0,
"value" : {
"from" : {
"grain" : "minute",
"value" : "0650-01-01T00:00:00.000-08:00"
},
"to" : {
"grain" : "minute",
"value" : "0650-01-01T16:00:00.000-08:00"
},
"type" : "interval",
"values" : [
{
"from" : {
"grain" : "minute",
"value" : "0650-01-01T00:00:00.000-08:00"
},
"to" : {
"grain" : "minute",
"value" : "0650-01-01T16:00:00.000-08:00"
},
"type" : "interval"
},
{
"from" : {
"grain" : "minute",
"value" : "0650-01-01T10:00:00.000-08:00"
},
"to" : {
"grain" : "minute",
"value" : "0650-01-01T16:00:00.000-08:00"
},
"type" : "interval"
},
{
"from" : {
"grain" : "minute",
"value" : "0650-01-01T22:00:00.000-08:00"
},
"to" : {
"grain" : "minute",
"value" : "0650-01-02T16:00:00.000-08:00"
},
"type" : "interval"
}
]
}
}
]
```
I do not however want 650 to be parsed as a year.
Contributor guide
Research direction
Reproduce the reported input "from 10 - 16:00 in 650EK" and inspect the year-extraction path that recognizes 650 as a year. Done means numerals surrounded by text such as 650EK are ignored as years while valid year extraction continues to work.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- haskell
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100