@deepagents/agent 5.0.0 → 6.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.
@@ -2,94 +2,32 @@ import { z } from 'zod';
2
2
  declare const PlanningResponseSchema: z.ZodObject<{
3
3
  reasoning: z.ZodString;
4
4
  plan: z.ZodObject<{
5
- steps: z.ZodArray<z.ZodString, "many">;
6
- estimated_complexity: z.ZodEnum<["low", "medium", "high"]>;
7
- }, "strip", z.ZodTypeAny, {
8
- steps: string[];
9
- estimated_complexity: "low" | "medium" | "high";
10
- }, {
11
- steps: string[];
12
- estimated_complexity: "low" | "medium" | "high";
13
- }>;
14
- }, "strip", z.ZodTypeAny, {
15
- reasoning: string;
16
- plan: {
17
- steps: string[];
18
- estimated_complexity: "low" | "medium" | "high";
19
- };
20
- }, {
21
- reasoning: string;
22
- plan: {
23
- steps: string[];
24
- estimated_complexity: "low" | "medium" | "high";
25
- };
26
- }>;
5
+ steps: z.ZodArray<z.ZodString>;
6
+ estimated_complexity: z.ZodEnum<{
7
+ low: "low";
8
+ medium: "medium";
9
+ high: "high";
10
+ }>;
11
+ }, z.core.$strip>;
12
+ }, z.core.$strip>;
27
13
  declare const ExecutionResultSchema: z.ZodObject<{
28
14
  reasoning: z.ZodString;
29
15
  action_taken: z.ZodString;
30
16
  result: z.ZodString;
31
17
  success: z.ZodBoolean;
32
- }, "strip", z.ZodTypeAny, {
33
- reasoning: string;
34
- success: boolean;
35
- action_taken: string;
36
- result: string;
37
- }, {
38
- reasoning: string;
39
- success: boolean;
40
- action_taken: string;
41
- result: string;
42
- }>;
18
+ }, z.core.$strip>;
43
19
  declare const ReplanningDecisionSchema: z.ZodObject<{
44
20
  reasoning: z.ZodString;
45
- decision: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
21
+ decision: z.ZodDiscriminatedUnion<[z.ZodObject<{
46
22
  type: z.ZodLiteral<"continue">;
47
- updated_plan: z.ZodArray<z.ZodString, "many">;
23
+ updated_plan: z.ZodArray<z.ZodString>;
48
24
  notes: z.ZodOptional<z.ZodString>;
49
- }, "strip", z.ZodTypeAny, {
50
- type: "continue";
51
- updated_plan: string[];
52
- notes?: string | undefined;
53
- }, {
54
- type: "continue";
55
- updated_plan: string[];
56
- notes?: string | undefined;
57
- }>, z.ZodObject<{
25
+ }, z.core.$strip>, z.ZodObject<{
58
26
  type: z.ZodLiteral<"complete">;
59
27
  final_answer: z.ZodString;
60
28
  summary: z.ZodString;
61
- }, "strip", z.ZodTypeAny, {
62
- type: "complete";
63
- summary: string;
64
- final_answer: string;
65
- }, {
66
- type: "complete";
67
- summary: string;
68
- final_answer: string;
69
- }>]>;
70
- }, "strip", z.ZodTypeAny, {
71
- reasoning: string;
72
- decision: {
73
- type: "continue";
74
- updated_plan: string[];
75
- notes?: string | undefined;
76
- } | {
77
- type: "complete";
78
- summary: string;
79
- final_answer: string;
80
- };
81
- }, {
82
- reasoning: string;
83
- decision: {
84
- type: "continue";
85
- updated_plan: string[];
86
- notes?: string | undefined;
87
- } | {
88
- type: "complete";
89
- summary: string;
90
- final_answer: string;
91
- };
92
- }>;
29
+ }, z.core.$strip>], "type">;
30
+ }, z.core.$strip>;
93
31
  export type PlanningResponse = z.infer<typeof PlanningResponseSchema>;
94
32
  export type ExecutionResult = z.infer<typeof ExecutionResultSchema>;
95
33
  export type ReplanningDecision = z.infer<typeof ReplanningDecisionSchema>;
@@ -1 +1 @@
1
- {"version":3,"file":"plan_and_act.d.ts","sourceRoot":"","sources":["../../../../src/lib/patterns/plan_and_act/plan_and_act.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAUxB,QAAA,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;EAY1B,CAAC;AAGH,QAAA,MAAM,qBAAqB;;;;;;;;;;;;;;;EASzB,CAAC;AAGH,QAAA,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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M,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AACpE,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAG1E,MAAM,WAAW,eAAe;IAC9B,aAAa,EAAE,MAAM,CAAC;IACtB,WAAW,EAAE,MAAM,EAAE,CAAC;IACtB,gBAAgB,EAAE,KAAK,CAAC;QACtB,SAAS,EAAE,MAAM,CAAC;QAClB,IAAI,EAAE,MAAM,CAAC;QACb,SAAS,EAAE,eAAe,CAAC;QAC3B,QAAQ,EAAE,kBAAkB,CAAC;KAC9B,CAAC,CAAC;IACH,UAAU,EAAE,OAAO,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAgFD;;;GAGG;AACH,wBAAsB,aAAa,CACjC,KAAK,EAAE,MAAM,EACb,aAAa,SAAK,GACjB,OAAO,CAAC;IACT,IAAI,EAAE,gBAAgB,CAAC;IACvB,OAAO,EAAE,eAAe,CAAC,kBAAkB,CAAC,CAAC;IAC7C,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC,CAkJD"}
@@ -1,58 +1,26 @@
1
1
  import z from 'zod';
2
- declare const ToolNameSchema: z.ZodEnum<["web", "news", "images"]>;
2
+ declare const ToolNameSchema: z.ZodEnum<{
3
+ images: "images";
4
+ web: "web";
5
+ news: "news";
6
+ }>;
3
7
  export declare const RewooPlanSchema: z.ZodObject<{
4
8
  statements: z.ZodArray<z.ZodObject<{
5
9
  id: z.ZodString;
6
10
  content: z.ZodString;
7
- }, "strip", z.ZodTypeAny, {
8
- id: string;
9
- content: string;
10
- }, {
11
- id: string;
12
- content: string;
13
- }>, "many">;
11
+ }, z.core.$strip>>;
14
12
  tool_calls: z.ZodArray<z.ZodObject<{
15
13
  id: z.ZodString;
16
- tool: z.ZodEnum<["web", "news", "images"]>;
14
+ tool: z.ZodEnum<{
15
+ images: "images";
16
+ web: "web";
17
+ news: "news";
18
+ }>;
17
19
  input: z.ZodString;
18
- depends_on: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
19
- }, "strip", z.ZodTypeAny, {
20
- input: string;
21
- id: string;
22
- tool: "images" | "web" | "news";
23
- depends_on: string[];
24
- }, {
25
- input: string;
26
- id: string;
27
- tool: "images" | "web" | "news";
28
- depends_on?: string[] | undefined;
29
- }>, "many">;
20
+ depends_on: z.ZodDefault<z.ZodArray<z.ZodString>>;
21
+ }, z.core.$strip>>;
30
22
  notes: z.ZodOptional<z.ZodString>;
31
- }, "strip", z.ZodTypeAny, {
32
- statements: {
33
- id: string;
34
- content: string;
35
- }[];
36
- tool_calls: {
37
- input: string;
38
- id: string;
39
- tool: "images" | "web" | "news";
40
- depends_on: string[];
41
- }[];
42
- notes?: string | undefined;
43
- }, {
44
- statements: {
45
- id: string;
46
- content: string;
47
- }[];
48
- tool_calls: {
49
- input: string;
50
- id: string;
51
- tool: "images" | "web" | "news";
52
- depends_on?: string[] | undefined;
53
- }[];
54
- notes?: string | undefined;
55
- }>;
23
+ }, z.core.$strip>;
56
24
  export type RewooPlan = z.infer<typeof RewooPlanSchema>;
57
25
  export type Evidence = {
58
26
  id: string;
@@ -67,10 +35,10 @@ export declare const rewooPlanner: import("../../agent.ts").Agent<{
67
35
  content: string;
68
36
  }[];
69
37
  tool_calls: {
70
- input: string;
71
38
  id: string;
72
39
  tool: "images" | "web" | "news";
73
- depends_on?: string[] | undefined;
40
+ input: string;
41
+ depends_on: string[];
74
42
  }[];
75
43
  notes?: string | undefined;
76
44
  }, import("../../agent.ts").ContextVariables, import("../../agent.ts").ContextVariables>;
@@ -82,9 +50,9 @@ export declare function runRewoo(query: string): Promise<{
82
50
  content: string;
83
51
  }[];
84
52
  tool_calls: {
85
- input: string;
86
53
  id: string;
87
54
  tool: "images" | "web" | "news";
55
+ input: string;
88
56
  depends_on: string[];
89
57
  }[];
90
58
  notes?: string | undefined;
@@ -1 +1 @@
1
- {"version":3,"file":"rewoo.d.ts","sourceRoot":"","sources":["../../../../src/lib/patterns/rewoo/rewoo.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAC;AAcpB,QAAA,MAAM,cAAc,sCAAoC,CAAC;AAiBzD,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAa1B,CAAC;AAEH,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAExD,MAAM,MAAM,QAAQ,GAAG;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;IACrC,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,GAAG,CAAC,EAAE,OAAO,CAAC;CACf,CAAC;AASF,eAAO,MAAM,YAAY;;;;;;;;;;;;wFAoBvB,CAAC;AA+BH,eAAO,MAAM,WAAW,+HAgBtB,CAAC;AAMH,wBAAsB,QAAQ,CAAC,KAAK,EAAE,MAAM;;;;;;;;;;;;;;;;GAoC3C"}
1
+ {"version":3,"file":"rewoo.d.ts","sourceRoot":"","sources":["../../../../src/lib/patterns/rewoo/rewoo.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAC;AAcpB,QAAA,MAAM,cAAc;;;;EAAoC,CAAC;AAiBzD,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;iBAa1B,CAAC;AAEH,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAExD,MAAM,MAAM,QAAQ,GAAG;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;IACrC,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,GAAG,CAAC,EAAE,OAAO,CAAC;CACf,CAAC;AASF,eAAO,MAAM,YAAY;;;;;;;;;;;;wFAoBvB,CAAC;AA+BH,eAAO,MAAM,WAAW,+HAgBtB,CAAC;AAMH,wBAAsB,QAAQ,CAAC,KAAK,EAAE,MAAM;;;;;;;;;;;;;;;;GAoC3C"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@deepagents/agent",
3
- "version": "5.0.0",
3
+ "version": "6.1.0",
4
4
  "license": "MIT",
5
5
  "repository": {
6
6
  "type": "git",
@@ -33,22 +33,21 @@
33
33
  "access": "public"
34
34
  },
35
35
  "dependencies": {
36
- "@ai-sdk/groq": "^4.0.7",
37
- "@ai-sdk/openai": "^4.0.11",
38
- "@ai-sdk/openai-compatible": "^3.0.7",
39
- "ai": "^7.0.20",
40
- "@deepagents/retrieval": "5.0.0",
36
+ "@ai-sdk/groq": "^4.0.11",
37
+ "@ai-sdk/openai": "^4.0.15",
38
+ "@ai-sdk/openai-compatible": "^3.0.11",
39
+ "ai": "^7.0.30",
41
40
  "chalk": "^5.6.2",
42
- "dedent": "1.7.0",
43
- "listr2": "^9.0.4",
44
- "lodash-es": "^4.17.21",
41
+ "dedent": "1.7.2",
42
+ "listr2": "^10.2.2",
43
+ "lodash-es": "^4.18.1",
45
44
  "stringcase": "^4.3.1",
46
45
  "@ai-sdk/provider": "^4.0.3"
47
46
  },
48
47
  "peerDependencies": {
49
- "zod": "^3.25.76 || ^4.0.0"
48
+ "zod": "^4.4.3"
50
49
  },
51
50
  "devDependencies": {
52
- "@types/debug": "^4.1.12"
51
+ "@types/debug": "^4.1.13"
53
52
  }
54
53
  }
package/dist/lib/rag.d.ts DELETED
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=rag.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"rag.d.ts","sourceRoot":"","sources":["../../src/lib/rag.ts"],"names":[],"mappings":""}