@langchain/langgraph-cli 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/api/threads.mjs
CHANGED
|
@@ -44,13 +44,15 @@ api.get("/threads/:thread_id/state", zValidator("param", z.object({ thread_id: z
|
|
|
44
44
|
return jsonExtra(c, state);
|
|
45
45
|
});
|
|
46
46
|
api.post("/threads/:thread_id/state", zValidator("param", z.object({ thread_id: z.string().uuid() })), zValidator("json", z.object({
|
|
47
|
-
values: z
|
|
47
|
+
values: z
|
|
48
|
+
.union([
|
|
48
49
|
z.record(z.string(), z.unknown()),
|
|
49
50
|
z.array(z.record(z.string(), z.unknown())),
|
|
50
|
-
])
|
|
51
|
+
])
|
|
52
|
+
.nullish(),
|
|
51
53
|
as_node: z.string().optional(),
|
|
52
54
|
checkpoint_id: z.string().optional(),
|
|
53
|
-
checkpoint:
|
|
55
|
+
checkpoint: schemas.CheckpointSchema.nullish(),
|
|
54
56
|
})), async (c) => {
|
|
55
57
|
// Update Thread State
|
|
56
58
|
const { thread_id } = c.req.valid("param");
|
|
@@ -76,11 +78,7 @@ api.get("/threads/:thread_id/state/:checkpoint_id", zValidator("param", z.object
|
|
|
76
78
|
});
|
|
77
79
|
api.post("/threads/:thread_id/state/checkpoint", zValidator("param", z.object({ thread_id: z.string().uuid() })), zValidator("json", z.object({
|
|
78
80
|
subgraphs: schemas.coercedBoolean.optional(),
|
|
79
|
-
checkpoint:
|
|
80
|
-
checkpoint_id: z.string().uuid().optional(),
|
|
81
|
-
checkpoint_ns: z.string().optional(),
|
|
82
|
-
checkpoint_map: z.record(z.string(), z.unknown()).optional(),
|
|
83
|
-
}),
|
|
81
|
+
checkpoint: schemas.CheckpointSchema.nullish(),
|
|
84
82
|
})), async (c) => {
|
|
85
83
|
// Get Thread State At Checkpoint Post
|
|
86
84
|
const { thread_id } = c.req.valid("param");
|
|
@@ -17,6 +17,8 @@ const isTracingEnabled = () => {
|
|
|
17
17
|
return value === "true";
|
|
18
18
|
};
|
|
19
19
|
const options = StartServerSchema.parse(JSON.parse(payload));
|
|
20
|
+
// Export PORT to the environment
|
|
21
|
+
process.env.PORT = options.port.toString();
|
|
20
22
|
const [{ host, cleanup }, organizationId] = await Promise.all([
|
|
21
23
|
startServer(options),
|
|
22
24
|
(async () => {
|
package/dist/schemas.mjs
CHANGED
|
@@ -67,7 +67,7 @@ export const Cron = z.object({
|
|
|
67
67
|
payload: z.object({}).catchall(z.any()),
|
|
68
68
|
});
|
|
69
69
|
export const CheckpointSchema = z.object({
|
|
70
|
-
checkpoint_id: z.string(),
|
|
70
|
+
checkpoint_id: z.string().uuid().optional(),
|
|
71
71
|
checkpoint_ns: z.string().nullish(),
|
|
72
72
|
checkpoint_map: z.record(z.unknown()).nullish(),
|
|
73
73
|
});
|