Time_NLP
Time_NLP copied to clipboard
weeks(下周五)无法识别

安装 arrow==0.14.0 解决
我是macOS系统,安装的arrow是0.14.6,没有找到0.14.0的版本,请问能麻烦给一下0.14.0的安装包吗? 谢谢
在 2019-08-31 21:44:41,"Artin" [email protected] 写道:
安装 arrow==0.14.0 解决
— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub, or mute the thread.
pip install arrow==0.14.0
就可以了呀
新版的 arrow 把 replace 方法中的复数形式都改为了 shift.
兼容了最新版的包 >=0.15 https://github.com/BuddingLab/time_converter
换一个工具,JioNLP
import jionlp as jio
import time
text = '下周五'
print(jio.parse_time(text, time_base=time.time()))
# {'type': 'time_point', 'definition': 'accurate', 'time': ['2021-08-06 00:00:00', '2021-08-06 23:59:59']}