qlogicagent 0.5.3 → 0.6.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.
Files changed (84) hide show
  1. package/README.md +24 -23
  2. package/dist/agent.js +13 -13
  3. package/dist/cli.js +210 -186
  4. package/dist/contracts.js +1 -1
  5. package/dist/index.js +381 -20
  6. package/dist/orchestration.js +14 -105
  7. package/dist/types/agent/agent.d.ts +1 -1
  8. package/dist/types/agent/constants.d.ts +2 -2
  9. package/dist/types/agent/tool-access.d.ts +30 -0
  10. package/dist/types/agent/tool-loop.d.ts +2 -4
  11. package/dist/types/agent/types.d.ts +1 -13
  12. package/dist/types/cli/main.d.ts +3 -3
  13. package/dist/types/cli/stdio-server.d.ts +29 -7
  14. package/dist/types/cli/tool-bootstrap.d.ts +24 -5
  15. package/dist/types/cli/transport.d.ts +40 -0
  16. package/dist/types/contracts/index.d.ts +0 -1
  17. package/dist/types/contracts/todo.d.ts +9 -0
  18. package/dist/types/index.d.ts +3 -0
  19. package/dist/types/llm/model-catalog.d.ts +1 -1
  20. package/dist/types/orchestration/index.d.ts +14 -112
  21. package/dist/types/orchestration/skill-improvement.d.ts +2 -2
  22. package/dist/types/orchestration/{fork-subagent.d.ts → subagent/fork-subagent.d.ts} +2 -4
  23. package/dist/types/runtime/execution/dream-agent.d.ts +1 -1
  24. package/dist/types/runtime/execution/forked-agent.d.ts +1 -3
  25. package/dist/types/runtime/hooks/context-compression.d.ts +1 -1
  26. package/dist/types/runtime/infra/agent-paths.d.ts +57 -0
  27. package/dist/types/runtime/infra/checkpoint-backend.d.ts +8 -0
  28. package/dist/types/runtime/infra/disk-storage.d.ts +36 -0
  29. package/dist/types/runtime/infra/file-watcher.d.ts +2 -2
  30. package/dist/types/runtime/infra/index.d.ts +2 -0
  31. package/dist/types/runtime/infra/secure-storage.d.ts +1 -1
  32. package/dist/types/runtime/infra/task-runtime.d.ts +1 -1
  33. package/dist/types/runtime/prompt/instruction-loader.d.ts +6 -6
  34. package/dist/types/runtime/session/session-memory.d.ts +0 -1
  35. package/dist/types/runtime/session/session-persistence.d.ts +1 -1
  36. package/dist/types/skills/index.d.ts +20 -26
  37. package/dist/types/skills/mcp/mcp-manager.d.ts +3 -4
  38. package/dist/types/skills/mcp/mcp-stdio-client.d.ts +1 -1
  39. package/dist/types/skills/{memory-store.d.ts → memory/memory-store.d.ts} +20 -0
  40. package/dist/types/skills/{memory-tool.d.ts → memory/memory-tool.d.ts} +20 -0
  41. package/dist/types/skills/permissions/hook-runner.d.ts +1 -1
  42. package/dist/types/skills/permissions/settings-watcher.d.ts +2 -2
  43. package/dist/types/skills/plugins/plugin-api.d.ts +1 -1
  44. package/dist/types/skills/plugins/plugin-loader.d.ts +1 -4
  45. package/dist/types/skills/plugins/plugin-marketplace.d.ts +1 -1
  46. package/dist/types/skills/portable-tool.d.ts +34 -1
  47. package/dist/types/skills/todo-tool.d.ts +51 -42
  48. package/dist/types/skills/tools/instructions-tool.d.ts +20 -58
  49. package/dist/types/skills/tools/skill-invoke-tool.d.ts +2 -2
  50. package/dist/types/skills/tools.d.ts +65 -0
  51. package/package.json +2 -2
  52. package/dist/types/contracts/skill-candidate.d.ts +0 -63
  53. package/dist/types/orchestration/curator-scheduler.d.ts +0 -119
  54. package/dist/types/orchestration/memory-provider.d.ts +0 -14
  55. package/dist/types/orchestration/skill-candidate.d.ts +0 -52
  56. package/dist/types/orchestration/skill-consolidation.d.ts +0 -123
  57. package/dist/types/orchestration/skill-similarity.d.ts +0 -98
  58. package/dist/types/orchestration/team-orchestration.d.ts +0 -195
  59. package/dist/types/orchestration/team-tool-loop-wiring.d.ts +0 -92
  60. package/dist/types/skills/memory-query-tool.d.ts +0 -43
  61. package/dist/types/skills/tool-registry.d.ts +0 -29
  62. package/dist/types/skills/tools/memory-tool.d.ts +0 -74
  63. package/dist/types/skills/tools/pdf-tool.d.ts +0 -66
  64. /package/dist/types/orchestration/{context-collapse.d.ts → context/context-collapse.d.ts} +0 -0
  65. /package/dist/types/orchestration/{context-compression.d.ts → context/context-compression.d.ts} +0 -0
  66. /package/dist/types/orchestration/{reactive-compact.d.ts → context/reactive-compact.d.ts} +0 -0
  67. /package/dist/types/orchestration/{turn-loop-guard.d.ts → context/turn-loop-guard.d.ts} +0 -0
  68. /package/dist/types/orchestration/{error-classification.d.ts → error-handling/error-classification.d.ts} +0 -0
  69. /package/dist/types/orchestration/{failover-classification.d.ts → error-handling/failover-classification.d.ts} +0 -0
  70. /package/dist/types/orchestration/{failover-error.d.ts → error-handling/failover-error.d.ts} +0 -0
  71. /package/dist/types/orchestration/{retry-loop.d.ts → error-handling/retry-loop.d.ts} +0 -0
  72. /package/dist/types/orchestration/{agent-registry.d.ts → subagent/agent-registry.d.ts} +0 -0
  73. /package/dist/types/orchestration/{task-types.d.ts → subagent/task-types.d.ts} +0 -0
  74. /package/dist/types/orchestration/{conversation-repair.d.ts → tool-loop/conversation-repair.d.ts} +0 -0
  75. /package/dist/types/orchestration/{tool-choice-policy.d.ts → tool-loop/tool-choice-policy.d.ts} +0 -0
  76. /package/dist/types/orchestration/{tool-loop-state.d.ts → tool-loop/tool-loop-state.d.ts} +0 -0
  77. /package/dist/types/orchestration/{tool-schema.d.ts → tool-loop/tool-schema.d.ts} +0 -0
  78. /package/dist/types/skills/{memory-extractor.d.ts → memory/memory-extractor.d.ts} +0 -0
  79. /package/dist/types/skills/{qmemory-adapter.d.ts → memory/qmemory-adapter.d.ts} +0 -0
  80. /package/dist/types/skills/{skill-frontmatter.d.ts → skill-system/skill-frontmatter.d.ts} +0 -0
  81. /package/dist/types/skills/{skill-guard.d.ts → skill-system/skill-guard.d.ts} +0 -0
  82. /package/dist/types/skills/{skill-loader.d.ts → skill-system/skill-loader.d.ts} +0 -0
  83. /package/dist/types/skills/{skill-source.d.ts → skill-system/skill-source.d.ts} +0 -0
  84. /package/dist/types/skills/{skill-types.d.ts → skill-system/skill-types.d.ts} +0 -0
@@ -1,6 +1,21 @@
1
- import { ToolRegistry } from "../skills/tool-registry.js";
1
+ import type { PortableTool } from "../skills/portable-tool.js";
2
2
  import { type ExecProgress } from "../skills/tools/exec-tool.js";
3
3
  import type { AgentLogger } from "../agent/types.js";
4
+ export interface MediaRelayConfig {
5
+ imageEndpoint?: string;
6
+ ttsEndpoint?: string;
7
+ videoEndpoint?: string;
8
+ videoEditEndpoint?: string;
9
+ videoMergeEndpoint?: string;
10
+ videoUpscaleEndpoint?: string;
11
+ musicEndpoint?: string;
12
+ }
13
+ /**
14
+ * Set the media relay config for multimedia tools.
15
+ * CC parity: tools use isEnabled() gates instead of conditional addTool().
16
+ * Call this before getAllBaseTools() or when config changes.
17
+ */
18
+ export declare function setMediaConfig(config: MediaRelayConfig | undefined): void;
4
19
  export interface BootstrapConfig {
5
20
  workdir?: string;
6
21
  log?: AgentLogger;
@@ -8,12 +23,16 @@ export interface BootstrapConfig {
8
23
  onExecProgress?(progress: ExecProgress): void;
9
24
  }
10
25
  /**
11
- * Create and populate a ToolRegistry with all locally-executable tools.
26
+ * Create all locally-executable tools and install into centralized tool pool.
27
+ *
28
+ * CC parity: getAllBaseTools() returns flat array, installed via setToolPool().
29
+ * Tools execute IN-PROCESS (zero IPC).
12
30
  *
13
- * Tools registered here execute IN-PROCESS (zero IPC).
14
- * All tools are agent-local — no Gateway relay.
31
+ * @alias initToolDeps kept for backward compat with existing call sites.
15
32
  */
16
- export declare function bootstrapToolRegistry(config?: BootstrapConfig): ToolRegistry;
33
+ export declare function getAllBaseTools(config?: BootstrapConfig): PortableTool[];
34
+ /** @deprecated Use getAllBaseTools() instead. */
35
+ export declare const initToolDeps: typeof getAllBaseTools;
17
36
  /**
18
37
  * Update the working directory for all local tool deps.
19
38
  * Called when Gateway sends a new workdir via config.
@@ -0,0 +1,40 @@
1
+ /**
2
+ * Transport — abstract I/O layer for JSON-RPC message exchange.
3
+ *
4
+ * Decouples the agent protocol handler from the physical transport
5
+ * (stdin/stdout, WebSocket, Unix Domain Socket, etc.).
6
+ *
7
+ * Each transport reads incoming JSON-RPC messages and emits them
8
+ * to a registered handler; outgoing messages are sent via send().
9
+ */
10
+ export interface Transport {
11
+ /** Register the message handler (called for each valid parsed message). */
12
+ onMessage(handler: (msg: unknown) => void): void;
13
+ /** Register the close handler (called when the transport closes). */
14
+ onClose(handler: () => void): void;
15
+ /** Send a JSON-RPC message (object will be serialized to JSON). */
16
+ send(msg: unknown): void;
17
+ /** Start listening for incoming messages. */
18
+ start(): void;
19
+ /** Close the transport gracefully. */
20
+ close(): void;
21
+ }
22
+ /**
23
+ * Line-delimited JSON over stdin/stdout.
24
+ * Each line on stdin is a JSON message; each send() writes one JSON line to stdout.
25
+ * All diagnostic logging goes to stderr.
26
+ */
27
+ export declare class StdioTransport implements Transport {
28
+ private messageHandler;
29
+ private closeHandler;
30
+ private verbose;
31
+ constructor(opts?: {
32
+ verbose?: boolean;
33
+ });
34
+ onMessage(handler: (msg: unknown) => void): void;
35
+ onClose(handler: () => void): void;
36
+ send(msg: unknown): void;
37
+ start(): void;
38
+ close(): void;
39
+ private log;
40
+ }
@@ -7,4 +7,3 @@
7
7
  export * from "./planner.js";
8
8
  export * from "./todo.js";
9
9
  export * from "./hooks.js";
10
- export * from "./skill-candidate.js";
@@ -4,11 +4,20 @@ export interface TodoItem {
4
4
  id: number;
5
5
  title: string;
6
6
  status: TodoItemStatus;
7
+ /** Detailed task description (V2). */
8
+ description?: string;
9
+ /** Owner agent/subagent identifier for per-agent isolation (V2). */
10
+ owner?: string;
11
+ /** IDs of tasks that must complete before this one can start (V2). */
12
+ blockedBy?: number[];
13
+ /** IDs of tasks this one blocks from starting (V2). */
14
+ blocks?: number[];
7
15
  }
8
16
  export interface TodoListSummary {
9
17
  total: number;
10
18
  completed: number;
11
19
  inProgress: number;
12
20
  notStarted: number;
21
+ blocked: number;
13
22
  }
14
23
  export declare function summarizeTodoList(items: readonly TodoItem[]): TodoListSummary;
@@ -7,6 +7,9 @@ export { Agent } from "./agent/agent.js";
7
7
  export type { AgentLogger, ChatMessage, ToolDefinition, ToolInvoker, TurnConfig, TurnEvent, TurnRequest, HookRegistry, } from "./agent/types.js";
8
8
  export { parseCliArgs } from "./config/config.js";
9
9
  export type { AgentConfig } from "./config/config.js";
10
+ export type { Transport } from "./cli/transport.js";
11
+ export { StdioTransport } from "./cli/transport.js";
12
+ export { StdioServer, type StdioServerConfig } from "./cli/stdio-server.js";
10
13
  export { ProviderRegistry, createLLMClient, autoDetectProvider, } from "./llm/index.js";
11
14
  export type { LLMTransport, LLMRequest, LLMChunk } from "./llm/index.js";
12
15
  export { createHookRegistry } from "./runtime/hooks/hook-registry.js";
@@ -6,7 +6,7 @@
6
6
  *
7
7
  * Three-layer fallback:
8
8
  * 1. In-memory cache (process-level, TTL check against disk mtime)
9
- * 2. Disk cache (~/.openclaw/cache/model_catalog.json)
9
+ * 2. Disk cache (~/.qlogicagent/cache/model_catalog.json)
10
10
  * 3. Remote fetch (https://models.dev/api.json)
11
11
  * 4. Stale disk cache (if remote fails)
12
12
  * 5. Empty (caller falls back to builtin-providers.ts hardcoded)
@@ -1,113 +1,15 @@
1
- export { buildAssistantToolCallMessage, buildToolResultMessage, type FunctionToolDefinition, } from "./tool-schema.js";
2
- export { classifyError, getRetryStrategy, type ErrorCategory, type RetryStrategy, } from "./error-classification.js";
3
- export { composeStrategies, composeAsyncStrategies, SlidingWindowStrategy, SummarizeOldStrategy, ToolResultTrimStrategy, HeadTailProtectedStrategy, IncrementalCompactStrategy, CacheAwareCompressionStrategy, CompressionMetricsCollector, ContextEngineRegistry, MicroCompactStrategy, postCompactFileRecovery, type PostCompactRecoveryConfig, buildStructuredSummaryPrompt, computeAdaptiveBudget, isAsyncCompressionStrategy, selectCompressionTier, DEFAULT_ADAPTIVE_BUDGET_CONFIG, type AdaptiveBudgetConfig, type AsyncCompressionStrategy, type CacheAwareCompressionConfig, type CompressibleMessage, type CompressionEvent, type CompressionMetrics, type CompressionMetricsSnapshot, type CompressionResult, type CompressionStrategy, type CompressionTier, type ContextEngine, type HeadTailProtectionConfig, type IncrementalCompactConfig, type SummarizeFn, } from "./context-compression.js";
4
- export { snipCompactIfNeeded, type SnipResult, } from "./context-compression.js";
5
- export { applyCollapsesIfNeeded as applyContextCollapsesIfNeeded, recoverFromOverflow as recoverContextCollapseFromOverflow, createCollapseStore, type CollapseStore, type CollapseStage, } from "./context-collapse.js";
1
+ export { buildAssistantToolCallMessage, buildToolResultMessage, type FunctionToolDefinition, } from "./tool-loop/tool-schema.js";
2
+ export { classifyError, getRetryStrategy, type ErrorCategory, type RetryStrategy, } from "./error-handling/error-classification.js";
3
+ export { composeStrategies, composeAsyncStrategies, SlidingWindowStrategy, SummarizeOldStrategy, ToolResultTrimStrategy, HeadTailProtectedStrategy, IncrementalCompactStrategy, CacheAwareCompressionStrategy, CompressionMetricsCollector, ContextEngineRegistry, MicroCompactStrategy, postCompactFileRecovery, type PostCompactRecoveryConfig, buildStructuredSummaryPrompt, computeAdaptiveBudget, isAsyncCompressionStrategy, selectCompressionTier, DEFAULT_ADAPTIVE_BUDGET_CONFIG, type AdaptiveBudgetConfig, type AsyncCompressionStrategy, type CacheAwareCompressionConfig, type CompressibleMessage, type CompressionEvent, type CompressionMetrics, type CompressionMetricsSnapshot, type CompressionResult, type CompressionStrategy, type CompressionTier, type ContextEngine, type HeadTailProtectionConfig, type IncrementalCompactConfig, type SummarizeFn, } from "./context/context-compression.js";
4
+ export { snipCompactIfNeeded, type SnipResult, } from "./context/context-compression.js";
5
+ export { applyCollapsesIfNeeded as applyContextCollapsesIfNeeded, recoverFromOverflow as recoverContextCollapseFromOverflow, createCollapseStore, type CollapseStore, type CollapseStage, } from "./context/context-collapse.js";
6
6
  export { buildSkillInstruction, type SkillCreateInstruction, type SkillImproveInstruction, type SkillInstruction, type SkillTurnResult, } from "./skill-improvement.js";
7
- export { buildSkillCandidateEffectivenessSummary, buildSkillCandidateEvidencePayload, buildSkillCandidateImprovementEvidenceBundle, buildSkillCandidateLatestReview, createDefaultSkillImprovementPolicy, normalizeSkillImprovementPolicy, type SkillCandidateImprovementEvidenceBundleContract, type SkillImprovementPolicyContract, } from "./skill-candidate.js";
8
- export declare const SIDECHAIN_TYPE_VALUES: readonly ["research", "planner", "plan-repair", "code-repair", "media-prep"];
9
- export type SidechainType = typeof SIDECHAIN_TYPE_VALUES[number];
10
- export type SidechainBudgetTier = "low" | "medium" | "high";
11
- export type SidechainMergePolicy = "summary-only" | "append-messages" | "replace-context" | "manual";
12
- export type SidechainToolAccessMode = "full" | "read-only" | "none";
13
- export interface SidechainTypePolicy {
14
- type: SidechainType;
15
- label: string;
16
- description: string;
17
- mergePolicy: SidechainMergePolicy;
18
- budgetTier: SidechainBudgetTier;
19
- budgetWeight: number;
20
- preferFullContext: boolean;
21
- preserveConversationHistory: boolean;
22
- toolAccessMode: SidechainToolAccessMode;
23
- }
24
- export type SidechainToolAccessDecision = "allowed" | "denied";
25
- export type SidechainToolAccessInheritance = "inherit" | "shrink";
26
- export type SidechainToolAccessReason = "default-allow" | "always-deny" | "leaf-deny";
27
- export interface SidechainToolAccessRule {
28
- toolName: string;
29
- decision: SidechainToolAccessDecision;
30
- inheritance: SidechainToolAccessInheritance;
31
- reason: SidechainToolAccessReason;
32
- }
33
- export interface SidechainToolAccessPolicy {
34
- deniedTools: string[];
35
- canSpawnChildren: boolean;
36
- defaultDecision: "allowed";
37
- defaultInheritance: "inherit";
38
- tools: SidechainToolAccessRule[];
39
- }
40
- export declare const SIDECHAIN_TOOL_DENY_ALWAYS: readonly ["gateway", "agents_list", "whatsapp_login", "session_status", "cron", "memory_query", "sessions_send"];
41
- export declare const SIDECHAIN_TOOL_DENY_LEAF: readonly ["sessions_list", "sessions_history", "sessions_spawn"];
42
- /** Tools that perform write/mutation operations — denied in read-only sidechain types. */
43
- export declare const SIDECHAIN_TOOL_DENY_WRITE: readonly ["file_edit", "create_file", "replace_string_in_file", "multi_replace_string_in_file", "create_directory", "run_in_terminal", "run_command", "delete_file", "rename_file", "move_file", "git_commit", "git_push", "manage_todo_list"];
44
- export declare function resolveSidechainToolAccessPolicy(params?: {
45
- depth?: number;
46
- maxDepth?: number;
47
- role?: "leaf" | "orchestrator";
48
- toolNames?: Iterable<string>;
49
- }): SidechainToolAccessPolicy;
50
- /**
51
- * Resolve tool access policy for a specific sidechain type.
52
- * Combines depth-based deny lists with type-specific access mode:
53
- * - "full": only depth-based denials apply
54
- * - "read-only": depth-based + all write/mutation tools denied
55
- * - "none": all tools denied
56
- */
57
- export declare function resolveSidechainToolAccessByType(params: {
58
- type: SidechainType;
59
- depth?: number;
60
- maxDepth?: number;
61
- role?: "leaf" | "orchestrator";
62
- toolNames?: Iterable<string>;
63
- }): SidechainToolAccessPolicy;
64
- export interface ToolCallAccessFilterResult<T> {
65
- allowed: T[];
66
- denied: Array<{
67
- toolCall: T;
68
- reason: string;
69
- }>;
70
- }
71
- /**
72
- * Filter tool_calls against a resolved access policy.
73
- * Returns allowed calls and denied calls with reasons.
74
- * T must have at least { id: string; function: { name: string } }.
75
- */
76
- export declare function filterToolCallsByAccessPolicy<T extends {
77
- id: string;
78
- function: {
79
- name: string;
80
- };
81
- }>(toolCalls: T[], policy: SidechainToolAccessPolicy): ToolCallAccessFilterResult<T>;
82
- export declare function listSidechainTypePolicies(): SidechainTypePolicy[];
83
- export declare function resolveSidechainTypePolicy(type: SidechainType): SidechainTypePolicy;
84
- export declare function resolveRepairSidechainType(params?: {
85
- toolNames?: Iterable<string>;
86
- preferCodeRepair?: boolean;
87
- trigger?: string;
88
- }): Extract<SidechainType, "plan-repair" | "code-repair">;
89
- export declare function resolveSidechainMergePolicyByType(type: SidechainType, overrides?: {
90
- forceManualReview?: boolean;
91
- preferFullContext?: boolean;
92
- preserveConversationHistory?: boolean;
93
- }): SidechainMergePolicy;
94
- export declare function resolveSidechainMergePolicy(params?: {
95
- preferFullContext?: boolean;
96
- forceManualReview?: boolean;
97
- preserveConversationHistory?: boolean;
98
- }): SidechainMergePolicy;
99
- export { applyToolChoicePolicy, type ApplyToolChoicePolicyInput, type ApplyToolChoicePolicyResult, } from "./tool-choice-policy.js";
100
- export { repairOpenAiChatConversation, type ConversationRepairOptions, type OpenAiChatMessageLike, type OpenAiToolCall, } from "./conversation-repair.js";
101
- export { advanceToolLoopState, recoverToolLoopStateFromChatConversation, recoverToolLoopStateFromResponsesItems, settleToolLoopState, type RepairToolLoopStateResult, type ToolLoopRepairAction, type ToolLoopState, } from "./tool-loop-state.js";
102
- export { MEMORY_OBSERVATION_HOOK_VALUES, MEMORY_OBSERVATION_SOURCE_VALUES, MEMORY_WRITE_ACCESS_VALUES, type MemoryObservationHook, type MemoryObservationSource, type MemoryWriteAccess, type MemoryProviderLifecycleInvocation, } from "./memory-provider.js";
103
- export { isForegroundSource, isTransientCapacityError, computeRetryBackoff, isPersistentRetryEnabled, FallbackTriggeredError, type PersistentRetryConfig, } from "./retry-loop.js";
104
- export { computeLifecycleTransitions, DEFAULT_CURATOR_SCHEDULE_POLICY, INITIAL_CURATOR_STATE, selectReviewCandidates, shouldRunCurator, type CuratorAutoTransitionResult, type CuratorGateInput, type CuratorGateResult, type CuratorLifecycleTransition, type CuratorSchedulePolicy, type CuratorSkillLifecycleState, type CuratorSkillRecord, type CuratorState, } from "./curator-scheduler.js";
105
- export { buildConsolidationPrompt, buildCuratorRunSummary, detectPrefixClusters, parseConsolidationOutput, reconcileConsolidationPlan, type ConsolidationAction, type ConsolidationPlan, type ConsolidationSkillSummary, type CuratorRunReport, type PruningAction, type ReconciledConsolidationPlan, type SkillPrefixCluster, } from "./skill-consolidation.js";
106
- export { bigramSimilarity, computeSimilarity, decideSimilarityAction, DEFAULT_SKILL_SIMILARITY_POLICY, findSimilarSkills, stepCountProximity, toolSetJaccard, type SimilarityDecision, type SimilarityScore, type SimilarSkillMatch, type SkillSimilarityPolicy, type SkillSimilarityProfile, } from "./skill-similarity.js";
107
- export { aggregateTeamResults, allocateTokenBudgets, buildAgentTaskPrompt, inferAggregationPolicy, inferExecutionMode, mapRoleToSidechainType, resolveAgentToolAccess, resolveExecutionOrder, resolveTeamPlan, shouldCancelTeam, TEAM_MAX_AGENTS, TEAM_MAX_DEPTH, validateTeamPlan, type AgentRole, type TeamAgentResult, type TeamAgentSpec, type TeamAggregationPolicy, type TeamExecutionMode, type TeamLifecycleState, type TeamPlan, type TeamResult, } from "./team-orchestration.js";
108
- export { canForkAtDepth, buildForkedMessages, buildForkPlaceholderResults, FORK_PLACEHOLDER_RESULT, FORK_SENTINEL_TAG, generateForkChildAgentId, isInForkChild, MAX_FORK_DEPTH, MAX_SIDECHAIN_DB_DEPTH, resolveForkChildTools, type ForkChildConfig, type ForkChildMessage, type ForkContext, type ForkResult, } from "./fork-subagent.js";
109
- export { getBuiltInAgent, getBuiltInAgents, isBuiltInAgent, resolveAgentToolSet, type AgentDefinition, } from "./agent-registry.js";
110
- export { createTaskState, filterToolsByRole, type IsolationMode, type PermissionRole, type TaskType, type TaskLifecycle, type TaskState, type TaskStateBase, type LocalBashTaskState, type LocalAgentTaskState, type RemoteAgentTaskState, type InProcessTeammateTaskState, type DreamTaskState, type DreamTurn, type DreamPhase, } from "./task-types.js";
111
- export { calculateTokenWarningState, createTurnLoopGuardState, resolveApiErrorRecovery, resolveOutputTokenEscalation, shouldAbortTurn, type ApiErrorRecovery, type TokenWarningState, type TurnLoopGuardConfig, type TurnLoopGuardState, } from "./turn-loop-guard.js";
112
- export { buildPostCompactRestorationMessage, createReactiveCompactState, shouldAttemptReactiveCompact, type ReactiveCompactConfig, type ReactiveCompactState, } from "./reactive-compact.js";
113
- export { aggregateTeamToolResults, mapTeamRequestToForkConfigs, resolveTeamExecutionPlan, type TeamAgentRequest, type TeamAggregatedResult, type TeamExecutionBatch, type TeamExecutionPlan, type TeamToolRequest, } from "./team-tool-loop-wiring.js";
7
+ export { applyToolChoicePolicy, type ApplyToolChoicePolicyInput, type ApplyToolChoicePolicyResult, } from "./tool-loop/tool-choice-policy.js";
8
+ export { repairOpenAiChatConversation, type ConversationRepairOptions, type OpenAiChatMessageLike, type OpenAiToolCall, } from "./tool-loop/conversation-repair.js";
9
+ export { advanceToolLoopState, recoverToolLoopStateFromChatConversation, recoverToolLoopStateFromResponsesItems, settleToolLoopState, type RepairToolLoopStateResult, type ToolLoopRepairAction, type ToolLoopState, } from "./tool-loop/tool-loop-state.js";
10
+ export { isForegroundSource, isTransientCapacityError, computeRetryBackoff, isPersistentRetryEnabled, FallbackTriggeredError, type PersistentRetryConfig, } from "./error-handling/retry-loop.js";
11
+ export { canForkAtDepth, buildForkedMessages, buildForkPlaceholderResults, FORK_PLACEHOLDER_RESULT, FORK_SENTINEL_TAG, generateForkChildAgentId, isInForkChild, MAX_FORK_DEPTH, resolveForkChildTools, type ForkChildConfig, type ForkChildMessage, type ForkContext, type ForkResult, } from "./subagent/fork-subagent.js";
12
+ export { getBuiltInAgent, getBuiltInAgents, isBuiltInAgent, resolveAgentToolSet, type AgentDefinition, } from "./subagent/agent-registry.js";
13
+ export { createTaskState, filterToolsByRole, type IsolationMode, type PermissionRole, type TaskType, type TaskLifecycle, type TaskState, type TaskStateBase, type LocalBashTaskState, type LocalAgentTaskState, type RemoteAgentTaskState, type InProcessTeammateTaskState, type DreamTaskState, type DreamTurn, type DreamPhase, } from "./subagent/task-types.js";
14
+ export { calculateTokenWarningState, createTurnLoopGuardState, resolveApiErrorRecovery, resolveOutputTokenEscalation, shouldAbortTurn, type ApiErrorRecovery, type TokenWarningState, type TurnLoopGuardConfig, type TurnLoopGuardState, } from "./context/turn-loop-guard.js";
15
+ export { buildPostCompactRestorationMessage, createReactiveCompactState, shouldAttemptReactiveCompact, type ReactiveCompactConfig, type ReactiveCompactState, } from "./context/reactive-compact.js";
@@ -10,8 +10,8 @@ export interface SkillTurnResult {
10
10
  distinctToolCount: number;
11
11
  /** Was a multi-step orchestration (≥2 rounds) used? */
12
12
  multiStep: boolean;
13
- /** Did the turn involve a sidechain? */
14
- hasSidechain: boolean;
13
+ /** Did the turn involve a sub-agent fork? */
14
+ hasSubAgent: boolean;
15
15
  /** Optional user feedback signal (positive/negative/none) */
16
16
  feedback?: "positive" | "negative" | null;
17
17
  /** Skill name if an existing skill was used */
@@ -13,10 +13,8 @@ import type { AgentDefinition } from "./agent-registry.js";
13
13
  export declare const FORK_SENTINEL_TAG = "<fork-child-context>";
14
14
  /** Placeholder text used for all tool_results in shared prefix (ensures byte-identical prefix). */
15
15
  export declare const FORK_PLACEHOLDER_RESULT = "Fork started \u2014 processing in background";
16
- /** Maximum fork depth for in-memory agents (more permissive than DB sidechain). */
16
+ /** Maximum fork depth for in-memory agents (CC: MAX_FORK_DEPTH). */
17
17
  export declare const MAX_FORK_DEPTH = 4;
18
- /** Maximum fork depth for DB-backed sidechains (more conservative). */
19
- export declare const MAX_SIDECHAIN_DB_DEPTH = 2;
20
18
  export interface ForkContext {
21
19
  /** Parent's full message history (becomes shared prefix for cache). */
22
20
  parentMessages: unknown[];
@@ -67,7 +65,7 @@ export declare function isInForkChild(messages: unknown[]): boolean;
67
65
  /**
68
66
  * Check if fork depth allows spawning another child.
69
67
  */
70
- export declare function canForkAtDepth(currentDepth: number, mode?: "in-memory" | "db-sidechain"): boolean;
68
+ export declare function canForkAtDepth(currentDepth: number): boolean;
71
69
  /**
72
70
  * Build forked messages that ensure byte-identical prefix across all fork children.
73
71
  *
@@ -10,7 +10,7 @@
10
10
  *
11
11
  * Reference: claude-code src/services/autoDream/
12
12
  */
13
- import type { DreamTaskState, DreamTurn } from "../../orchestration/task-types.js";
13
+ import type { DreamTaskState, DreamTurn } from "../../orchestration/subagent/task-types.js";
14
14
  import type { ToolDefinition, ToolInvoker, AgentLogger, HookRegistry } from "../../agent/types.js";
15
15
  import type { LLMTransport } from "../../llm/transport.js";
16
16
  export interface DreamTriggerConfig {
@@ -77,10 +77,8 @@ export interface ForkedAgentParams {
77
77
  skipTranscript?: boolean;
78
78
  /** Token budget for this sub-agent. 0 or undefined = no limit. */
79
79
  budgetTokens?: number;
80
- /** Parent sidechain depth (propagated to child tool loop) */
80
+ /** Parent fork depth (propagated to child tool loop) */
81
81
  parentDepth?: number;
82
- /** Sidechain type for tool access policy (default "code-repair" = full) */
83
- sidechainType?: import("../../orchestration/index.js").SidechainType;
84
82
  }
85
83
  /**
86
84
  * Result of a forked agent run.
@@ -6,7 +6,7 @@ import type { LLMTransport } from "../../llm/transport.js";
6
6
  export declare function estimateTokens(msg: CompressibleMessage): number;
7
7
  /** Estimate total tokens for a message array. */
8
8
  export declare function estimateTotalTokens(messages: CompressibleMessage[]): number;
9
- export declare function getCompressionMetrics(): import("../../orchestration/context-compression.js").CompressionMetricsSnapshot;
9
+ export declare function getCompressionMetrics(): import("../../orchestration/index.js").CompressionMetricsSnapshot;
10
10
  export declare function getContextEngineRegistry(): ContextEngineRegistry;
11
11
  /**
12
12
  * Create a summarization callback using an injected LLM transport.
@@ -0,0 +1,57 @@
1
+ /**
2
+ * Agent Paths — Centralized dot-directory name and path helpers.
3
+ *
4
+ * All filesystem paths under `~/.qlogicagent/` (user-level) or
5
+ * `<project>/.qlogicagent/` (project-level) must go through these
6
+ * helpers so the dot-dir name is defined in exactly one place.
7
+ */
8
+ /** Dot-directory name used for both user-level and project-level storage. */
9
+ export declare const AGENT_DOT_DIR = ".qlogicagent";
10
+ /** `~/.qlogicagent/` */
11
+ export declare function getUserAgentHome(): string;
12
+ /** `~/.qlogicagent/sessions/` */
13
+ export declare function getUserSessionsRoot(): string;
14
+ /** `~/.qlogicagent/sessions/{sessionId}` */
15
+ export declare function getUserSessionDir(sessionId: string): string;
16
+ /** `~/.qlogicagent/.credentials.json` */
17
+ export declare function getUserCredentialsPath(): string;
18
+ /** `~/.qlogicagent/plugins/` */
19
+ export declare function getUserPluginsDir(): string;
20
+ /** `~/.qlogicagent/skills/` */
21
+ export declare function getUserSkillsDir(): string;
22
+ /** `~/.qlogicagent/settings.json` */
23
+ export declare function getUserSettingsPath(): string;
24
+ /** `~/.qlogicagent/cache/` */
25
+ export declare function getUserCacheDir(): string;
26
+ /** `~/.qlogicagent/debug-logs/` */
27
+ export declare function getUserDebugLogsDir(): string;
28
+ /** `~/.qlogicagent/checkpoints/` or `~/.qlogicagent/checkpoints/{sessionId}` */
29
+ export declare function getUserCheckpointsDir(sessionId?: string): string;
30
+ /** `~/.qlogicagent/plugin-cache/` */
31
+ export declare function getUserPluginCacheDir(): string;
32
+ /** `~/.qlogicagent/mcp.json` */
33
+ export declare function getUserMcpConfigPath(): string;
34
+ /** `~/.qlogicagent/marketplace.json` */
35
+ export declare function getUserMarketplaceConfigPath(): string;
36
+ /** `~/.qlogicagent/workflows/` */
37
+ export declare function getUserWorkflowsDir(): string;
38
+ /** `~/.qlogicagent/INSTRUCTIONS.md` */
39
+ export declare function getUserInstructionsPath(): string;
40
+ /** `~/.qlogicagent/rules/` */
41
+ export declare function getUserRulesDir(): string;
42
+ /** `<cwd>/.qlogicagent/` */
43
+ export declare function getProjectAgentDir(cwd?: string): string;
44
+ /** `<cwd>/.qlogicagent/workflows/` */
45
+ export declare function getProjectWorkflowsDir(cwd?: string): string;
46
+ /** `<cwd>/.qlogicagent/plugins/` */
47
+ export declare function getProjectPluginsDir(cwd?: string): string;
48
+ /** `<cwd>/.qlogicagent/skills/` */
49
+ export declare function getProjectSkillsDir(cwd?: string): string;
50
+ /** `<cwd>/.qlogicagent/settings.json` */
51
+ export declare function getProjectSettingsPath(cwd?: string): string;
52
+ /** `<cwd>/.qlogicagent/INSTRUCTIONS.md` */
53
+ export declare function getProjectInstructionsPath(cwd?: string): string;
54
+ /** `<cwd>/.qlogicagent/rules/` */
55
+ export declare function getProjectRulesDir(cwd?: string): string;
56
+ /** `<gitRoot>/.qlogicagent/hooks/` */
57
+ export declare function getGitRootHooksDir(gitRoot: string): string;
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Local Checkpoint Backend — git-based shadow repo implementation.
3
+ *
4
+ * Creates and manages checkpoint snapshots in `~/.qlogicagent/checkpoints/<sessionId>/`
5
+ * using a shadow git repository independent of the user's project .git.
6
+ */
7
+ import type { CheckpointToolDeps } from "../../skills/tools/checkpoint-tool.js";
8
+ export declare function createLocalCheckpointBackend(projectRoot: string, sessionId: string): CheckpointToolDeps;
@@ -0,0 +1,36 @@
1
+ /**
2
+ * Disk Storage Manager — unified atomic file I/O for agent self-managed storage.
3
+ *
4
+ * Provides:
5
+ * - Atomic write (tmp + rename) with dir auto-creation
6
+ * - JSON read/write helpers
7
+ * - MemoryStore disk persistence (auto-save on mutation)
8
+ */
9
+ /**
10
+ * Write data atomically: write to a temp file in the same directory,
11
+ * then rename over the target. This prevents partial/corrupted reads.
12
+ */
13
+ export declare function atomicWriteFile(filePath: string, data: string | Buffer): Promise<void>;
14
+ /**
15
+ * Read a JSON file. Returns `undefined` if the file does not exist.
16
+ */
17
+ export declare function readJsonFile<T = unknown>(filePath: string): Promise<T | undefined>;
18
+ /**
19
+ * Write a JSON file atomically.
20
+ */
21
+ export declare function writeJsonFile(filePath: string, data: unknown): Promise<void>;
22
+ /** Path to user-level memory file: `~/.qlogicagent/memory.json` */
23
+ export declare function getMemoryFilePath(): string;
24
+ export interface PersistedMemory {
25
+ memory: string;
26
+ user: string;
27
+ /** ISO 8601 timestamp of last save. */
28
+ savedAt: string;
29
+ }
30
+ /** Load persisted memory from disk. Returns undefined if no file exists. */
31
+ export declare function loadPersistedMemory(): Promise<PersistedMemory | undefined>;
32
+ /** Save memory to disk atomically. */
33
+ export declare function savePersistedMemory(data: {
34
+ memory: string;
35
+ user: string;
36
+ }): Promise<void>;
@@ -10,8 +10,8 @@
10
10
  * this is a lightweight change-awareness system.
11
11
  *
12
12
  * Watched paths:
13
- * - .openclaw/settings.json → permission hot-reload
14
- * - INSTRUCTIONS.md / .openclaw/INSTRUCTIONS.md → instruction re-load
13
+ * - .qlogicagent/settings.json → permission hot-reload
14
+ * - INSTRUCTIONS.md / .qlogicagent/INSTRUCTIONS.md → instruction re-load
15
15
  * - configurable additional patterns
16
16
  *
17
17
  * Reference: claude-code file-watcher usage throughout lifecycle
@@ -1,6 +1,8 @@
1
+ export { AGENT_DOT_DIR, getUserAgentHome, getUserSessionDir, getUserCredentialsPath, getUserPluginsDir, getUserSkillsDir, getUserSettingsPath, getUserCacheDir, getUserDebugLogsDir, getUserCheckpointsDir, getUserPluginCacheDir, getUserMcpConfigPath, getUserMarketplaceConfigPath, getUserWorkflowsDir, getUserInstructionsPath, getProjectAgentDir, getProjectWorkflowsDir, getProjectPluginsDir, getProjectSkillsDir, getProjectSettingsPath, getProjectInstructionsPath, getProjectRulesDir, getGitRootHooksDir, } from "./agent-paths.js";
1
2
  export { getBudgetContinuationMessage } from "./token-budget.js";
2
3
  export { type SecureStorage, saveApiKey, loadApiKey } from "./secure-storage.js";
3
4
  export { createFileWatcher, FileWatcher } from "./file-watcher.js";
4
5
  export { TaskStore } from "./task-runtime.js";
5
6
  export { createWorktreeBackend } from "./worktree-backend.js";
6
7
  export { registerCleanup, runCleanupFunctions } from "./cleanup-registry.js";
8
+ export { atomicWriteFile, readJsonFile, writeJsonFile, loadPersistedMemory, savePersistedMemory, getMemoryFilePath, type PersistedMemory, } from "./disk-storage.js";
@@ -7,7 +7,7 @@
7
7
  * - macOS Keychain / Windows Credential Manager can be added as plugins
8
8
  *
9
9
  * Storage layout:
10
- * ~/.openclaw/.credentials.json — API keys, OAuth tokens
10
+ * ~/.qlogicagent/.credentials.json — API keys, OAuth tokens
11
11
  *
12
12
  * Reference: claude-code-haha/src/utils/secureStorage/
13
13
  */
@@ -9,7 +9,7 @@
9
9
  * Architecture note: CC uses React-style setAppState(prev => next). We use
10
10
  * a simple Map-based store since we're in a subprocess (no React).
11
11
  */
12
- import type { TaskState, TaskType, TaskLifecycle, PermissionRole, IsolationMode, LocalAgentTaskState, LocalBashTaskState } from "../../orchestration/task-types.js";
12
+ import type { TaskState, TaskType, TaskLifecycle, PermissionRole, IsolationMode, LocalAgentTaskState, LocalBashTaskState } from "../../orchestration/subagent/task-types.js";
13
13
  import type { HookRegistry } from "../../contracts/hooks.js";
14
14
  /** Polling interval for running tasks (ms) */
15
15
  export declare const POLL_INTERVAL_MS = 1000;
@@ -2,9 +2,9 @@
2
2
  * Instruction Loader — CC claudemd.ts parity (adapted for qlogicagent).
3
3
  *
4
4
  * Discovers and loads instruction files following CC's load order:
5
- * 1. User instructions (~/.openclaw/INSTRUCTIONS.md)
6
- * 2. Project instructions (INSTRUCTIONS.md, .openclaw/INSTRUCTIONS.md,
7
- * .openclaw/rules/*.md — walkup from cwd to git root)
5
+ * 1. User instructions (~/.qlogicagent/INSTRUCTIONS.md)
6
+ * 2. Project instructions (INSTRUCTIONS.md, .qlogicagent/INSTRUCTIONS.md,
7
+ * .qlogicagent/rules/*.md — walkup from cwd to git root)
8
8
  * 3. Local instructions (INSTRUCTIONS.local.md — private, not checked in)
9
9
  *
10
10
  * Features ported from CC:
@@ -33,11 +33,11 @@ export interface InstructionFileInfo {
33
33
  * Load all instruction files following CC's discovery order.
34
34
  *
35
35
  * Discovery order (priority: last loaded = highest):
36
- * 1. User: ~/.openclaw/INSTRUCTIONS.md, ~/.openclaw/rules/*.md
36
+ * 1. User: ~/.qlogicagent/INSTRUCTIONS.md, ~/.qlogicagent/rules/*.md
37
37
  * 2. Project: Walk from git root → cwd, each dir:
38
38
  * - INSTRUCTIONS.md
39
- * - .openclaw/INSTRUCTIONS.md
40
- * - .openclaw/rules/*.md (unconditional)
39
+ * - .qlogicagent/INSTRUCTIONS.md
40
+ * - .qlogicagent/rules/*.md (unconditional)
41
41
  * 3. Local: INSTRUCTIONS.local.md (per dir, walkup)
42
42
  *
43
43
  * @param cwd - Starting directory for walkup discovery
@@ -44,7 +44,6 @@ export type ForkedAgentRunner = (params: {
44
44
  log: AgentLogger;
45
45
  hooks?: HookRegistry;
46
46
  forkLabel: string;
47
- sidechainType?: "planner" | "research" | "plan-repair" | "code-repair" | "media-prep";
48
47
  maxTurns?: number;
49
48
  parentSignal?: AbortSignal;
50
49
  skipTranscript?: boolean;
@@ -7,7 +7,7 @@
7
7
  * 3. Session metadata (model, cwd, agent mode)
8
8
  *
9
9
  * Storage layout:
10
- * ~/.openclaw/sessions/<session-id>/
10
+ * ~/.qlogicagent/sessions/<session-id>/
11
11
  * transcript.jsonl — append-only message log
12
12
  * state.json — cost snapshot + metadata
13
13
  *
@@ -1,19 +1,17 @@
1
1
  export type { PortableTool, PortableToolResult, ToolContentBlock, } from "./portable-tool.js";
2
- export { ToolRegistry } from "./tool-registry.js";
3
- export { MEMORY_TOOL_NAME, MEMORY_TOOL_MAX_CONTENT_LENGTH, MEMORY_TOOL_ACTIONS, MEMORY_TOOL_SCHEMA, MEMORY_TOOL_DESCRIPTION, MEMORY_TOOL_LABEL, isMemoryContentSafe, executeMemoryTool, } from "./memory-tool.js";
4
- export type { MemoryToolAction, MemoryToolParams, MemoryToolResult, MemoryToolExecutorDeps, } from "./memory-tool.js";
5
- export { MemoryStore, MEMORY_ENTRY_DELIMITER, DEFAULT_MEMORY_CHAR_LIMIT, DEFAULT_USER_CHAR_LIMIT, } from "./memory-store.js";
6
- export type { MemoryStoreTarget, MemoryStoreResult, MemoryStoreOptions, MemoryStoreSerialized, } from "./memory-store.js";
7
- export { createQMemoryAdapter } from "./qmemory-adapter.js";
8
- export type { QMemoryAdapterConfig, QMemoryHealthStatus, ExtractedMemoryItem } from "./qmemory-adapter.js";
9
- export { createMemoryExtractor } from "./memory-extractor.js";
10
- export type { ExtractedMemory, ProfileUpdate, ExtractionResult, ExtractionCompleteFn, MemoryExtractorOptions, } from "./memory-extractor.js";
2
+ export { setToolPool, addTool, addTools, removeTool, findTool, hasTool, getToolNames, getToolCount, executeTool, getToolManifest, getTools, AGENT_DISALLOWED_TOOLS, CUSTOM_AGENT_DISALLOWED_TOOLS, filterToolsForAgent, } from "./tools.js";
3
+ export { MEMORY_TOOL_NAME, MEMORY_TOOL_MAX_CONTENT_LENGTH, MEMORY_TOOL_ACTIONS, MEMORY_TOOL_SCHEMA, MEMORY_TOOL_DESCRIPTION, MEMORY_TOOL_LABEL, isMemoryContentSafe, executeMemoryTool, } from "./memory/memory-tool.js";
4
+ export type { MemoryToolAction, MemoryToolParams, MemoryToolResult, MemoryToolExecutorDeps, MediaPreferencesSummary, } from "./memory/memory-tool.js";
5
+ export { MemoryStore, MEMORY_ENTRY_DELIMITER, DEFAULT_MEMORY_CHAR_LIMIT, DEFAULT_USER_CHAR_LIMIT, } from "./memory/memory-store.js";
6
+ export type { MemoryStoreTarget, MemoryStoreResult, MemoryStoreOptions, MemoryStoreSerialized, } from "./memory/memory-store.js";
7
+ export { createQMemoryAdapter } from "./memory/qmemory-adapter.js";
8
+ export type { QMemoryAdapterConfig, QMemoryHealthStatus, ExtractedMemoryItem } from "./memory/qmemory-adapter.js";
9
+ export { createMemoryExtractor } from "./memory/memory-extractor.js";
10
+ export type { ExtractedMemory, ProfileUpdate, ExtractionResult, ExtractionCompleteFn, MemoryExtractorOptions, } from "./memory/memory-extractor.js";
11
11
  export { THINK_TOOL_NAME, THINK_TOOL_SCHEMA, createThinkTool } from "./think-tool.js";
12
12
  export type { ThinkToolParams } from "./think-tool.js";
13
- export { TODO_TOOL_NAME, TODO_TOOL_SCHEMA, createTodoTool } from "./todo-tool.js";
14
- export type { TodoToolParams, TodoToolOptions } from "./todo-tool.js";
15
- export { MEMORY_QUERY_TOOL_NAME, MEMORY_QUERY_TOOL_SCHEMA, createMemoryQueryTool, } from "./memory-query-tool.js";
16
- export type { MemoryQueryToolParams, MemoryQueryToolDeps, MediaPreferencesSummary, } from "./memory-query-tool.js";
13
+ export { TODO_TOOL_NAME, TODO_TOOL_SCHEMA, TODO_ACTIONS, createTodoTool } from "./todo-tool.js";
14
+ export type { TodoToolParams, TodoToolOptions, TodoAction } from "./todo-tool.js";
17
15
  export { READ_TOOL_NAME, READ_TOOL_SCHEMA, createReadTool } from "./tools/read-tool.js";
18
16
  export type { ReadToolParams, ReadToolDeps, ReadResultType } from "./tools/read-tool.js";
19
17
  export { WRITE_TOOL_NAME, WRITE_TOOL_SCHEMA, createWriteTool } from "./tools/write-tool.js";
@@ -22,8 +20,6 @@ export { EDIT_TOOL_NAME, EDIT_TOOL_SCHEMA, createEditTool } from "./tools/edit-t
22
20
  export type { EditToolParams, EditToolDeps } from "./tools/edit-tool.js";
23
21
  export { APPLY_PATCH_TOOL_NAME, APPLY_PATCH_TOOL_SCHEMA, createApplyPatchTool } from "./tools/apply-patch-tool.js";
24
22
  export type { ApplyPatchToolParams, ApplyPatchToolDeps, ApplyPatchSummary } from "./tools/apply-patch-tool.js";
25
- export { PDF_TOOL_NAME, PDF_TOOL_SCHEMA, createPdfTool } from "./tools/pdf-tool.js";
26
- export type { PdfToolParams, PdfToolDeps } from "./tools/pdf-tool.js";
27
23
  export { EXEC_TOOL_NAME, EXEC_TOOL_SCHEMA, createExecTool, ASSISTANT_BLOCKING_BUDGET_MS } from "./tools/exec-tool.js";
28
24
  export type { ExecToolParams, ExecToolHost, ExecProgress, ExecToolOutput } from "./tools/exec-tool.js";
29
25
  export { isPowerShellToolEnabled, getDefaultShellType, generateCommandId, createBashProvider, createPowerShellProvider, encodePowerShellCommand, classifyCommand, commandHasAnyCd, SEARCH_COMMANDS, READ_COMMANDS, LIST_COMMANDS, SILENT_COMMANDS, SAFE_ENV_VARS, BARE_SHELL_PREFIXES, stripSafeWrappers, stripAllLeadingEnvVars, getSimpleCommandPrefix, getFirstWordPrefix, stripWrappersFromArgv, detectBlockedSleepPattern, TaskOutput, generateTaskId, getTaskOutputDir, setTaskOutputDir, getTaskOutputPath, MAX_TASK_OUTPUT_BYTES, wrapSpawn, createAbortedCommand, createFailedCommand, exec, getCwd, setCwd, initCwd, getOriginalCwd, setShellProvider, getShellProvider, } from "./tools/shell/index.js";
@@ -72,8 +68,6 @@ export { BROWSER_TOOL_NAME, BROWSER_TOOL_SCHEMA, createBrowserTool } from "./too
72
68
  export type { BrowserToolParams, BrowserToolDeps, BrowserAction, BrowserSnapshot, BrowserScreenshot } from "./tools/browser-tool.js";
73
69
  export { CRON_TOOL_NAME, CRON_TOOL_SCHEMA, MAX_CRON_JOBS, createCronTool } from "./tools/cron-tool.js";
74
70
  export type { CronToolParams, CronToolDeps, CronJob, CronResult, CronAction } from "./tools/cron-tool.js";
75
- export { MEMORY_SEARCH_TOOL_NAME, MEMORY_SEARCH_TOOL_SCHEMA, createMemorySearchTool } from "./tools/memory-tool.js";
76
- export type { MemorySearchToolParams, MemorySearchToolDeps, MemoryEntry, MemoryQueryOutput, MemorySource } from "./tools/memory-tool.js";
77
71
  export { CHECKPOINT_TOOL_NAME, CHECKPOINT_TOOL_SCHEMA, createCheckpointTool } from "./tools/checkpoint-tool.js";
78
72
  export type { CheckpointToolParams, CheckpointToolDeps, Checkpoint, CheckpointResult, CheckpointAction } from "./tools/checkpoint-tool.js";
79
73
  export { NOTIFY_TOOL_NAME, NOTIFY_TOOL_SCHEMA, createNotifyTool } from "./tools/notify-tool.js";
@@ -100,15 +94,15 @@ export { MONITOR_TOOL_NAME, MONITOR_TOOL_SCHEMA, createMonitorTool } from "./too
100
94
  export type { MonitorToolParams, MonitorToolDeps, MonitorSource, MonitorAction, MonitorCondition, MonitorInfo, MonitorResult, } from "./tools/monitor-tool.js";
101
95
  export { STRUCTURED_OUTPUT_TOOL_NAME, STRUCTURED_OUTPUT_TOOL_SCHEMA, STRUCTURED_OUTPUT_MAX_CHARS, createStructuredOutputTool, createConfiguredStructuredOutputTool, isStructuredOutputEnabled, } from "./tools/structured-output-tool.js";
102
96
  export type { StructuredOutputToolParams, StructuredOutputToolDeps, StructuredOutputResult, SchemaValidationError, ConfiguredToolResult, SchemaCompiler, } from "./tools/structured-output-tool.js";
103
- export { INSTRUCTIONS_LIST_TOOL_NAME, INSTRUCTIONS_LIST_SCHEMA, createInstructionsListTool, INSTRUCTIONS_READ_TOOL_NAME, INSTRUCTIONS_READ_SCHEMA, createInstructionsReadTool, INSTRUCTIONS_WRITE_TOOL_NAME, INSTRUCTIONS_WRITE_SCHEMA, createInstructionsWriteTool, INSTRUCTIONS_DELETE_TOOL_NAME, INSTRUCTIONS_DELETE_SCHEMA, createInstructionsDeleteTool, } from "./tools/instructions-tool.js";
104
- export type { InstructionFileInfo, InstructionFileContent, InstructionsToolDeps, InstructionsListParams, InstructionsReadParams, InstructionsWriteParams, InstructionsDeleteParams, } from "./tools/instructions-tool.js";
105
- export type { ParsedSkillFrontmatter, WorkspaceSkill, SkillInstallSpec, SkillMetadata, SkillInvocationPolicy, SkillEntry, SkillCommandDispatchSpec, SkillCommandSpec, SkillSnapshot, SkillScanSeverity, SkillScanFinding, SkillScanSummary, SkillScanOptions, SkillFsDeps, SkillPathDeps, SkillLoadLimits, SkillSearchPaths, SkillLoaderDeps, } from "./skill-types.js";
106
- export { parseFrontmatter, resolveSkillMetadata, resolveSkillInvocationPolicy, resolveSkillKey, } from "./skill-frontmatter.js";
107
- export { loadSkillEntries, filterSkillEntries, buildSkillSnapshot, } from "./skill-loader.js";
108
- export { scanSource, scanSkillDirectory, hasCriticalFindings, isScannable, } from "./skill-guard.js";
109
- export type { SkillGuardDeps } from "./skill-guard.js";
110
- export { installSkill, uninstallSkill, createEmptyLockfile, } from "./skill-source.js";
111
- export type { TrustLevel, ScanVerdict, SkillSourceDescriptor, SkillFetchResult, SkillFetchDeps, SkillStorageDeps, SkillLockEntry, SkillLockfile, SkillInstallResult, } from "./skill-source.js";
97
+ export { INSTRUCTIONS_TOOL_NAME, INSTRUCTIONS_TOOL_SCHEMA, createInstructionsTool, } from "./tools/instructions-tool.js";
98
+ export type { InstructionFileInfo, InstructionFileContent, InstructionsToolDeps, InstructionsAction, InstructionsToolParams, } from "./tools/instructions-tool.js";
99
+ export type { ParsedSkillFrontmatter, WorkspaceSkill, SkillInstallSpec, SkillMetadata, SkillInvocationPolicy, SkillEntry, SkillCommandDispatchSpec, SkillCommandSpec, SkillSnapshot, SkillScanSeverity, SkillScanFinding, SkillScanSummary, SkillScanOptions, SkillFsDeps, SkillPathDeps, SkillLoadLimits, SkillSearchPaths, SkillLoaderDeps, } from "./skill-system/skill-types.js";
100
+ export { parseFrontmatter, resolveSkillMetadata, resolveSkillInvocationPolicy, resolveSkillKey, } from "./skill-system/skill-frontmatter.js";
101
+ export { loadSkillEntries, filterSkillEntries, buildSkillSnapshot, } from "./skill-system/skill-loader.js";
102
+ export { scanSource, scanSkillDirectory, hasCriticalFindings, isScannable, } from "./skill-system/skill-guard.js";
103
+ export type { SkillGuardDeps } from "./skill-system/skill-guard.js";
104
+ export { installSkill, uninstallSkill, createEmptyLockfile, } from "./skill-system/skill-source.js";
105
+ export type { TrustLevel, ScanVerdict, SkillSourceDescriptor, SkillFetchResult, SkillFetchDeps, SkillStorageDeps, SkillLockEntry, SkillLockfile, SkillInstallResult, } from "./skill-system/skill-source.js";
112
106
  export { SKILL_TOOL_NAME, SKILL_INVOKE_SCHEMA, createSkillTool } from "./tools/skill-invoke-tool.js";
113
107
  export type { SkillInvokeParams, SkillToolDeps } from "./tools/skill-invoke-tool.js";
114
108
  export { McpStdioClient } from "./mcp/mcp-stdio-client.js";