@langchain/langgraph-api 1.0.3 → 1.1.0

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/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # @langchain/langgraph-api
2
2
 
3
+ ## 1.1.0
4
+
5
+ ### Patch Changes
6
+
7
+ - @langchain/langgraph-ui@1.1.0
8
+
9
+ ## 1.0.4
10
+
11
+ ### Patch Changes
12
+
13
+ - b9be526: Adding functionality to search assistants by name in the in-memory server implementation.
14
+ - @langchain/langgraph-ui@1.0.4
15
+
3
16
  ## 1.0.3
4
17
 
5
18
  ### Patch Changes
package/README.md CHANGED
@@ -1,3 +1,9 @@
1
1
  # LangGraph.js API
2
2
 
3
3
  In-memory implementation of the LangGraph.js API.
4
+
5
+ ## Tests
6
+
7
+ 1. Build the latest code changes to test: `yarn build`
8
+ 1. Start a local server: `yarn dev`
9
+ 1. Run the tests: `yarn test`
@@ -51,6 +51,7 @@ api.post("/assistants/search", zValidator("json", schemas.AssistantSearchRequest
51
51
  let total = 0;
52
52
  for await (const item of assistants().search({
53
53
  graph_id: payload.graph_id,
54
+ name: payload.name,
54
55
  metadata: payload.metadata,
55
56
  limit: payload.limit ?? 10,
56
57
  offset: payload.offset ?? 0,
@@ -14,7 +14,7 @@ export async function spawnServer(args, context, options) {
14
14
  - 🎨 Studio UI: \x1b[36m${studioUrl}\x1b[0m
15
15
 
16
16
  This in-memory server is designed for development and testing.
17
- For production use, please use LangGraph Cloud.
17
+ For production use, please use LangSmith Deployment.
18
18
 
19
19
  `);
20
20
  return spawn(process.execPath, [
@@ -1078,6 +1078,7 @@ export declare const SearchResult: z.ZodObject<{
1078
1078
  export declare const AssistantSearchRequest: z.ZodObject<{
1079
1079
  metadata: z.ZodOptional<z.ZodObject<{}, "strip", z.ZodAny, z.objectOutputType<{}, z.ZodAny, "strip">, z.objectInputType<{}, z.ZodAny, "strip">>>;
1080
1080
  graph_id: z.ZodOptional<z.ZodString>;
1081
+ name: z.ZodOptional<z.ZodString>;
1081
1082
  limit: z.ZodOptional<z.ZodNumber>;
1082
1083
  offset: z.ZodOptional<z.ZodNumber>;
1083
1084
  sort_by: z.ZodOptional<z.ZodEnum<["assistant_id", "graph_id", "created_at", "updated_at", "name"]>>;
@@ -1085,6 +1086,7 @@ export declare const AssistantSearchRequest: z.ZodObject<{
1085
1086
  select: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1086
1087
  }, "strip", z.ZodTypeAny, {
1087
1088
  graph_id?: string | undefined;
1089
+ name?: string | undefined;
1088
1090
  metadata?: z.objectOutputType<{}, z.ZodAny, "strip"> | undefined;
1089
1091
  limit?: number | undefined;
1090
1092
  offset?: number | undefined;
@@ -1093,6 +1095,7 @@ export declare const AssistantSearchRequest: z.ZodObject<{
1093
1095
  select?: string[] | undefined;
1094
1096
  }, {
1095
1097
  graph_id?: string | undefined;
1098
+ name?: string | undefined;
1096
1099
  metadata?: z.objectInputType<{}, z.ZodAny, "strip"> | undefined;
1097
1100
  limit?: number | undefined;
1098
1101
  offset?: number | undefined;
package/dist/schemas.mjs CHANGED
@@ -261,6 +261,10 @@ export const AssistantSearchRequest = z
261
261
  .describe("Metadata to search for.")
262
262
  .optional(),
263
263
  graph_id: z.string().describe("Filter by graph ID.").optional(),
264
+ name: z
265
+ .string()
266
+ .describe("Filter by name. The filtering logic will match assistants where 'name' is a substring (case insensitive) of the assistant name.")
267
+ .optional(),
264
268
  limit: z
265
269
  .number()
266
270
  .int()
@@ -51,6 +51,7 @@ export declare class FileSystemAssistants implements AssistantsRepo {
51
51
  constructor(conn: FileSystemPersistence<Store>);
52
52
  search(options: {
53
53
  graph_id?: string;
54
+ name?: string;
54
55
  metadata?: Metadata;
55
56
  limit: number;
56
57
  offset: number;
@@ -171,6 +171,12 @@ export class FileSystemAssistants {
171
171
  assistant["graph_id"] !== options.graph_id) {
172
172
  return false;
173
173
  }
174
+ if (options.name != null &&
175
+ !assistant["name"]
176
+ .toLowerCase()
177
+ .includes(options.name.toLowerCase())) {
178
+ return false;
179
+ }
174
180
  if (options.metadata != null &&
175
181
  !isJsonbContained(assistant["metadata"], options.metadata)) {
176
182
  return false;
@@ -245,6 +245,7 @@ export interface ThreadsStateRepo {
245
245
  export interface AssistantsRepo {
246
246
  search(options: {
247
247
  graph_id?: string;
248
+ name?: string;
248
249
  metadata?: Metadata;
249
250
  limit: number;
250
251
  offset: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@langchain/langgraph-api",
3
- "version": "1.0.3",
3
+ "version": "1.1.0",
4
4
  "type": "module",
5
5
  "engines": {
6
6
  "node": "^18.19.0 || >=20.16.0"
@@ -64,7 +64,7 @@
64
64
  "@babel/code-frame": "^7.26.2",
65
65
  "@hono/node-server": "^1.12.0",
66
66
  "@hono/zod-validator": "^0.2.2",
67
- "@langchain/langgraph-ui": "1.0.3",
67
+ "@langchain/langgraph-ui": "1.1.0",
68
68
  "@types/json-schema": "^7.0.15",
69
69
  "@typescript/vfs": "^1.6.0",
70
70
  "dedent": "^1.5.3",
@@ -96,9 +96,9 @@
96
96
  },
97
97
  "devDependencies": {
98
98
  "@langchain/core": "^1.0.0",
99
- "@langchain/langgraph": "1.0.1",
99
+ "@langchain/langgraph": "1.0.2",
100
100
  "@langchain/langgraph-checkpoint": "1.0.0",
101
- "@langchain/langgraph-sdk": "1.0.0",
101
+ "@langchain/langgraph-sdk": "1.0.3",
102
102
  "@types/babel__code-frame": "^7.0.6",
103
103
  "@types/node": "^18.15.11",
104
104
  "@types/react": "^19.0.8",
@@ -109,7 +109,7 @@
109
109
  "postgres": "^3.4.5",
110
110
  "prettier": "^2.8.3",
111
111
  "typescript": "^4.9.5 || ^5.4.5",
112
- "vitest": "^3.1.2",
112
+ "vitest": "^3.2.4",
113
113
  "wait-port": "^1.1.0"
114
114
  }
115
115
  }