feat: Basic trip planner agent

This commit is contained in:
bracesproul
2025-03-03 16:51:46 -08:00
parent 5256efb23f
commit da396ac83e
22 changed files with 471 additions and 13 deletions

View File

@@ -0,0 +1,18 @@
import { Annotation } from "@langchain/langgraph";
import { GenerativeUIAnnotation } from "../types";
export type TripDetails = {
location: string;
startDate: Date;
endDate: Date;
numberOfGuests: number;
};
export const TripPlannerAnnotation = Annotation.Root({
messages: GenerativeUIAnnotation.spec.messages,
ui: GenerativeUIAnnotation.spec.ui,
timestamp: GenerativeUIAnnotation.spec.timestamp,
tripDetails: Annotation<TripDetails | undefined>(),
});
export type TripPlannerState = typeof TripPlannerAnnotation.State;