extend chat model with CRUD actions for event changes
- Add ProposedEventChange type with create/update/delete actions - Replace proposedEvent with proposedChange in ChatMessage - Add currentDate to AIContext for time-aware AI responses - Add AI test endpoint for development (/api/ai/test) - Fix MongoUserRepository type safety with explicit toUser mapping - Update CLAUDE.md documentation
This commit is contained in:
@@ -1,14 +1,15 @@
|
||||
import { CalendarEvent, ChatMessage, CreateEventDTO } from '@caldav/shared';
|
||||
import { CalendarEvent, ChatMessage, ProposedEventChange } from '@caldav/shared';
|
||||
|
||||
export interface AIContext {
|
||||
userId: string;
|
||||
conversationHistory: ChatMessage[];
|
||||
existingEvents: CalendarEvent[];
|
||||
currentDate: Date;
|
||||
}
|
||||
|
||||
export interface AIResponse {
|
||||
content: string;
|
||||
proposedEvent?: CreateEventDTO;
|
||||
proposedChange?: ProposedEventChange;
|
||||
}
|
||||
|
||||
export interface AIProvider {
|
||||
|
||||
Reference in New Issue
Block a user