@deepagents/orchestrator 0.1.0 → 0.1.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.
Files changed (45) hide show
  1. package/dist/lib/deepplan/demo.d.ts +2 -0
  2. package/dist/lib/deepplan/demo.d.ts.map +1 -0
  3. package/dist/lib/deepplan/{executor-agent.d.ts → executors/generic-executor.d.ts} +3 -27
  4. package/dist/lib/deepplan/executors/generic-executor.d.ts.map +1 -0
  5. package/dist/lib/deepplan/executors/hackernews-executor.d.ts +2 -0
  6. package/dist/lib/deepplan/executors/hackernews-executor.d.ts.map +1 -0
  7. package/dist/lib/deepplan/executors/product-manager-executor.d.ts.map +1 -0
  8. package/dist/lib/deepplan/executors/repo-search-executor.d.ts +11 -0
  9. package/dist/lib/deepplan/executors/repo-search-executor.d.ts.map +1 -0
  10. package/dist/lib/deepplan/executors/research-executor.d.ts.map +1 -0
  11. package/dist/lib/deepplan/next/plan.d.ts +1 -0
  12. package/dist/lib/deepplan/next/plan.d.ts.map +1 -0
  13. package/dist/lib/deepplan/plan-and-solve.d.ts +12 -4
  14. package/dist/lib/deepplan/plan-and-solve.d.ts.map +1 -1
  15. package/dist/lib/deepplan/planner-agent.d.ts +38 -2
  16. package/dist/lib/deepplan/planner-agent.d.ts.map +1 -1
  17. package/dist/lib/deepplan/replanner-agent.d.ts +3 -3
  18. package/dist/lib/deepplan/replanner-agent.d.ts.map +1 -1
  19. package/dist/lib/deepwiki/tools.d.ts.map +1 -1
  20. package/dist/lib/repo-context.d.ts +2 -0
  21. package/dist/lib/repo-context.d.ts.map +1 -0
  22. package/package.json +11 -7
  23. package/dist/lib/deepplan/deepplan.d.ts +0 -2
  24. package/dist/lib/deepplan/deepplan.d.ts.map +0 -1
  25. package/dist/lib/deepplan/executor-agent.d.ts.map +0 -1
  26. package/dist/lib/deepplan/jordan-research-demo.d.ts +0 -2
  27. package/dist/lib/deepplan/jordan-research-demo.d.ts.map +0 -1
  28. package/dist/lib/deepplan/plan.d.ts +0 -2
  29. package/dist/lib/deepplan/plan.d.ts.map +0 -1
  30. package/dist/lib/deepplan/product-manager-executor.d.ts.map +0 -1
  31. package/dist/lib/deepplan/research-executor.d.ts.map +0 -1
  32. package/dist/lib/plan-and-solve/examples.d.ts +0 -98
  33. package/dist/lib/plan-and-solve/examples.d.ts.map +0 -1
  34. package/dist/lib/plan-and-solve/index.d.ts +0 -14
  35. package/dist/lib/plan-and-solve/index.d.ts.map +0 -1
  36. package/dist/lib/plan-and-solve/plan-and-solve-agent.d.ts +0 -37
  37. package/dist/lib/plan-and-solve/plan-and-solve-agent.d.ts.map +0 -1
  38. package/dist/lib/plan-and-solve/run-demo.d.ts +0 -2
  39. package/dist/lib/plan-and-solve/run-demo.d.ts.map +0 -1
  40. package/dist/lib/plan-and-solve/self-consistency.d.ts +0 -24
  41. package/dist/lib/plan-and-solve/self-consistency.d.ts.map +0 -1
  42. package/dist/lib/plan-and-solve/types.d.ts +0 -70
  43. package/dist/lib/plan-and-solve/types.d.ts.map +0 -1
  44. /package/dist/lib/deepplan/{product-manager-executor.d.ts → executors/product-manager-executor.d.ts} +0 -0
  45. /package/dist/lib/deepplan/{research-executor.d.ts → executors/research-executor.d.ts} +0 -0
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=demo.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"demo.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/demo.ts"],"names":[],"mappings":""}
@@ -1,4 +1,4 @@
1
- import type { PlanStep, PlannerOutput } from './planner-agent.ts';
1
+ import type { PlanStep, PlannerOutput } from '../planner-agent.ts';
2
2
  /**
3
3
  * Executor Agent
4
4
  *
@@ -15,6 +15,7 @@ export declare const executorAgent: import("@deepagents/agent").Agent<unknown, i
15
15
  * Format step for executor with full context
16
16
  */
17
17
  export declare function formatStepForExecutor(step: PlanStep, context: ExecutionContext): string;
18
+ export declare function createExecutionContext(request: string, plannerOutput: PlannerOutput): ExecutionContext;
18
19
  export interface ExecutionContext {
19
20
  original_request: string;
20
21
  understanding: string;
@@ -25,29 +26,4 @@ export interface ExecutionContext {
25
26
  is_complete: boolean;
26
27
  success_criteria_met?: boolean;
27
28
  }
28
- export declare function createExecutionContext(request: string, plannerOutput: PlannerOutput): ExecutionContext;
29
- /**
30
- * Final result of the entire planning and execution process
31
- */
32
- export interface AdaptivePlanResult {
33
- original_request: string;
34
- understanding: string;
35
- success: boolean;
36
- completion_status: 'completed' | 'partial' | 'failed';
37
- final_data: Record<string, unknown>;
38
- execution_history: string[];
39
- execution_context: ExecutionContext;
40
- }
41
- export declare function run(step: PlanStep, context: ExecutionContext): Promise<{
42
- variables: {
43
- [x: string]: string | number | boolean;
44
- };
45
- step_results: string[];
46
- original_request: string;
47
- understanding: string;
48
- initial_plan: PlanStep[];
49
- current_plan: PlanStep[];
50
- is_complete: boolean;
51
- success_criteria_met?: boolean;
52
- }>;
53
- //# sourceMappingURL=executor-agent.d.ts.map
29
+ //# sourceMappingURL=generic-executor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generic-executor.d.ts","sourceRoot":"","sources":["../../../../src/lib/deepplan/executors/generic-executor.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEnE;;;;;;;;;;GAUG;AACH,eAAO,MAAM,aAAa,0FAmJxB,CAAC;AAEH;;GAEG;AACH,wBAAgB,qBAAqB,CACnC,IAAI,EAAE,QAAQ,EACd,OAAO,EAAE,gBAAgB,GACxB,MAAM,CAqBR;AAED,wBAAgB,sBAAsB,CACpC,OAAO,EAAE,MAAM,EACf,aAAa,EAAE,aAAa,GAC3B,gBAAgB,CAUlB;AAED,MAAM,WAAW,gBAAgB;IAE/B,gBAAgB,EAAE,MAAM,CAAC;IACzB,aAAa,EAAE,MAAM,CAAC;IAGtB,YAAY,EAAE,QAAQ,EAAE,CAAC;IACzB,YAAY,EAAE,QAAQ,EAAE,CAAC;IAGzB,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC;IAGrD,YAAY,EAAE,MAAM,EAAE,CAAC;IAGvB,WAAW,EAAE,OAAO,CAAC;IACrB,oBAAoB,CAAC,EAAE,OAAO,CAAC;CAChC"}
@@ -0,0 +1,2 @@
1
+ export declare const hackerNewsExecutor: import("@deepagents/agent").Agent<unknown, import("@deepagents/agent").ContextVariables>;
2
+ //# sourceMappingURL=hackernews-executor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hackernews-executor.d.ts","sourceRoot":"","sources":["../../../../src/lib/deepplan/executors/hackernews-executor.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,kBAAkB,0FAoM7B,CAAC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"product-manager-executor.d.ts","sourceRoot":"","sources":["../../../../src/lib/deepplan/executors/product-manager-executor.ts"],"names":[],"mappings":"AAUA;;;;;;;;;;GAUG;AACH,eAAO,MAAM,sBAAsB,0FAoNjC,CAAC"}
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Repository Q&A Executor Agent
3
+ *
4
+ * Purpose-built for answering questions about a local repository by:
5
+ * 1. Locating relevant files and directories
6
+ * 2. Reading precise code/documentation snippets
7
+ * 3. Synthesizing findings into grounded answers
8
+ * 4. Tracking evidence for every conclusion
9
+ */
10
+ export declare const repoSearchExecutor: import("@deepagents/agent").Agent<unknown, import("@deepagents/agent").ContextVariables>;
11
+ //# sourceMappingURL=repo-search-executor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"repo-search-executor.d.ts","sourceRoot":"","sources":["../../../../src/lib/deepplan/executors/repo-search-executor.ts"],"names":[],"mappings":"AAOA;;;;;;;;GAQG;AACH,eAAO,MAAM,kBAAkB,0FA8D7B,CAAC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"research-executor.d.ts","sourceRoot":"","sources":["../../../../src/lib/deepplan/executors/research-executor.ts"],"names":[],"mappings":"AAKA;;;;;;;;;GASG;AACH,eAAO,MAAM,gBAAgB,0FAsL3B,CAAC"}
@@ -0,0 +1 @@
1
+ //# sourceMappingURL=plan.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plan.d.ts","sourceRoot":"","sources":["../../../../src/lib/deepplan/next/plan.ts"],"names":[],"mappings":""}
@@ -1,5 +1,5 @@
1
1
  import { type Agent, type ContextVariables } from '@deepagents/agent';
2
- import { type ExecutionContext } from './executor-agent.ts';
2
+ import { type ExecutionContext } from './executors/generic-executor.ts';
3
3
  /**
4
4
  * Lifecycle hooks for Plan-and-Solve execution.
5
5
  *
@@ -104,8 +104,17 @@ export interface PlanHooks {
104
104
  * ```typescript
105
105
  * const result = await planAndSolve({
106
106
  * input: "Find all AI startups that raised Series A",
107
- * executor: myExecutor,
108
- * state: { repo_path: process.cwd() },
107
+ * executor: researchExecutor,
108
+ * state: {
109
+ * repo_path: process.cwd()
110
+ * },
111
+ * environment: {
112
+ * executor_type: 'research',
113
+ * available_tools: ['browser_search', 'scratchpad'],
114
+ * domain: 'market research',
115
+ * capabilities: ['web search', 'source verification', 'numerical data extraction']
116
+ * },
117
+ * },
109
118
  * hooks: {
110
119
  * beforeReplan: async (context) => {
111
120
  * // Save progress before replanning
@@ -124,7 +133,6 @@ export interface PlanHooks {
124
133
  export declare function planAndSolve(options: {
125
134
  input: string;
126
135
  executor: Agent<any, any>;
127
- synthesizer?: Agent<any, any>;
128
136
  state: ContextVariables;
129
137
  hooks?: PlanHooks;
130
138
  }): Promise<string>;
@@ -1 +1 @@
1
- {"version":3,"file":"plan-and-solve.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/plan-and-solve.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,KAAK,EACV,KAAK,gBAAgB,EAGtB,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EACL,KAAK,gBAAgB,EAEtB,MAAM,qBAAqB,CAAC;AAK7B;;;;;;;;;GASG;AACH,MAAM,WAAW,SAAS;IACxB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAmCG;IACH,aAAa,CAAC,EAAE,CACd,OAAO,EAAE,gBAAgB,KACtB,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC,GAAG,gBAAgB,GAAG,IAAI,CAAC;IAEhE;;;;;;;;;;;;;;;OAeG;IACH,YAAY,CAAC,EAAE,CACb,OAAO,EAAE,gBAAgB,KACtB,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC,GAAG,gBAAgB,GAAG,IAAI,CAAC;IAEhE;;;;;;;;;;;;;;;;;OAiBG;IACH,WAAW,CAAC,EAAE,CACZ,OAAO,EAAE,gBAAgB,KACtB,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC,GAAG,gBAAgB,GAAG,IAAI,CAAC;CACjE;AAoBD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmCG;AACH,wBAAsB,YAAY,CAAC,OAAO,EAAE;IAC1C,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,KAAK,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;IAC1B,WAAW,CAAC,EAAE,KAAK,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;IAC9B,KAAK,EAAE,gBAAgB,CAAC;IACxB,KAAK,CAAC,EAAE,SAAS,CAAC;CACnB,mBAkDA"}
1
+ {"version":3,"file":"plan-and-solve.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/plan-and-solve.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,KAAK,KAAK,EACV,KAAK,gBAAgB,EAItB,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EACL,KAAK,gBAAgB,EAEtB,MAAM,iCAAiC,CAAC;AAKzC;;;;;;;;;GASG;AACH,MAAM,WAAW,SAAS;IACxB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAmCG;IACH,aAAa,CAAC,EAAE,CACd,OAAO,EAAE,gBAAgB,KACtB,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC,GAAG,gBAAgB,GAAG,IAAI,CAAC;IAEhE;;;;;;;;;;;;;;;OAeG;IACH,YAAY,CAAC,EAAE,CACb,OAAO,EAAE,gBAAgB,KACtB,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC,GAAG,gBAAgB,GAAG,IAAI,CAAC;IAEhE;;;;;;;;;;;;;;;;;OAiBG;IACH,WAAW,CAAC,EAAE,CACZ,OAAO,EAAE,gBAAgB,KACtB,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC,GAAG,gBAAgB,GAAG,IAAI,CAAC;CACjE;AAoBD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4CG;AACH,wBAAsB,YAAY,CAAC,OAAO,EAAE;IAC1C,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,KAAK,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;IAC1B,KAAK,EAAE,gBAAgB,CAAC;IACxB,KAAK,CAAC,EAAE,SAAS,CAAC;CACnB,mBAqDA"}
@@ -15,6 +15,32 @@ export declare const PlannerOutputSchema: z.ZodObject<{
15
15
  }, z.core.$strip>;
16
16
  export type PlanStep = z.infer<typeof PlanStepSchema>;
17
17
  export type PlannerOutput = z.infer<typeof PlannerOutputSchema>;
18
+ /**
19
+ * Environment context that describes the execution capabilities.
20
+ * This helps the planner create steps that are actually executable.
21
+ */
22
+ export interface PlanEnvironment {
23
+ /**
24
+ * Type of executor that will execute the steps
25
+ * @example 'research', 'hackernews', 'generic', 'product_manager'
26
+ */
27
+ executor_type: string;
28
+ /**
29
+ * Available tools the executor has access to
30
+ * @example ['browser_search', 'scratchpad'], ['hackernews_search', 'scratchpad']
31
+ */
32
+ available_tools: string[];
33
+ /**
34
+ * Domain or task category
35
+ * @example 'market research', 'hackernews sentiment analysis', 'code repository search'
36
+ */
37
+ domain: string;
38
+ /**
39
+ * High-level capabilities description
40
+ * @example ['web search', 'source verification', 'numerical data extraction']
41
+ */
42
+ capabilities?: string[];
43
+ }
18
44
  /**
19
45
  * Planner agent that creates structured execution plans:
20
46
  * 1. Understanding Phase: Deeply understand the user's request
@@ -33,7 +59,17 @@ export declare const plannerAgent: import("@deepagents/agent").Agent<{
33
59
  description: string;
34
60
  expected_outcome: string;
35
61
  }[];
36
- }, import("@deepagents/agent").ContextVariables>;
37
- export declare function plan(userRequest: string): Promise<import("./executor-agent.ts").ExecutionContext>;
62
+ }, {
63
+ environment?: PlanEnvironment;
64
+ }>;
65
+ /**
66
+ * Create an execution plan for the given user request
67
+ *
68
+ * @param userRequest - The user's task or question
69
+ * @param environment - Optional execution environment describing available tools and domain
70
+ */
71
+ export declare function plan(userRequest: string, state?: {
72
+ environment?: PlanEnvironment;
73
+ }): Promise<import("./executors/generic-executor.ts").ExecutionContext>;
38
74
  export {};
39
75
  //# sourceMappingURL=planner-agent.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"planner-agent.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/planner-agent.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAC;AAMpB,QAAA,MAAM,cAAc;;;iBAOlB,CAAC;AAEH,eAAO,MAAM,mBAAmB;;;;;;;;;iBAqB9B,CAAC;AAEH,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AACtD,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEhE;;;;;;;;GAQG;AACH,eAAO,MAAM,YAAY;;;;;;;;;gDAoIvB,CAAC;AAEH,wBAAsB,IAAI,CAAC,WAAW,EAAE,MAAM,2DAO7C"}
1
+ {"version":3,"file":"planner-agent.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/planner-agent.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AAMpB,QAAA,MAAM,cAAc;;;iBAOlB,CAAC;AAEH,eAAO,MAAM,mBAAmB;;;;;;;;;iBAqB9B,CAAC;AAEH,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AACtD,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEhE;;;GAGG;AACH,MAAM,WAAW,eAAe;IAC9B;;;OAGG;IACH,aAAa,EAAE,MAAM,CAAC;IAEtB;;;OAGG;IACH,eAAe,EAAE,MAAM,EAAE,CAAC;IAE1B;;;OAGG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;CACzB;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,YAAY;;;;;;;;;;kBAEP,eAAe;EA8K/B,CAAC;AAqBH;;;;;GAKG;AACH,wBAAsB,IAAI,CACxB,WAAW,EAAE,MAAM,EACnB,KAAK,GAAE;IAAE,WAAW,CAAC,EAAE,eAAe,CAAA;CAAO,uEAQ9C"}
@@ -1,5 +1,5 @@
1
1
  import z from 'zod';
2
- import { type ExecutionContext } from './executor-agent.ts';
2
+ import { type ExecutionContext } from './executors/generic-executor.ts';
3
3
  import type { PlanStep } from './planner-agent.ts';
4
4
  export declare const ReplanDecisionSchema: z.ZodObject<{
5
5
  reasoning: z.ZodString;
@@ -8,7 +8,7 @@ export declare const ReplanDecisionSchema: z.ZodObject<{
8
8
  description: z.ZodString;
9
9
  expected_outcome: z.ZodString;
10
10
  }, z.core.$strip>>;
11
- new_insights: z.ZodDefault<z.ZodArray<z.ZodString>>;
11
+ new_insights: z.ZodString;
12
12
  }, z.core.$strip>;
13
13
  export type ReplanDecision = z.infer<typeof ReplanDecisionSchema>;
14
14
  /**
@@ -29,7 +29,7 @@ export declare const replannerAgent: import("@deepagents/agent").Agent<{
29
29
  description: string;
30
30
  expected_outcome: string;
31
31
  }[];
32
- new_insights: string[];
32
+ new_insights: string;
33
33
  }, import("@deepagents/agent").ContextVariables>;
34
34
  export declare function replan(context: ExecutionContext): Promise<{
35
35
  current_plan: {
@@ -1 +1 @@
1
- {"version":3,"file":"replanner-agent.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/replanner-agent.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAC;AAIpB,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAUnD,eAAO,MAAM,oBAAoB;;;;;;;;iBAW/B,CAAC;AAEH,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAElE;;;;;;;;;;GAUG;AACH,eAAO,MAAM,cAAc;;;;;;;;gDA6JzB,CAAC;AAkDH,wBAAsB,MAAM,CAAC,OAAO,EAAE,gBAAgB;;;;;;;;;;;;GAarD"}
1
+ {"version":3,"file":"replanner-agent.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/replanner-agent.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAC;AAIpB,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AACxE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAUnD,eAAO,MAAM,oBAAoB;;;;;;;;iBAU/B,CAAC;AAEH,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAElE;;;;;;;;;;GAUG;AACH,eAAO,MAAM,cAAc;;;;;;;;gDA8JzB,CAAC;AAkDH,wBAAsB,MAAM,CAAC,OAAO,EAAE,gBAAgB;;;;;;;;;;;;GAYrD"}
@@ -1 +1 @@
1
- {"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../../../src/lib/deepwiki/tools.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,cAAc;;;;UAiEzB,CAAC;AAEH,eAAO,MAAM,aAAa;;YAcxB,CAAC;AAEH,eAAO,MAAM,SAAS;;YAoBpB,CAAC;AAEH,eAAO,MAAM,iBAAiB;;;;YAwB5B,CAAC;AAEH,eAAO,MAAM,gBAAgB;;WAS3B,CAAC;AAEH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA2C9B,CAAC;AAEH,wBAAsB,QAAQ,CAAC,QAAQ,EAAE,MAAM,mBAK9C"}
1
+ {"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../../../src/lib/deepwiki/tools.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,cAAc;;;;UAiEzB,CAAC;AAEH,eAAO,MAAM,aAAa;;YAcxB,CAAC;AAEH,eAAO,MAAM,SAAS;;YAoBpB,CAAC;AAEH,eAAO,MAAM,iBAAiB;;;;YAwB5B,CAAC;AAEH,eAAO,MAAM,gBAAgB;;WAS3B,CAAC;AAEH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA6C9B,CAAC;AAEH,wBAAsB,QAAQ,CAAC,QAAQ,EAAE,MAAM,mBAK9C"}
@@ -0,0 +1,2 @@
1
+ export declare function repoContext(repoPath: string): Promise<void>;
2
+ //# sourceMappingURL=repo-context.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"repo-context.d.ts","sourceRoot":"","sources":["../../src/lib/repo-context.ts"],"names":[],"mappings":"AAIA,wBAAsB,WAAW,CAAC,QAAQ,EAAE,MAAM,iBAGjD"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@deepagents/orchestrator",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",
@@ -27,14 +27,18 @@
27
27
  "access": "public"
28
28
  },
29
29
  "dependencies": {
30
- "@deepagents/agent": "0.1.0",
31
- "@ai-sdk/groq": "2.0.24",
30
+ "@deepagents/agent": "0.1.2",
31
+ "@ai-sdk/groq": "2.0.26",
32
32
  "zod": "^3.25.76 || ^4.0.0",
33
- "ai": "^5.0.65",
33
+ "ai": "^5.0.82",
34
34
  "lodash-es": "^4.17.21",
35
- "@deepagents/retrieval": "0.1.0",
36
- "@deepagents/toolbox": "0.1.0",
37
- "p-limit": "^6.1.0"
35
+ "@deepagents/retrieval": "0.1.2",
36
+ "@deepagents/toolbox": "0.1.2",
37
+ "p-limit": "^7.2.0",
38
+ "@ai-sdk/openai": "2.0.58",
39
+ "@tavily/core": "^0.5.12",
40
+ "fast-glob": "^3.3.3",
41
+ "nano-spawn": "^2.0.0"
38
42
  },
39
43
  "peerDependencies": {},
40
44
  "devDependencies": {
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=deepplan.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"deepplan.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/deepplan.ts"],"names":[],"mappings":""}
@@ -1 +0,0 @@
1
- {"version":3,"file":"executor-agent.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/executor-agent.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAElE;;;;;;;;;;GAUG;AACH,eAAO,MAAM,aAAa,0FAmJxB,CAAC;AAEH;;GAEG;AACH,wBAAgB,qBAAqB,CACnC,IAAI,EAAE,QAAQ,EACd,OAAO,EAAE,gBAAgB,GACxB,MAAM,CAqBR;AAED,MAAM,WAAW,gBAAgB;IAE/B,gBAAgB,EAAE,MAAM,CAAC;IACzB,aAAa,EAAE,MAAM,CAAC;IAGtB,YAAY,EAAE,QAAQ,EAAE,CAAC;IACzB,YAAY,EAAE,QAAQ,EAAE,CAAC;IAGzB,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC;IAGrD,YAAY,EAAE,MAAM,EAAE,CAAC;IAGvB,WAAW,EAAE,OAAO,CAAC;IACrB,oBAAoB,CAAC,EAAE,OAAO,CAAC;CAChC;AAED,wBAAgB,sBAAsB,CACpC,OAAO,EAAE,MAAM,EACf,aAAa,EAAE,aAAa,GAC3B,gBAAgB,CAUlB;AAED;;GAEG;AACH,MAAM,WAAW,kBAAkB;IAEjC,gBAAgB,EAAE,MAAM,CAAC;IACzB,aAAa,EAAE,MAAM,CAAC;IAGtB,OAAO,EAAE,OAAO,CAAC;IACjB,iBAAiB,EAAE,WAAW,GAAG,SAAS,GAAG,QAAQ,CAAC;IAGtD,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAEpC,iBAAiB,EAAE,MAAM,EAAE,CAAC;IAG5B,iBAAiB,EAAE,gBAAgB,CAAC;CACrC;AAED,wBAAsB,GAAG,CAAC,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,gBAAgB;;;;;sBAtD/C,MAAM;mBACT,MAAM;kBAGP,QAAQ,EAAE;kBACV,QAAQ,EAAE;iBASX,OAAO;2BACG,OAAO;GAkD/B"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=jordan-research-demo.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"jordan-research-demo.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/jordan-research-demo.ts"],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=plan.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"plan.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/plan.ts"],"names":[],"mappings":""}
@@ -1 +0,0 @@
1
- {"version":3,"file":"product-manager-executor.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/product-manager-executor.ts"],"names":[],"mappings":"AAUA;;;;;;;;;;GAUG;AACH,eAAO,MAAM,sBAAsB,0FAoNjC,CAAC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"research-executor.d.ts","sourceRoot":"","sources":["../../../src/lib/deepplan/research-executor.ts"],"names":[],"mappings":"AAKA;;;;;;;;;GASG;AACH,eAAO,MAAM,gBAAgB,0FAsL3B,CAAC"}
@@ -1,98 +0,0 @@
1
- /**
2
- * Example problems from different reasoning categories
3
- * Based on the paper's evaluation datasets
4
- */
5
- export declare const EXAMPLE_PROBLEMS: {
6
- arithmetic: {
7
- simple: string;
8
- complex: string;
9
- multistep: string;
10
- };
11
- symbolic: {
12
- pattern: string;
13
- sequence: string;
14
- logic: string;
15
- };
16
- commonsense: {
17
- physical: string;
18
- temporal: string;
19
- social: string;
20
- };
21
- };
22
- /**
23
- * Run a single problem with PS+ (deterministic, temperature=0)
24
- */
25
- export declare function runSinglePath(problem: string): Promise<{
26
- understanding?: string | undefined;
27
- plan?: (string | undefined)[] | undefined;
28
- variables?: {
29
- [x: string]: any;
30
- } | undefined;
31
- reasoning_steps?: ({
32
- step_number?: number | undefined;
33
- description?: string | undefined;
34
- reasoning?: string | undefined;
35
- result?: string | undefined;
36
- } | undefined)[] | undefined;
37
- final_answer?: string | number | undefined;
38
- calculations?: ({
39
- expression?: string | undefined;
40
- result?: string | number | undefined;
41
- } | undefined)[] | undefined;
42
- }>;
43
- /**
44
- * Run a problem with self-consistency (multiple paths, temperature=0.7)
45
- */
46
- export declare function runSelfConsistency(problem: string, numPaths?: number): Promise<{
47
- answers: {
48
- answer: string | number;
49
- reasoning_path: string;
50
- confidence?: number | undefined;
51
- }[];
52
- majority_answer: string | number;
53
- confidence_score: number;
54
- vote_distribution: Record<string, number>;
55
- }>;
56
- /**
57
- * Compare single-path vs self-consistency for a given problem
58
- */
59
- export declare function compareApproaches(problem: string, numPaths?: number): Promise<{
60
- singlePath: {
61
- understanding?: string | undefined;
62
- plan?: (string | undefined)[] | undefined;
63
- variables?: {
64
- [x: string]: any;
65
- } | undefined;
66
- reasoning_steps?: ({
67
- step_number?: number | undefined;
68
- description?: string | undefined;
69
- reasoning?: string | undefined;
70
- result?: string | undefined;
71
- } | undefined)[] | undefined;
72
- final_answer?: string | number | undefined;
73
- calculations?: ({
74
- expression?: string | undefined;
75
- result?: string | number | undefined;
76
- } | undefined)[] | undefined;
77
- };
78
- selfConsistency: {
79
- answers: {
80
- answer: string | number;
81
- reasoning_path: string;
82
- confidence?: number | undefined;
83
- }[];
84
- majority_answer: string | number;
85
- confidence_score: number;
86
- vote_distribution: Record<string, number>;
87
- };
88
- answersMatch: boolean;
89
- }>;
90
- /**
91
- * Run all example problems (useful for testing)
92
- */
93
- export declare function runAllExamples(): Promise<void>;
94
- /**
95
- * Demonstrate self-consistency on a challenging problem
96
- */
97
- export declare function demonstrateSelfConsistency(): Promise<void>;
98
- //# sourceMappingURL=examples.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"examples.d.ts","sourceRoot":"","sources":["../../../src/lib/plan-and-solve/examples.ts"],"names":[],"mappings":"AASA;;;GAGG;AACH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;CAqB5B,CAAC;AAEF;;GAEG;AACH,wBAAsB,aAAa,CAAC,OAAO,EAAE,MAAM;;;;;;;;;;;;;;;;;GAYlD;AAED;;GAEG;AACH,wBAAsB,kBAAkB,CAAC,OAAO,EAAE,MAAM,EAAE,QAAQ,SAAK;;;;;;;;;GAoBtE;AAED;;GAEG;AACH,wBAAsB,iBAAiB,CAAC,OAAO,EAAE,MAAM,EAAE,QAAQ,SAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BpE;AAED;;GAEG;AACH,wBAAsB,cAAc,kBAiBnC;AAED;;GAEG;AACH,wBAAsB,0BAA0B,kBAO/C"}
@@ -1,14 +0,0 @@
1
- /**
2
- * Plan-and-Solve Plus (PS+) Implementation
3
- *
4
- * Implements the enhanced PS+ prompting technique from the paper:
5
- * "Plan-and-Solve Prompting: Improving Zero-Shot Chain-of-Thought Reasoning by Large Language Models"
6
- * (arXiv:2305.04091)
7
- *
8
- * @module plan-and-solve
9
- */
10
- export { planAndSolveAgent, createPlanAndSolveAgent, } from './plan-and-solve-agent.ts';
11
- export { planAndSolveWithSelfConsistency, analyzeReasoningDiversity, } from './self-consistency.ts';
12
- export type { ReasoningStep, PlanAndSolveOutput, SelfConsistencyResult, PlanAndSolveConfig, } from './types.ts';
13
- export { EXAMPLE_PROBLEMS, runSinglePath, runSelfConsistency, compareApproaches, runAllExamples, demonstrateSelfConsistency, } from './examples.ts';
14
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/plan-and-solve/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAGH,OAAO,EACL,iBAAiB,EACjB,uBAAuB,GACxB,MAAM,2BAA2B,CAAC;AAGnC,OAAO,EACL,+BAA+B,EAC/B,yBAAyB,GAC1B,MAAM,uBAAuB,CAAC;AAG/B,YAAY,EACV,aAAa,EACb,kBAAkB,EAClB,qBAAqB,EACrB,kBAAkB,GACnB,MAAM,YAAY,CAAC;AAGpB,OAAO,EACL,gBAAgB,EAChB,aAAa,EACb,kBAAkB,EAClB,iBAAiB,EACjB,cAAc,EACd,0BAA0B,GAC3B,MAAM,eAAe,CAAC"}
@@ -1,37 +0,0 @@
1
- export declare const planAndSolveAgent: import("@deepagents/agent").Agent<{
2
- understanding: string;
3
- plan: string[];
4
- variables: Record<string, any>;
5
- reasoning_steps: {
6
- step_number: number;
7
- description: string;
8
- reasoning: string;
9
- result?: string | undefined;
10
- }[];
11
- final_answer: string | number;
12
- calculations?: {
13
- expression: string;
14
- result: string | number;
15
- }[] | undefined;
16
- }, import("@deepagents/agent").ContextVariables>;
17
- /**
18
- * Creates a Plan-and-Solve Plus agent with custom temperature
19
- * Useful for self-consistency where higher temperature (0.7) is needed
20
- */
21
- export declare function createPlanAndSolveAgent(temperature?: number): import("@deepagents/agent").Agent<{
22
- understanding: string;
23
- plan: string[];
24
- variables: Record<string, any>;
25
- reasoning_steps: {
26
- step_number: number;
27
- description: string;
28
- reasoning: string;
29
- result?: string | undefined;
30
- }[];
31
- final_answer: string | number;
32
- calculations?: {
33
- expression: string;
34
- result: string | number;
35
- }[] | undefined;
36
- }, import("@deepagents/agent").ContextVariables>;
37
- //# sourceMappingURL=plan-and-solve-agent.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"plan-and-solve-agent.d.ts","sourceRoot":"","sources":["../../../src/lib/plan-and-solve/plan-and-solve-agent.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;gDAiG5B,CAAC;AAEH;;;GAGG;AACH,wBAAgB,uBAAuB,CAAC,WAAW,SAAI;;;;;;;;;;;;;;;iDAEtD"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=run-demo.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"run-demo.d.ts","sourceRoot":"","sources":["../../../src/lib/plan-and-solve/run-demo.ts"],"names":[],"mappings":""}
@@ -1,24 +0,0 @@
1
- import type { SelfConsistencyResult } from './types.ts';
2
- /**
3
- * Implements self-consistency for Plan-and-Solve Plus
4
- *
5
- * Self-consistency improves reasoning by:
6
- * 1. Generating multiple diverse reasoning paths (with temperature > 0)
7
- * 2. Extracting the final answer from each path
8
- * 3. Selecting the most consistent answer via majority voting
9
- *
10
- * Based on the paper's configuration:
11
- * - Temperature: 0.7 (for diversity)
12
- * - Number of paths: 10 (default, configurable)
13
- */
14
- export declare function planAndSolveWithSelfConsistency(problem: string, numPaths?: number): Promise<SelfConsistencyResult>;
15
- /**
16
- * Analyzes the diversity of reasoning paths
17
- * Useful for understanding how different the generated paths are
18
- */
19
- export declare function analyzeReasoningDiversity(results: SelfConsistencyResult): {
20
- uniqueAnswers: number;
21
- entropy: number;
22
- diversityScore: number;
23
- };
24
- //# sourceMappingURL=self-consistency.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"self-consistency.d.ts","sourceRoot":"","sources":["../../../src/lib/plan-and-solve/self-consistency.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAsB,qBAAqB,EAAE,MAAM,YAAY,CAAC;AAE5E;;;;;;;;;;;GAWG;AACH,wBAAsB,+BAA+B,CACnD,OAAO,EAAE,MAAM,EACf,QAAQ,SAAK,GACZ,OAAO,CAAC,qBAAqB,CAAC,CAsGhC;AAED;;;GAGG;AACH,wBAAgB,yBAAyB,CAAC,OAAO,EAAE,qBAAqB,GAAG;IACzE,aAAa,EAAE,MAAM,CAAC;IACtB,OAAO,EAAE,MAAM,CAAC;IAChB,cAAc,EAAE,MAAM,CAAC;CACxB,CAuBA"}
@@ -1,70 +0,0 @@
1
- import z from 'zod';
2
- /**
3
- * Schema for a single reasoning step in the plan
4
- */
5
- export declare const ReasoningStepSchema: z.ZodObject<{
6
- step_number: z.ZodNumber;
7
- description: z.ZodString;
8
- reasoning: z.ZodString;
9
- result: z.ZodOptional<z.ZodString>;
10
- }, z.core.$strip>;
11
- /**
12
- * Schema for the complete Plan-and-Solve Plus output
13
- */
14
- export declare const PlanAndSolveOutputSchema: z.ZodObject<{
15
- understanding: z.ZodString;
16
- plan: z.ZodArray<z.ZodString>;
17
- variables: z.ZodRecord<z.ZodString, z.ZodAny>;
18
- reasoning_steps: z.ZodArray<z.ZodObject<{
19
- step_number: z.ZodNumber;
20
- description: z.ZodString;
21
- reasoning: z.ZodString;
22
- result: z.ZodOptional<z.ZodString>;
23
- }, z.core.$strip>>;
24
- calculations: z.ZodOptional<z.ZodArray<z.ZodObject<{
25
- expression: z.ZodString;
26
- result: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
27
- }, z.core.$strip>>>;
28
- final_answer: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
29
- }, z.core.$strip>;
30
- /**
31
- * Schema for self-consistency result
32
- */
33
- export declare const SelfConsistencyResultSchema: z.ZodObject<{
34
- answers: z.ZodArray<z.ZodObject<{
35
- answer: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
36
- reasoning_path: z.ZodString;
37
- confidence: z.ZodOptional<z.ZodNumber>;
38
- }, z.core.$strip>>;
39
- majority_answer: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
40
- confidence_score: z.ZodNumber;
41
- vote_distribution: z.ZodRecord<z.ZodString, z.ZodNumber>;
42
- }, z.core.$strip>;
43
- export type ReasoningStep = z.infer<typeof ReasoningStepSchema>;
44
- export type PlanAndSolveOutput = z.infer<typeof PlanAndSolveOutputSchema>;
45
- export type SelfConsistencyResult = z.infer<typeof SelfConsistencyResultSchema>;
46
- /**
47
- * Input configuration for Plan-and-Solve Plus
48
- */
49
- export interface PlanAndSolveConfig {
50
- /**
51
- * The problem/question to solve
52
- */
53
- problem: string;
54
- /**
55
- * Temperature for generation (0 for deterministic, 0.7 for self-consistency)
56
- * @default 0
57
- */
58
- temperature?: number;
59
- /**
60
- * Whether to use self-consistency (multiple reasoning paths)
61
- * @default false
62
- */
63
- useSelfConsistency?: boolean;
64
- /**
65
- * Number of reasoning paths to generate for self-consistency
66
- * @default 10
67
- */
68
- numPaths?: number;
69
- }
70
- //# sourceMappingURL=types.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/lib/plan-and-solve/types.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB;;GAEG;AACH,eAAO,MAAM,mBAAmB;;;;;iBAU9B,CAAC;AAEH;;GAEG;AACH,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;iBA6BnC,CAAC;AAEH;;GAEG;AACH,eAAO,MAAM,2BAA2B;;;;;;;;;iBAqBtC,CAAC;AAGH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAChE,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAC1E,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,2BAA2B,CAAC,CAAC;AAEhF;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC;;OAEG;IACH,OAAO,EAAE,MAAM,CAAC;IAEhB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAE7B;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}