qlogicagent 2.17.3 → 2.17.5
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/agent.js +23 -20
- package/dist/cli.js +403 -400
- package/dist/index.js +402 -399
- package/dist/types/agent/tool-loop/artifact-final-contract.d.ts +55 -8
- package/dist/types/cli/handlers/turn-handler.d.ts +0 -6
- package/dist/types/runtime/infra/agent-process.d.ts +4 -0
- package/dist/types/skills/memory/local-store.d.ts +1 -1
- package/package.json +3 -2
|
@@ -16,6 +16,16 @@ export interface ArtifactContractState {
|
|
|
16
16
|
buildVerified: boolean;
|
|
17
17
|
buildEvidence: string[];
|
|
18
18
|
buildFailureEvidence: string[];
|
|
19
|
+
/**
|
|
20
|
+
* Ledger sizes recovered from prior turns' history at turn start. The recovered ledger keeps
|
|
21
|
+
* cross-turn claims reconcilable (a model may legitimately cite files written last turn), but
|
|
22
|
+
* it is NOT this turn's evidence — the engine fallback block only fires on new entries.
|
|
23
|
+
*/
|
|
24
|
+
recoveredBaseline?: {
|
|
25
|
+
writePaths: number;
|
|
26
|
+
devServerUrls: number;
|
|
27
|
+
artifactRoot: boolean;
|
|
28
|
+
};
|
|
19
29
|
}
|
|
20
30
|
export interface ArtifactContractEventPayload {
|
|
21
31
|
artifactRoot?: string;
|
|
@@ -39,10 +49,40 @@ export interface TaskContractItem {
|
|
|
39
49
|
export declare function createArtifactContractState(inputMessages: readonly ChatMessage[]): ArtifactContractState;
|
|
40
50
|
export declare function requiresBrowserAcceptance(inputMessages: readonly ChatMessage[]): boolean;
|
|
41
51
|
export declare function requiresBuildVerification(inputMessages: readonly ChatMessage[]): boolean;
|
|
42
|
-
export
|
|
43
|
-
export
|
|
44
|
-
export
|
|
45
|
-
|
|
52
|
+
export type FinalStatusBrowserVerdict = "verified" | "failed" | "not-run";
|
|
53
|
+
export type FinalStatusBuildVerdict = "passed" | "failed" | "not-run";
|
|
54
|
+
export interface FinalStatusClaim {
|
|
55
|
+
schema: number;
|
|
56
|
+
author?: "model" | "engine";
|
|
57
|
+
done?: string[];
|
|
58
|
+
notDone?: string[];
|
|
59
|
+
artifacts?: {
|
|
60
|
+
root?: string;
|
|
61
|
+
files?: string[];
|
|
62
|
+
urls?: string[];
|
|
63
|
+
};
|
|
64
|
+
verification?: {
|
|
65
|
+
browser?: FinalStatusBrowserVerdict;
|
|
66
|
+
build?: FinalStatusBuildVerdict;
|
|
67
|
+
};
|
|
68
|
+
sources?: {
|
|
69
|
+
cited?: string[];
|
|
70
|
+
};
|
|
71
|
+
blockers?: string[];
|
|
72
|
+
nextAction?: string;
|
|
73
|
+
}
|
|
74
|
+
export interface ParsedFinalStatusBlock {
|
|
75
|
+
/** null = a block was present but not valid schema-1 JSON (malformed). */
|
|
76
|
+
claim: FinalStatusClaim | null;
|
|
77
|
+
start: number;
|
|
78
|
+
end: number;
|
|
79
|
+
}
|
|
80
|
+
/** The final-status contract applies only to turns whose tool surface can produce artifacts or run verification. */
|
|
81
|
+
export declare function finalStatusContractApplies(toolNames: Iterable<string>): boolean;
|
|
82
|
+
export declare const FINAL_STATUS_PROMPT_CONTRACT: string;
|
|
83
|
+
/** Locate and parse the last ```final-status block. Returns null when no block exists. */
|
|
84
|
+
export declare function parseFinalStatusBlock(content: string): ParsedFinalStatusBlock | null;
|
|
85
|
+
export declare function renderFinalStatusBlock(claim: FinalStatusClaim): string;
|
|
46
86
|
export declare function toolCallWritePath(toolName: string, rawArguments: string): string | null;
|
|
47
87
|
export declare function resolveArtifactRootWriteBlock(params: {
|
|
48
88
|
state: ArtifactContractState;
|
|
@@ -77,10 +117,15 @@ export declare function updateArtifactContractFromToolResult(params: {
|
|
|
77
117
|
export declare function artifactContractPayload(state: ArtifactContractState, inputMessages: readonly ChatMessage[]): ArtifactContractEventPayload;
|
|
78
118
|
export declare function recoverArtifactContractState(inputMessages: readonly ChatMessage[]): ArtifactContractState;
|
|
79
119
|
export declare function updateArtifactContractFromFinalContent(state: ArtifactContractState, content: string): void;
|
|
80
|
-
export
|
|
120
|
+
export interface FinalStatusReconciliation {
|
|
81
121
|
content: string;
|
|
82
|
-
|
|
83
|
-
|
|
122
|
+
/** A ```final-status block was present but not valid schema-1 JSON (treated as absent). */
|
|
123
|
+
malformedBlock: boolean;
|
|
124
|
+
}
|
|
125
|
+
export declare function reconcileFinalStatus(params: {
|
|
126
|
+
content: string;
|
|
127
|
+
/** From finalStatusContractApplies() over the turn's tool surface; inactive turns pass through untouched. */
|
|
128
|
+
contractActive: boolean;
|
|
84
129
|
totalToolCallCount: number;
|
|
85
130
|
distinctToolNames: Iterable<string>;
|
|
86
131
|
visibleToolCallCount?: number;
|
|
@@ -91,4 +136,6 @@ export declare function applyFinalStatusContract(params: {
|
|
|
91
136
|
reason: string;
|
|
92
137
|
}>;
|
|
93
138
|
activeTasks?: readonly TaskContractItem[];
|
|
94
|
-
|
|
139
|
+
/** The turn ended on a forced/failure terminal rather than a clean model stop. */
|
|
140
|
+
forcedStop?: boolean;
|
|
141
|
+
}): FinalStatusReconciliation;
|
|
@@ -18,12 +18,6 @@ export interface TurnControlHandlerHost {
|
|
|
18
18
|
sendResponse(id: string | number, result?: unknown, error?: unknown): void;
|
|
19
19
|
}
|
|
20
20
|
export declare function hydrateTurnConfigFromModelMetadata(config: TurnConfig): TurnConfig;
|
|
21
|
-
export declare function resolveAutoToolChoice(params: {
|
|
22
|
-
currentToolChoice?: TurnConfig["toolChoice"];
|
|
23
|
-
explicitNoToolTurn: boolean;
|
|
24
|
-
looksLikeBuildIntent: boolean;
|
|
25
|
-
requiresPreToolPreamble?: boolean;
|
|
26
|
-
}): TurnConfig["toolChoice"] | undefined;
|
|
27
21
|
export declare function hydrateAttachmentReferenceUrlsForTurn(messages: ChatMessage[]): ChatMessage[];
|
|
28
22
|
export declare function getFocusedAttachmentToolNamesForTurn(messages: ChatMessage[]): Set<string> | null;
|
|
29
23
|
type FocusedAttachmentModelPurpose = "imageUnderstanding" | "videoUnderstanding";
|
|
@@ -53,6 +53,10 @@ export interface AgentProcessConfig {
|
|
|
53
53
|
/** System prompt to inject into ACP session. */
|
|
54
54
|
systemPrompt?: string;
|
|
55
55
|
}
|
|
56
|
+
export declare function buildExternalAcpSpawnCommand(cliPath: string, acpArgs: string[]): {
|
|
57
|
+
command: string;
|
|
58
|
+
args: string[];
|
|
59
|
+
};
|
|
56
60
|
/** Snapshot of ongoing media generation progress reported by a child agent. */
|
|
57
61
|
export interface MediaProgressSnapshot {
|
|
58
62
|
/** Provider-specific task ID (e.g. volcengine job id). */
|
|
@@ -195,7 +195,7 @@ export declare class LocalMemoryStore {
|
|
|
195
195
|
}>;
|
|
196
196
|
};
|
|
197
197
|
/**
|
|
198
|
-
* Find memories related to a specific event date (
|
|
198
|
+
* Find memories related to a specific event date (±tolerance).
|
|
199
199
|
* Used for temporal context retrieval, such as finding memories around a requested date.
|
|
200
200
|
*/
|
|
201
201
|
findByEventDate(userId: string, targetDate: string, toleranceDays?: number): MemorySearchHit[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "qlogicagent",
|
|
3
|
-
"version": "2.17.
|
|
3
|
+
"version": "2.17.5",
|
|
4
4
|
"description": "XiaozhiClaw Agent CLI — subprocess architecture (JSON-RPC over stdio)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -69,10 +69,11 @@
|
|
|
69
69
|
"build:search-svc": "node scripts/build-search-svc.mjs",
|
|
70
70
|
"start": "node dist/cli.js",
|
|
71
71
|
"test": "vitest run",
|
|
72
|
-
"check": "tsc --noEmit && pnpm test && pnpm run check:architecture-boundaries && pnpm run check:provider-core-boundary && pnpm run check:provider-core-release-sync && pnpm run check:pet-core-boundary && pnpm run check:workspace-hygiene && pnpm run check:package-artifact",
|
|
72
|
+
"check": "pnpm run check:encoding-corruption && tsc --noEmit && pnpm test && pnpm run check:architecture-boundaries && pnpm run check:provider-core-boundary && pnpm run check:provider-core-release-sync && pnpm run check:pet-core-boundary && pnpm run check:workspace-hygiene && pnpm run check:package-artifact",
|
|
73
73
|
"test:watch": "vitest",
|
|
74
74
|
"benchmark:hermes-superiority": "tsx benchmarks/hermes-superiority/runner.ts",
|
|
75
75
|
"lint": "oxlint .",
|
|
76
|
+
"check:encoding-corruption": "node scripts/check-encoding-corruption.mjs",
|
|
76
77
|
"check:architecture-boundaries": "node scripts/check-architecture-boundaries.mjs",
|
|
77
78
|
"check:provider-core-boundary": "node scripts/check-provider-core-boundary.mjs",
|
|
78
79
|
"check:provider-core-release-sync": "node scripts/check-provider-core-release-sync.mjs",
|