fix(schedule): route daily set-remind phrases through ITL with recurrence
Memind CI / Test, build, and release guards (push) Failing after 3m4s
Memind CI / Test, build, and release guards (push) Failing after 3m4s
Support colloquial forms like「设置每天18:00提醒打卡」, persist daily metadata on commit, and schedule the next reminder after each delivery. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -144,6 +144,25 @@ test('ASR spaced colon routes to ITL timed reminder not agent', () => {
|
||||
assert.equal(result.layer, 'L1');
|
||||
});
|
||||
|
||||
test('parses daily reminder with time between set and remind words', () => {
|
||||
const now = Date.UTC(2026, 7, 24, 9, 0, 0); // 2026-08-24 17:00 Asia/Shanghai
|
||||
const intent = parseScheduleIntent('设置每天18:00提醒打卡', {
|
||||
timezone: 'Asia/Shanghai',
|
||||
now,
|
||||
});
|
||||
assert.equal(intent.action, 'create_timed_reminder');
|
||||
assert.equal(intent.title, '打卡');
|
||||
assert.equal(intent.recurrence, 'daily');
|
||||
assert.equal(intent.hour, 18);
|
||||
assert.equal(intent.minute, 0);
|
||||
});
|
||||
|
||||
test('daily set-remind phrase routes to ITL timed reminder', () => {
|
||||
const result = classifyUserIntent('设置每天18:00提醒打卡');
|
||||
assert.equal(result.kind, 'timed_reminder');
|
||||
assert.equal(result.detail.recurrence, 'daily');
|
||||
});
|
||||
|
||||
test('parses direct reminder setup phrase from wechat', () => {
|
||||
const now = Date.UTC(2026, 7, 24, 4, 0, 0); // 2026-08-24 12:00 Asia/Shanghai
|
||||
const intent = parseScheduleIntent('帮我设置提醒,下午 14:30 分开会,项目计划例会', {
|
||||
|
||||
Reference in New Issue
Block a user