@easbot/agent 0.2.10 → 0.2.11
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/cli.cjs +310 -307
- package/dist/cli.mjs +310 -307
- package/dist/index.cjs +293 -290
- package/dist/index.d.cts +61 -1
- package/dist/index.d.ts +61 -1
- package/dist/index.mjs +295 -292
- package/package.json +12 -12
package/dist/index.d.cts
CHANGED
|
@@ -10,7 +10,7 @@ export { AgentSyncConfig, AuthConfig, GatewayClusterConfig, GatewayConfig, Gatew
|
|
|
10
10
|
import { SearchResult, INoteKnowledge } from '@easbot/note';
|
|
11
11
|
import { MemoryRecallResult, IMemorySystem } from '@easbot/memory';
|
|
12
12
|
import * as _easbot_plugin from '@easbot/plugin';
|
|
13
|
-
import { CommandArguments, CommandExecutionContext, CommandExecuteResult, CommandInitContext, CommandInitResult, CommandDefinition, CommandPromptPart, HookEvent, HookHandler, HookDefinition, HookOutputWrapper, HookContext, HookMatcher as HookMatcher$1, HookChainResult } from '@easbot/plugin';
|
|
13
|
+
import { CommandArguments, CommandExecutionContext, CommandExecuteResult, CommandInitContext, CommandInitResult, CommandDefinition, CommandPromptPart, TaskSource, HookEvent, HookHandler, HookDefinition, HookOutputWrapper, HookContext, HookMatcher as HookMatcher$1, HookChainResult } from '@easbot/plugin';
|
|
14
14
|
export { CommandDefinition, CommandExecuteResult, CommandExecutionContext, CommandInitContext, CommandInitResult, HookChainResult, HookContext, HookDefinition, HookError, HookEvent, HookExecutionDetail, HookHandler, HookMatcher, HookOutputWrapper, HookResult } from '@easbot/plugin';
|
|
15
15
|
import { EasServer, NodeSpawnResult } from '@easbot/utils';
|
|
16
16
|
export { Identifier } from '@easbot/utils';
|
|
@@ -29279,6 +29279,64 @@ declare namespace Todo {
|
|
|
29279
29279
|
}[]>;
|
|
29280
29280
|
}
|
|
29281
29281
|
|
|
29282
|
+
declare namespace Task {
|
|
29283
|
+
export const MAX_CONCURRENT_TASKS = 5;
|
|
29284
|
+
export function getRunningCount(sessionId: string): Promise<number>;
|
|
29285
|
+
export type Status = 'pending' | 'running' | 'completed' | 'error';
|
|
29286
|
+
export interface Item {
|
|
29287
|
+
taskId: string;
|
|
29288
|
+
sessionId: string;
|
|
29289
|
+
description: string;
|
|
29290
|
+
prompt: string;
|
|
29291
|
+
agentType: string;
|
|
29292
|
+
source: TaskSource;
|
|
29293
|
+
status: Status;
|
|
29294
|
+
result?: string;
|
|
29295
|
+
error?: string;
|
|
29296
|
+
duration?: number;
|
|
29297
|
+
createdAt: number;
|
|
29298
|
+
updatedAt: number;
|
|
29299
|
+
metadata?: Record<string, unknown>;
|
|
29300
|
+
}
|
|
29301
|
+
export interface CreateParams {
|
|
29302
|
+
taskId: string;
|
|
29303
|
+
sessionId: string;
|
|
29304
|
+
description: string;
|
|
29305
|
+
prompt: string;
|
|
29306
|
+
agentType: string;
|
|
29307
|
+
source?: TaskSource;
|
|
29308
|
+
metadata?: Record<string, unknown>;
|
|
29309
|
+
}
|
|
29310
|
+
export interface UpdateParams {
|
|
29311
|
+
status?: Status;
|
|
29312
|
+
result?: string;
|
|
29313
|
+
error?: string;
|
|
29314
|
+
duration?: number;
|
|
29315
|
+
metadata?: Record<string, unknown>;
|
|
29316
|
+
}
|
|
29317
|
+
export interface Stats {
|
|
29318
|
+
total: number;
|
|
29319
|
+
pending: number;
|
|
29320
|
+
running: number;
|
|
29321
|
+
completed: number;
|
|
29322
|
+
error: number;
|
|
29323
|
+
}
|
|
29324
|
+
type StateResult = {
|
|
29325
|
+
tasks: Map<string, Item>;
|
|
29326
|
+
initialized: boolean;
|
|
29327
|
+
};
|
|
29328
|
+
export function state(): Promise<StateResult>;
|
|
29329
|
+
export function get(taskId: string): Promise<Item | undefined>;
|
|
29330
|
+
export function create(params: CreateParams): Promise<Item>;
|
|
29331
|
+
export function update(taskId: string, params: UpdateParams): Promise<void>;
|
|
29332
|
+
export function remove(taskId: string): Promise<void>;
|
|
29333
|
+
export function list(sessionId: string): Promise<Item[]>;
|
|
29334
|
+
export function active(sessionId: string): Promise<Item[]>;
|
|
29335
|
+
export function stats(sessionId: string): Promise<Stats>;
|
|
29336
|
+
export function cleanup(maxAge?: number): Promise<number>;
|
|
29337
|
+
export { };
|
|
29338
|
+
}
|
|
29339
|
+
|
|
29282
29340
|
declare namespace DynamicPrompt {
|
|
29283
29341
|
interface BuildOptions {
|
|
29284
29342
|
query?: string;
|
|
@@ -29291,11 +29349,13 @@ declare namespace DynamicPrompt {
|
|
|
29291
29349
|
useLLMSummary?: boolean;
|
|
29292
29350
|
maxTokens?: number;
|
|
29293
29351
|
includeTodos?: boolean;
|
|
29352
|
+
includeTaskAgents?: boolean;
|
|
29294
29353
|
}
|
|
29295
29354
|
function build(options: BuildOptions): Promise<string[]>;
|
|
29296
29355
|
function buildMemorySummary(query: string, results: MemorySearchResult[], useLLM: boolean, maxTokens?: number): Promise<string>;
|
|
29297
29356
|
function buildKnowledgeSummary(query: string, results: KnowledgeSearchResult[], useLLM: boolean, maxTokens?: number): Promise<string>;
|
|
29298
29357
|
function buildTodosSummary(todos: Todo.Info[]): string;
|
|
29358
|
+
function buildTaskAgentSummary(tasks: Task.Item[]): string;
|
|
29299
29359
|
function buildFileChangesSummary(changes: FileChange[]): string;
|
|
29300
29360
|
function buildCoderContext(_options: BuildOptions): string[];
|
|
29301
29361
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -10,7 +10,7 @@ export { AgentSyncConfig, AuthConfig, GatewayClusterConfig, GatewayConfig, Gatew
|
|
|
10
10
|
import { SearchResult, INoteKnowledge } from '@easbot/note';
|
|
11
11
|
import { MemoryRecallResult, IMemorySystem } from '@easbot/memory';
|
|
12
12
|
import * as _easbot_plugin from '@easbot/plugin';
|
|
13
|
-
import { CommandArguments, CommandExecutionContext, CommandExecuteResult, CommandInitContext, CommandInitResult, CommandDefinition, CommandPromptPart, HookEvent, HookHandler, HookDefinition, HookOutputWrapper, HookContext, HookMatcher as HookMatcher$1, HookChainResult } from '@easbot/plugin';
|
|
13
|
+
import { CommandArguments, CommandExecutionContext, CommandExecuteResult, CommandInitContext, CommandInitResult, CommandDefinition, CommandPromptPart, TaskSource, HookEvent, HookHandler, HookDefinition, HookOutputWrapper, HookContext, HookMatcher as HookMatcher$1, HookChainResult } from '@easbot/plugin';
|
|
14
14
|
export { CommandDefinition, CommandExecuteResult, CommandExecutionContext, CommandInitContext, CommandInitResult, HookChainResult, HookContext, HookDefinition, HookError, HookEvent, HookExecutionDetail, HookHandler, HookMatcher, HookOutputWrapper, HookResult } from '@easbot/plugin';
|
|
15
15
|
import { EasServer, NodeSpawnResult } from '@easbot/utils';
|
|
16
16
|
export { Identifier } from '@easbot/utils';
|
|
@@ -29279,6 +29279,64 @@ declare namespace Todo {
|
|
|
29279
29279
|
}[]>;
|
|
29280
29280
|
}
|
|
29281
29281
|
|
|
29282
|
+
declare namespace Task {
|
|
29283
|
+
export const MAX_CONCURRENT_TASKS = 5;
|
|
29284
|
+
export function getRunningCount(sessionId: string): Promise<number>;
|
|
29285
|
+
export type Status = 'pending' | 'running' | 'completed' | 'error';
|
|
29286
|
+
export interface Item {
|
|
29287
|
+
taskId: string;
|
|
29288
|
+
sessionId: string;
|
|
29289
|
+
description: string;
|
|
29290
|
+
prompt: string;
|
|
29291
|
+
agentType: string;
|
|
29292
|
+
source: TaskSource;
|
|
29293
|
+
status: Status;
|
|
29294
|
+
result?: string;
|
|
29295
|
+
error?: string;
|
|
29296
|
+
duration?: number;
|
|
29297
|
+
createdAt: number;
|
|
29298
|
+
updatedAt: number;
|
|
29299
|
+
metadata?: Record<string, unknown>;
|
|
29300
|
+
}
|
|
29301
|
+
export interface CreateParams {
|
|
29302
|
+
taskId: string;
|
|
29303
|
+
sessionId: string;
|
|
29304
|
+
description: string;
|
|
29305
|
+
prompt: string;
|
|
29306
|
+
agentType: string;
|
|
29307
|
+
source?: TaskSource;
|
|
29308
|
+
metadata?: Record<string, unknown>;
|
|
29309
|
+
}
|
|
29310
|
+
export interface UpdateParams {
|
|
29311
|
+
status?: Status;
|
|
29312
|
+
result?: string;
|
|
29313
|
+
error?: string;
|
|
29314
|
+
duration?: number;
|
|
29315
|
+
metadata?: Record<string, unknown>;
|
|
29316
|
+
}
|
|
29317
|
+
export interface Stats {
|
|
29318
|
+
total: number;
|
|
29319
|
+
pending: number;
|
|
29320
|
+
running: number;
|
|
29321
|
+
completed: number;
|
|
29322
|
+
error: number;
|
|
29323
|
+
}
|
|
29324
|
+
type StateResult = {
|
|
29325
|
+
tasks: Map<string, Item>;
|
|
29326
|
+
initialized: boolean;
|
|
29327
|
+
};
|
|
29328
|
+
export function state(): Promise<StateResult>;
|
|
29329
|
+
export function get(taskId: string): Promise<Item | undefined>;
|
|
29330
|
+
export function create(params: CreateParams): Promise<Item>;
|
|
29331
|
+
export function update(taskId: string, params: UpdateParams): Promise<void>;
|
|
29332
|
+
export function remove(taskId: string): Promise<void>;
|
|
29333
|
+
export function list(sessionId: string): Promise<Item[]>;
|
|
29334
|
+
export function active(sessionId: string): Promise<Item[]>;
|
|
29335
|
+
export function stats(sessionId: string): Promise<Stats>;
|
|
29336
|
+
export function cleanup(maxAge?: number): Promise<number>;
|
|
29337
|
+
export { };
|
|
29338
|
+
}
|
|
29339
|
+
|
|
29282
29340
|
declare namespace DynamicPrompt {
|
|
29283
29341
|
interface BuildOptions {
|
|
29284
29342
|
query?: string;
|
|
@@ -29291,11 +29349,13 @@ declare namespace DynamicPrompt {
|
|
|
29291
29349
|
useLLMSummary?: boolean;
|
|
29292
29350
|
maxTokens?: number;
|
|
29293
29351
|
includeTodos?: boolean;
|
|
29352
|
+
includeTaskAgents?: boolean;
|
|
29294
29353
|
}
|
|
29295
29354
|
function build(options: BuildOptions): Promise<string[]>;
|
|
29296
29355
|
function buildMemorySummary(query: string, results: MemorySearchResult[], useLLM: boolean, maxTokens?: number): Promise<string>;
|
|
29297
29356
|
function buildKnowledgeSummary(query: string, results: KnowledgeSearchResult[], useLLM: boolean, maxTokens?: number): Promise<string>;
|
|
29298
29357
|
function buildTodosSummary(todos: Todo.Info[]): string;
|
|
29358
|
+
function buildTaskAgentSummary(tasks: Task.Item[]): string;
|
|
29299
29359
|
function buildFileChangesSummary(changes: FileChange[]): string;
|
|
29300
29360
|
function buildCoderContext(_options: BuildOptions): string[];
|
|
29301
29361
|
}
|