2025-03-06 20:04:55 -08:00
|
|
|
import { Annotation } from "@langchain/langgraph";
|
|
|
|
|
import { GenerativeUIAnnotation } from "../types";
|
|
|
|
|
|
|
|
|
|
export const OpenCodeAnnotation = Annotation.Root({
|
|
|
|
|
messages: GenerativeUIAnnotation.spec.messages,
|
|
|
|
|
ui: GenerativeUIAnnotation.spec.ui,
|
|
|
|
|
timestamp: GenerativeUIAnnotation.spec.timestamp,
|
2025-03-06 20:12:47 -08:00
|
|
|
next: Annotation<"executor" | "interrupt">
|
2025-03-06 20:04:55 -08:00
|
|
|
});
|
|
|
|
|
|
|
|
|
|
export type OpenCodeState = typeof OpenCodeAnnotation.State;
|
|
|
|
|
export type OpenCodeUpdate = typeof OpenCodeAnnotation.Update;
|