feat(bot): move ad hoc notifications to llm parsing

This commit is contained in:
2026-03-24 02:39:22 +04:00
parent 3507bc0522
commit fedc4a4325
9 changed files with 1428 additions and 482 deletions

View File

@@ -15,7 +15,7 @@ function dueNotification(
creatorMemberId: input.creatorMemberId ?? 'creator',
assigneeMemberId: input.assigneeMemberId ?? 'assignee',
originalRequestText: 'raw',
notificationText: input.notificationText ?? 'Ping Georgiy',
notificationText: input.notificationText ?? 'Georgiy, time to call already.',
timezone: input.timezone ?? 'Asia/Tbilisi',
scheduledFor: input.scheduledFor ?? Temporal.Instant.from('2026-03-23T09:00:00Z'),
timePrecision: input.timePrecision ?? 'exact',
@@ -108,7 +108,7 @@ describe('createAdHocNotificationJobsHandler', () => {
expect(payload.ok).toBe(true)
expect(payload.notifications[0]?.outcome).toBe('sent')
expect(sentTopicMessages[0]).toContain('tg://user?id=222')
expect(sentTopicMessages[0]).toContain('Georgiy, time to call already.')
expect(sentNotifications).toEqual(['notif-1'])
})
})