qlogicagent 2.10.23 → 2.10.25

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.
@@ -1,3 +1,5 @@
1
+ import type { TurnConfig } from "../agent/types.js";
2
+ import { type ModelRegistry } from "../runtime/infra/model-registry.js";
1
3
  import { type MediaClient } from "./provider-core-facade.js";
2
4
  interface MediaUsageRecorder {
3
5
  addMediaUsage(model: string, billingUnit: string, quantity: number): void;
@@ -8,6 +10,7 @@ export interface TurnMediaSetupHost {
8
10
  sessionState?: MediaUsageRecorder | null;
9
11
  sendNotification(method: string, params: Record<string, unknown>): void;
10
12
  }
13
+ export declare function deriveMediaProvidersFromBindings(registry: Pick<ModelRegistry, "getBinding">): TurnConfig["mediaProviders"];
11
14
  export declare function configureTurnMedia(params: {
12
15
  host: TurnMediaSetupHost;
13
16
  config?: Record<string, unknown>;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,42 @@
1
+ /**
2
+ * QlogicagentExecutorHost — the REAL host backing host-executors (agent/tool/http/mcp/channel)
3
+ * with qlogicagent's actual capabilities. No mocks, no stubs (plan §1.5).
4
+ *
5
+ * Boundary capabilities (runAgent / invokeMcp / sendChannel) are injected so this file stays
6
+ * decoupled from the handler host that owns processManager/acpDetector and the openclaw channel
7
+ * callback. Tool invocation goes straight through the single-source-of-truth tool registry
8
+ * (`findTool`). fail-loud everywhere: unknown tool, missing channel host, or any rejection throws.
9
+ */
10
+ import type { PortableTool } from "../../skills/portable-tool.js";
11
+ import type { ExecutorHost } from "./node-schema.js";
12
+ /** Injected boundary capabilities — supplied by the handler host that owns the real runners. */
13
+ export interface QlaExecutorHostDeps {
14
+ /** Run one agent turn (spawn external ACP agent + sendTask). Returns the agent's text output. */
15
+ runAgent: (req: {
16
+ agentId?: string;
17
+ prompt: string;
18
+ signal?: AbortSignal;
19
+ }) => Promise<string>;
20
+ /** Invoke an MCP server tool through the real MCP bridge. */
21
+ invokeMcp: (req: {
22
+ server: string;
23
+ tool: string;
24
+ args: Record<string, unknown>;
25
+ signal?: AbortSignal;
26
+ }) => Promise<unknown>;
27
+ /**
28
+ * Send a message out through a channel via the openclaw channel layer.
29
+ * Undefined in standalone qlogicagent (no gateway) → channel nodes fail-loud (D12/D13).
30
+ */
31
+ sendChannel?: (req: {
32
+ channel: string;
33
+ target?: string;
34
+ payload: unknown;
35
+ signal?: AbortSignal;
36
+ }) => Promise<unknown>;
37
+ /** Tool lookup; defaults to the real registry. Injectable for tests. */
38
+ findTool?: (name: string) => PortableTool | undefined;
39
+ /** fetch impl; defaults to global fetch. Injectable for tests. */
40
+ fetchImpl?: typeof fetch;
41
+ }
42
+ export declare function createQlaExecutorHost(deps: QlaExecutorHostDeps): ExecutorHost;
@@ -9,6 +9,10 @@
9
9
  export declare const AGENT_DOT_DIR = ".qlogicagent";
10
10
  /** `~/.qlogicagent/` (or QLOGICAGENT_HOME override) */
11
11
  export declare function getUserAgentHome(): string;
12
+ /** Legacy pre-profile user settings path: `~/.qlogicagent/settings.json`. */
13
+ export declare function getLegacyUserSettingsPath(): string;
14
+ /** Legacy pre-profile local memory database path: `~/.qlogicagent/memory/memories.db`. */
15
+ export declare function getLegacyMemoryDbPath(): string;
12
16
  export declare function resolveActiveOwnerUserId(): string;
13
17
  export declare function encodeOwnerProfileSegment(ownerUserId: string): string;
14
18
  export declare function getOwnerProfileDir(ownerUserId?: string): string;
@@ -24,6 +24,8 @@ export interface LocalMemoryProviderConfig {
24
24
  userIdPrefix?: string;
25
25
  /** Factory function to create the SQLite database instance. */
26
26
  createDatabase?: (dbPath: string) => SqliteDatabase;
27
+ /** Import legacy pre-profile memory DB into the owner profile on startup. */
28
+ migrateLegacyMemory?: boolean;
27
29
  }
28
30
  export declare class LocalMemoryProvider implements MemoryProvider {
29
31
  readonly providerId = "qmemory-local";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "qlogicagent",
3
- "version": "2.10.23",
3
+ "version": "2.10.25",
4
4
  "description": "XiaozhiClaw Agent CLI — subprocess architecture (JSON-RPC over stdio)",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -76,7 +76,7 @@
76
76
  "node": ">=22.0.0"
77
77
  },
78
78
  "dependencies": {
79
- "@xiaozhiclaw/provider-core": "^0.1.0",
79
+ "@xiaozhiclaw/provider-core": "^0.1.0",
80
80
  "better-sqlite3": "^12.10.0",
81
81
  "dotenv": "^17.3.1",
82
82
  "nanoid": "^5.1.5",