qlogicagent 0.2.1 → 0.4.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.
- package/README.md +45 -45
- package/package.json +56 -42
- package/dist/agent/agent.d.ts +0 -43
- package/dist/agent/agent.js +0 -113
- package/dist/agent/tool-loop.d.ts +0 -64
- package/dist/agent/tool-loop.js +0 -575
- package/dist/agent/types.d.ts +0 -175
- package/dist/agent/types.js +0 -14
- package/dist/cli/main.d.ts +0 -11
- package/dist/cli/main.js +0 -23
- package/dist/cli/stdio-server.d.ts +0 -45
- package/dist/cli/stdio-server.js +0 -463
- package/dist/config/config.d.ts +0 -17
- package/dist/config/config.js +0 -21
- package/dist/contracts/hooks.d.ts +0 -120
- package/dist/contracts/hooks.js +0 -7
- package/dist/contracts/index.d.ts +0 -10
- package/dist/contracts/index.js +0 -10
- package/dist/contracts/planner.d.ts +0 -35
- package/dist/contracts/planner.js +0 -2
- package/dist/contracts/skill-candidate.d.ts +0 -63
- package/dist/contracts/skill-candidate.js +0 -195
- package/dist/contracts/todo.d.ts +0 -14
- package/dist/contracts/todo.js +0 -9
- package/dist/index.d.ts +0 -13
- package/dist/index.js +0 -15
- package/dist/llm/builtin-providers.d.ts +0 -10
- package/dist/llm/builtin-providers.js +0 -531
- package/dist/llm/index.d.ts +0 -15
- package/dist/llm/index.js +0 -14
- package/dist/llm/llm-client.d.ts +0 -43
- package/dist/llm/llm-client.js +0 -67
- package/dist/llm/model-catalog.d.ts +0 -53
- package/dist/llm/model-catalog.js +0 -191
- package/dist/llm/provider-def.d.ts +0 -59
- package/dist/llm/provider-def.js +0 -12
- package/dist/llm/provider-registry.d.ts +0 -54
- package/dist/llm/provider-registry.js +0 -147
- package/dist/llm/transport.d.ts +0 -62
- package/dist/llm/transport.js +0 -27
- package/dist/llm/transports/anthropic-messages.d.ts +0 -31
- package/dist/llm/transports/anthropic-messages.js +0 -293
- package/dist/llm/transports/openai-chat.d.ts +0 -36
- package/dist/llm/transports/openai-chat.js +0 -165
- package/dist/orchestration/agent-registry.d.ts +0 -41
- package/dist/orchestration/agent-registry.js +0 -116
- package/dist/orchestration/approval-aware-tool-plan.d.ts +0 -32
- package/dist/orchestration/approval-aware-tool-plan.js +0 -87
- package/dist/orchestration/context-compression.d.ts +0 -220
- package/dist/orchestration/context-compression.js +0 -583
- package/dist/orchestration/conversation-repair.d.ts +0 -61
- package/dist/orchestration/conversation-repair.js +0 -429
- package/dist/orchestration/curator-scheduler.d.ts +0 -119
- package/dist/orchestration/curator-scheduler.js +0 -135
- package/dist/orchestration/embedded-failover-policy.d.ts +0 -110
- package/dist/orchestration/embedded-failover-policy.js +0 -168
- package/dist/orchestration/error-classification.d.ts +0 -12
- package/dist/orchestration/error-classification.js +0 -77
- package/dist/orchestration/failover-classification.d.ts +0 -8
- package/dist/orchestration/failover-classification.js +0 -381
- package/dist/orchestration/failover-error.d.ts +0 -33
- package/dist/orchestration/failover-error.js +0 -198
- package/dist/orchestration/fork-subagent.d.ts +0 -100
- package/dist/orchestration/fork-subagent.js +0 -98
- package/dist/orchestration/index.d.ts +0 -120
- package/dist/orchestration/index.js +0 -267
- package/dist/orchestration/memory-flush-policy.d.ts +0 -57
- package/dist/orchestration/memory-flush-policy.js +0 -85
- package/dist/orchestration/memory-provider.d.ts +0 -14
- package/dist/orchestration/memory-provider.js +0 -2
- package/dist/orchestration/parallel-tool-calls.d.ts +0 -41
- package/dist/orchestration/parallel-tool-calls.js +0 -59
- package/dist/orchestration/prompt-cache-strategy.d.ts +0 -126
- package/dist/orchestration/prompt-cache-strategy.js +0 -228
- package/dist/orchestration/reactive-compact.d.ts +0 -73
- package/dist/orchestration/reactive-compact.js +0 -78
- package/dist/orchestration/retry-loop.d.ts +0 -22
- package/dist/orchestration/retry-loop.js +0 -24
- package/dist/orchestration/skill-candidate.d.ts +0 -52
- package/dist/orchestration/skill-candidate.js +0 -141
- package/dist/orchestration/skill-consolidation.d.ts +0 -123
- package/dist/orchestration/skill-consolidation.js +0 -220
- package/dist/orchestration/skill-improvement.d.ts +0 -59
- package/dist/orchestration/skill-improvement.js +0 -66
- package/dist/orchestration/skill-similarity.d.ts +0 -98
- package/dist/orchestration/skill-similarity.js +0 -131
- package/dist/orchestration/streaming-tool-executor.d.ts +0 -73
- package/dist/orchestration/streaming-tool-executor.js +0 -96
- package/dist/orchestration/team-orchestration.d.ts +0 -195
- package/dist/orchestration/team-orchestration.js +0 -369
- package/dist/orchestration/team-tool-loop-wiring.d.ts +0 -92
- package/dist/orchestration/team-tool-loop-wiring.js +0 -147
- package/dist/orchestration/tool-choice-policy.d.ts +0 -54
- package/dist/orchestration/tool-choice-policy.js +0 -164
- package/dist/orchestration/tool-loop-state.d.ts +0 -50
- package/dist/orchestration/tool-loop-state.js +0 -133
- package/dist/orchestration/tool-schema.d.ts +0 -39
- package/dist/orchestration/tool-schema.js +0 -297
- package/dist/orchestration/transcript-repair.d.ts +0 -42
- package/dist/orchestration/transcript-repair.js +0 -426
- package/dist/orchestration/turn-loop-guard.d.ts +0 -86
- package/dist/orchestration/turn-loop-guard.js +0 -92
- package/dist/orchestration/web-browser-policy.d.ts +0 -17
- package/dist/orchestration/web-browser-policy.js +0 -39
- package/dist/runtime/context-compression.d.ts +0 -61
- package/dist/runtime/context-compression.js +0 -274
- package/dist/runtime/hook-registry.d.ts +0 -12
- package/dist/runtime/hook-registry.js +0 -53
- package/dist/runtime/memory-hooks.d.ts +0 -23
- package/dist/runtime/memory-hooks.js +0 -65
- package/dist/runtime/tool-eligibility.d.ts +0 -59
- package/dist/runtime/tool-eligibility.js +0 -111
- package/dist/skills/index.d.ts +0 -108
- package/dist/skills/index.js +0 -82
- package/dist/skills/memory-extractor.d.ts +0 -64
- package/dist/skills/memory-extractor.js +0 -173
- package/dist/skills/memory-query-tool.d.ts +0 -43
- package/dist/skills/memory-query-tool.js +0 -127
- package/dist/skills/memory-store.d.ts +0 -66
- package/dist/skills/memory-store.js +0 -228
- package/dist/skills/memory-tool.d.ts +0 -67
- package/dist/skills/memory-tool.js +0 -192
- package/dist/skills/portable-tool.d.ts +0 -71
- package/dist/skills/portable-tool.js +0 -14
- package/dist/skills/qmemory-adapter.d.ts +0 -52
- package/dist/skills/qmemory-adapter.js +0 -165
- package/dist/skills/skill-frontmatter.d.ts +0 -19
- package/dist/skills/skill-frontmatter.js +0 -344
- package/dist/skills/skill-guard.d.ts +0 -23
- package/dist/skills/skill-guard.js +0 -229
- package/dist/skills/skill-loader.d.ts +0 -16
- package/dist/skills/skill-loader.js +0 -303
- package/dist/skills/skill-source.d.ts +0 -119
- package/dist/skills/skill-source.js +0 -126
- package/dist/skills/skill-types.d.ts +0 -199
- package/dist/skills/skill-types.js +0 -6
- package/dist/skills/think-tool.d.ts +0 -16
- package/dist/skills/think-tool.js +0 -59
- package/dist/skills/todo-tool.d.ts +0 -63
- package/dist/skills/todo-tool.js +0 -114
- package/dist/skills/tools/agent-tool.d.ts +0 -91
- package/dist/skills/tools/agent-tool.js +0 -142
- package/dist/skills/tools/apply-patch-tool.d.ts +0 -29
- package/dist/skills/tools/apply-patch-tool.js +0 -184
- package/dist/skills/tools/ask-user-tool.d.ts +0 -80
- package/dist/skills/tools/ask-user-tool.js +0 -121
- package/dist/skills/tools/brief-tool.d.ts +0 -74
- package/dist/skills/tools/brief-tool.js +0 -95
- package/dist/skills/tools/browser-tool.d.ts +0 -114
- package/dist/skills/tools/browser-tool.js +0 -155
- package/dist/skills/tools/checkpoint-tool.d.ts +0 -66
- package/dist/skills/tools/checkpoint-tool.js +0 -102
- package/dist/skills/tools/config-tool.d.ts +0 -63
- package/dist/skills/tools/config-tool.js +0 -143
- package/dist/skills/tools/cron-tool.d.ts +0 -116
- package/dist/skills/tools/cron-tool.js +0 -175
- package/dist/skills/tools/edit-tool.d.ts +0 -43
- package/dist/skills/tools/edit-tool.js +0 -70
- package/dist/skills/tools/exec-tool.d.ts +0 -102
- package/dist/skills/tools/exec-tool.js +0 -133
- package/dist/skills/tools/image-generate-tool.d.ts +0 -62
- package/dist/skills/tools/image-generate-tool.js +0 -67
- package/dist/skills/tools/instructions-tool.d.ts +0 -103
- package/dist/skills/tools/instructions-tool.js +0 -187
- package/dist/skills/tools/lsp-tool.d.ts +0 -153
- package/dist/skills/tools/lsp-tool.js +0 -227
- package/dist/skills/tools/mcp-client-types.d.ts +0 -269
- package/dist/skills/tools/mcp-client-types.js +0 -53
- package/dist/skills/tools/mcp-tool.d.ts +0 -249
- package/dist/skills/tools/mcp-tool.js +0 -503
- package/dist/skills/tools/memory-tool.d.ts +0 -74
- package/dist/skills/tools/memory-tool.js +0 -88
- package/dist/skills/tools/monitor-tool.d.ts +0 -113
- package/dist/skills/tools/monitor-tool.js +0 -131
- package/dist/skills/tools/music-generate-tool.d.ts +0 -55
- package/dist/skills/tools/music-generate-tool.js +0 -62
- package/dist/skills/tools/notify-tool.d.ts +0 -53
- package/dist/skills/tools/notify-tool.js +0 -62
- package/dist/skills/tools/patch-tool.d.ts +0 -45
- package/dist/skills/tools/patch-tool.js +0 -505
- package/dist/skills/tools/pdf-tool.d.ts +0 -66
- package/dist/skills/tools/pdf-tool.js +0 -88
- package/dist/skills/tools/plan-mode-tool.d.ts +0 -59
- package/dist/skills/tools/plan-mode-tool.js +0 -122
- package/dist/skills/tools/read-tool.d.ts +0 -51
- package/dist/skills/tools/read-tool.js +0 -84
- package/dist/skills/tools/repl-tool.d.ts +0 -70
- package/dist/skills/tools/repl-tool.js +0 -69
- package/dist/skills/tools/search-tool.d.ts +0 -112
- package/dist/skills/tools/search-tool.js +0 -225
- package/dist/skills/tools/send-message-tool.d.ts +0 -51
- package/dist/skills/tools/send-message-tool.js +0 -76
- package/dist/skills/tools/skill-list-tool.d.ts +0 -33
- package/dist/skills/tools/skill-list-tool.js +0 -54
- package/dist/skills/tools/skill-manage-tool.d.ts +0 -73
- package/dist/skills/tools/skill-manage-tool.js +0 -153
- package/dist/skills/tools/skill-view-tool.d.ts +0 -37
- package/dist/skills/tools/skill-view-tool.js +0 -72
- package/dist/skills/tools/sleep-tool.d.ts +0 -49
- package/dist/skills/tools/sleep-tool.js +0 -81
- package/dist/skills/tools/structured-output-tool.d.ts +0 -116
- package/dist/skills/tools/structured-output-tool.js +0 -176
- package/dist/skills/tools/task-tool.d.ts +0 -104
- package/dist/skills/tools/task-tool.js +0 -161
- package/dist/skills/tools/team-tool.d.ts +0 -89
- package/dist/skills/tools/team-tool.js +0 -105
- package/dist/skills/tools/tool-search-tool.d.ts +0 -51
- package/dist/skills/tools/tool-search-tool.js +0 -110
- package/dist/skills/tools/tts-tool.d.ts +0 -38
- package/dist/skills/tools/tts-tool.js +0 -45
- package/dist/skills/tools/video-edit-tool.d.ts +0 -69
- package/dist/skills/tools/video-edit-tool.js +0 -74
- package/dist/skills/tools/video-generate-tool.d.ts +0 -62
- package/dist/skills/tools/video-generate-tool.js +0 -66
- package/dist/skills/tools/video-merge-tool.d.ts +0 -105
- package/dist/skills/tools/video-merge-tool.js +0 -92
- package/dist/skills/tools/video-upscale-tool.d.ts +0 -45
- package/dist/skills/tools/video-upscale-tool.js +0 -52
- package/dist/skills/tools/web-fetch-tool.d.ts +0 -78
- package/dist/skills/tools/web-fetch-tool.js +0 -92
- package/dist/skills/tools/web-search-tool.d.ts +0 -57
- package/dist/skills/tools/web-search-tool.js +0 -86
- package/dist/skills/tools/worktree-tool.d.ts +0 -69
- package/dist/skills/tools/worktree-tool.js +0 -147
- package/dist/skills/tools/write-tool.d.ts +0 -45
- package/dist/skills/tools/write-tool.js +0 -81
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
export declare const SKILL_CANDIDATE_STATUS_VALUES: readonly ["draft", "in_review", "approved", "rejected", "canary", "published", "stale", "superseded", "rolled_back"];
|
|
2
|
-
export declare const SKILL_CANDIDATE_ACTION_VALUES: readonly ["submit-review", "approve", "reject", "start-canary", "record-effectiveness", "promote", "publish", "mark-stale", "mark-superseded", "rollback"];
|
|
3
|
-
export declare const SKILL_CANDIDATE_EFFECTIVENESS_PHASE_VALUES: readonly ["canary", "published"];
|
|
4
|
-
export type SkillCandidateStatus = (typeof SKILL_CANDIDATE_STATUS_VALUES)[number];
|
|
5
|
-
export type SkillCandidateAction = (typeof SKILL_CANDIDATE_ACTION_VALUES)[number];
|
|
6
|
-
export type SkillCandidateEffectivenessPhase = (typeof SKILL_CANDIDATE_EFFECTIVENESS_PHASE_VALUES)[number];
|
|
7
|
-
export type SkillCandidateArtifactContract = {
|
|
8
|
-
uri: string;
|
|
9
|
-
sha256?: string;
|
|
10
|
-
workspaceDir?: string;
|
|
11
|
-
relativePath?: string;
|
|
12
|
-
sourceWorkspaceDir?: string;
|
|
13
|
-
stagedAt?: string;
|
|
14
|
-
};
|
|
15
|
-
export type SkillCandidateSourceExecutionContract = {
|
|
16
|
-
executionId?: string;
|
|
17
|
-
rootExecutionId?: string;
|
|
18
|
-
parentExecutionId?: string;
|
|
19
|
-
sidechainId?: string;
|
|
20
|
-
attemptId?: string;
|
|
21
|
-
outcomeId?: string;
|
|
22
|
-
sessionId?: string;
|
|
23
|
-
turnId?: string;
|
|
24
|
-
};
|
|
25
|
-
export type SkillCandidateReviewContract = {
|
|
26
|
-
action: SkillCandidateAction;
|
|
27
|
-
actor?: string | null;
|
|
28
|
-
notes?: string | null;
|
|
29
|
-
payload?: Record<string, unknown>;
|
|
30
|
-
createdAt?: string;
|
|
31
|
-
};
|
|
32
|
-
export type SkillCandidateEffectivenessContract = {
|
|
33
|
-
phase: SkillCandidateEffectivenessPhase;
|
|
34
|
-
sampleCount: number;
|
|
35
|
-
successCount: number;
|
|
36
|
-
failureCount: number;
|
|
37
|
-
regressionCount: number;
|
|
38
|
-
successRate: number;
|
|
39
|
-
regressionRate: number;
|
|
40
|
-
avgLatencyMs?: number;
|
|
41
|
-
avgCostUsd?: number;
|
|
42
|
-
score?: number;
|
|
43
|
-
staleReason?: string | null;
|
|
44
|
-
notes?: string | null;
|
|
45
|
-
summary?: Record<string, unknown>;
|
|
46
|
-
lastObservedAt?: string;
|
|
47
|
-
updatedAt?: string;
|
|
48
|
-
/** ISO-8601 timestamp of last skill invocation/view/patch activity. */
|
|
49
|
-
lastActivityAt?: string;
|
|
50
|
-
/** Cumulative activity count (use + view + patch). */
|
|
51
|
-
activityCount?: number;
|
|
52
|
-
};
|
|
53
|
-
export declare function coerceSkillCandidateJsonObject(value: unknown): Record<string, unknown>;
|
|
54
|
-
export declare function isSkillCandidateStatus(value: unknown): value is SkillCandidateStatus;
|
|
55
|
-
export declare function isSkillCandidateAction(value: unknown): value is SkillCandidateAction;
|
|
56
|
-
export declare function isSkillCandidateEffectivenessPhase(value: unknown): value is SkillCandidateEffectivenessPhase;
|
|
57
|
-
export declare function normalizeSkillCandidateStatus(value: unknown, fallback?: SkillCandidateStatus): SkillCandidateStatus;
|
|
58
|
-
export declare function normalizeSkillCandidateAction(value: unknown): SkillCandidateAction | null;
|
|
59
|
-
export declare function normalizeSkillCandidateEffectivenessPhase(value: unknown): SkillCandidateEffectivenessPhase | null;
|
|
60
|
-
export declare function normalizeSkillCandidateArtifact(value: unknown): SkillCandidateArtifactContract | null;
|
|
61
|
-
export declare function normalizeSkillCandidateSourceExecution(value: unknown): SkillCandidateSourceExecutionContract | null;
|
|
62
|
-
export declare function normalizeSkillCandidateReview(value: unknown): SkillCandidateReviewContract | null;
|
|
63
|
-
export declare function normalizeSkillCandidateEffectiveness(value: unknown): SkillCandidateEffectivenessContract | null;
|
|
@@ -1,195 +0,0 @@
|
|
|
1
|
-
export const SKILL_CANDIDATE_STATUS_VALUES = [
|
|
2
|
-
"draft",
|
|
3
|
-
"in_review",
|
|
4
|
-
"approved",
|
|
5
|
-
"rejected",
|
|
6
|
-
"canary",
|
|
7
|
-
"published",
|
|
8
|
-
"stale",
|
|
9
|
-
"superseded",
|
|
10
|
-
"rolled_back",
|
|
11
|
-
];
|
|
12
|
-
export const SKILL_CANDIDATE_ACTION_VALUES = [
|
|
13
|
-
"submit-review",
|
|
14
|
-
"approve",
|
|
15
|
-
"reject",
|
|
16
|
-
"start-canary",
|
|
17
|
-
"record-effectiveness",
|
|
18
|
-
"promote",
|
|
19
|
-
"publish",
|
|
20
|
-
"mark-stale",
|
|
21
|
-
"mark-superseded",
|
|
22
|
-
"rollback",
|
|
23
|
-
];
|
|
24
|
-
export const SKILL_CANDIDATE_EFFECTIVENESS_PHASE_VALUES = ["canary", "published"];
|
|
25
|
-
function normalizeOptionalString(value) {
|
|
26
|
-
if (typeof value !== "string") {
|
|
27
|
-
return undefined;
|
|
28
|
-
}
|
|
29
|
-
const trimmed = value.trim();
|
|
30
|
-
return trimmed ? trimmed : undefined;
|
|
31
|
-
}
|
|
32
|
-
function normalizeOptionalFiniteNumber(value) {
|
|
33
|
-
if (typeof value === "number" && Number.isFinite(value)) {
|
|
34
|
-
return value;
|
|
35
|
-
}
|
|
36
|
-
if (typeof value !== "string") {
|
|
37
|
-
return undefined;
|
|
38
|
-
}
|
|
39
|
-
const trimmed = value.trim();
|
|
40
|
-
if (!trimmed) {
|
|
41
|
-
return undefined;
|
|
42
|
-
}
|
|
43
|
-
const parsed = Number(trimmed);
|
|
44
|
-
return Number.isFinite(parsed) ? parsed : undefined;
|
|
45
|
-
}
|
|
46
|
-
function normalizeCount(value, fallback = 0) {
|
|
47
|
-
const normalized = normalizeOptionalFiniteNumber(value);
|
|
48
|
-
if (normalized === undefined) {
|
|
49
|
-
return Math.max(0, Math.floor(fallback));
|
|
50
|
-
}
|
|
51
|
-
return Math.max(0, Math.floor(normalized));
|
|
52
|
-
}
|
|
53
|
-
export function coerceSkillCandidateJsonObject(value) {
|
|
54
|
-
return value && typeof value === "object" && !Array.isArray(value)
|
|
55
|
-
? { ...value }
|
|
56
|
-
: {};
|
|
57
|
-
}
|
|
58
|
-
export function isSkillCandidateStatus(value) {
|
|
59
|
-
return typeof value === "string"
|
|
60
|
-
&& SKILL_CANDIDATE_STATUS_VALUES.includes(value);
|
|
61
|
-
}
|
|
62
|
-
export function isSkillCandidateAction(value) {
|
|
63
|
-
return typeof value === "string"
|
|
64
|
-
&& SKILL_CANDIDATE_ACTION_VALUES.includes(value);
|
|
65
|
-
}
|
|
66
|
-
export function isSkillCandidateEffectivenessPhase(value) {
|
|
67
|
-
return typeof value === "string"
|
|
68
|
-
&& SKILL_CANDIDATE_EFFECTIVENESS_PHASE_VALUES.includes(value);
|
|
69
|
-
}
|
|
70
|
-
export function normalizeSkillCandidateStatus(value, fallback = "draft") {
|
|
71
|
-
const normalized = normalizeOptionalString(value);
|
|
72
|
-
return normalized && isSkillCandidateStatus(normalized) ? normalized : fallback;
|
|
73
|
-
}
|
|
74
|
-
export function normalizeSkillCandidateAction(value) {
|
|
75
|
-
const normalized = normalizeOptionalString(value);
|
|
76
|
-
return normalized && isSkillCandidateAction(normalized) ? normalized : null;
|
|
77
|
-
}
|
|
78
|
-
export function normalizeSkillCandidateEffectivenessPhase(value) {
|
|
79
|
-
const normalized = normalizeOptionalString(value);
|
|
80
|
-
return normalized && isSkillCandidateEffectivenessPhase(normalized) ? normalized : null;
|
|
81
|
-
}
|
|
82
|
-
export function normalizeSkillCandidateArtifact(value) {
|
|
83
|
-
const record = coerceSkillCandidateJsonObject(value);
|
|
84
|
-
const uri = normalizeOptionalString(record.uri);
|
|
85
|
-
if (!uri) {
|
|
86
|
-
return null;
|
|
87
|
-
}
|
|
88
|
-
const sha256 = normalizeOptionalString(record.sha256);
|
|
89
|
-
const workspaceDir = normalizeOptionalString(record.workspaceDir);
|
|
90
|
-
const relativePath = normalizeOptionalString(record.relativePath);
|
|
91
|
-
const sourceWorkspaceDir = normalizeOptionalString(record.sourceWorkspaceDir);
|
|
92
|
-
const stagedAt = normalizeOptionalString(record.stagedAt);
|
|
93
|
-
return {
|
|
94
|
-
uri,
|
|
95
|
-
...(sha256 ? { sha256 } : {}),
|
|
96
|
-
...(workspaceDir ? { workspaceDir } : {}),
|
|
97
|
-
...(relativePath ? { relativePath } : {}),
|
|
98
|
-
...(sourceWorkspaceDir ? { sourceWorkspaceDir } : {}),
|
|
99
|
-
...(stagedAt ? { stagedAt } : {}),
|
|
100
|
-
};
|
|
101
|
-
}
|
|
102
|
-
export function normalizeSkillCandidateSourceExecution(value) {
|
|
103
|
-
const record = coerceSkillCandidateJsonObject(value);
|
|
104
|
-
const executionId = normalizeOptionalString(record.executionId);
|
|
105
|
-
const rootExecutionId = normalizeOptionalString(record.rootExecutionId);
|
|
106
|
-
const parentExecutionId = normalizeOptionalString(record.parentExecutionId);
|
|
107
|
-
const sidechainId = normalizeOptionalString(record.sidechainId);
|
|
108
|
-
const attemptId = normalizeOptionalString(record.attemptId);
|
|
109
|
-
const outcomeId = normalizeOptionalString(record.outcomeId);
|
|
110
|
-
const sessionId = normalizeOptionalString(record.sessionId);
|
|
111
|
-
const turnId = normalizeOptionalString(record.turnId);
|
|
112
|
-
if (!executionId
|
|
113
|
-
&& !rootExecutionId
|
|
114
|
-
&& !parentExecutionId
|
|
115
|
-
&& !sidechainId
|
|
116
|
-
&& !attemptId
|
|
117
|
-
&& !outcomeId
|
|
118
|
-
&& !sessionId
|
|
119
|
-
&& !turnId) {
|
|
120
|
-
return null;
|
|
121
|
-
}
|
|
122
|
-
return {
|
|
123
|
-
...(executionId ? { executionId } : {}),
|
|
124
|
-
...(rootExecutionId ? { rootExecutionId } : {}),
|
|
125
|
-
...(parentExecutionId ? { parentExecutionId } : {}),
|
|
126
|
-
...(sidechainId ? { sidechainId } : {}),
|
|
127
|
-
...(attemptId ? { attemptId } : {}),
|
|
128
|
-
...(outcomeId ? { outcomeId } : {}),
|
|
129
|
-
...(sessionId ? { sessionId } : {}),
|
|
130
|
-
...(turnId ? { turnId } : {}),
|
|
131
|
-
};
|
|
132
|
-
}
|
|
133
|
-
export function normalizeSkillCandidateReview(value) {
|
|
134
|
-
const record = coerceSkillCandidateJsonObject(value);
|
|
135
|
-
const action = normalizeSkillCandidateAction(record.action);
|
|
136
|
-
if (!action) {
|
|
137
|
-
return null;
|
|
138
|
-
}
|
|
139
|
-
const actor = normalizeOptionalString(record.actor) ?? null;
|
|
140
|
-
const notes = normalizeOptionalString(record.notes) ?? null;
|
|
141
|
-
const payload = coerceSkillCandidateJsonObject(record.payload);
|
|
142
|
-
const createdAt = normalizeOptionalString(record.createdAt);
|
|
143
|
-
return {
|
|
144
|
-
action,
|
|
145
|
-
actor,
|
|
146
|
-
notes,
|
|
147
|
-
payload,
|
|
148
|
-
...(createdAt ? { createdAt } : {}),
|
|
149
|
-
};
|
|
150
|
-
}
|
|
151
|
-
export function normalizeSkillCandidateEffectiveness(value) {
|
|
152
|
-
const record = coerceSkillCandidateJsonObject(value);
|
|
153
|
-
const phase = normalizeSkillCandidateEffectivenessPhase(record.phase);
|
|
154
|
-
if (!phase) {
|
|
155
|
-
return null;
|
|
156
|
-
}
|
|
157
|
-
const successCount = normalizeCount(record.successCount);
|
|
158
|
-
const explicitFailureCount = normalizeOptionalFiniteNumber(record.failureCount);
|
|
159
|
-
const sampleCount = normalizeCount(record.sampleCount, explicitFailureCount !== undefined ? successCount + explicitFailureCount : successCount);
|
|
160
|
-
const failureCount = normalizeCount(record.failureCount, Math.max(sampleCount - successCount, 0));
|
|
161
|
-
const regressionCount = normalizeCount(record.regressionCount);
|
|
162
|
-
const successRate = normalizeOptionalFiniteNumber(record.successRate)
|
|
163
|
-
?? (sampleCount > 0 ? successCount / sampleCount : 0);
|
|
164
|
-
const regressionRate = normalizeOptionalFiniteNumber(record.regressionRate)
|
|
165
|
-
?? (sampleCount > 0 ? regressionCount / sampleCount : 0);
|
|
166
|
-
const avgLatencyMs = normalizeOptionalFiniteNumber(record.avgLatencyMs);
|
|
167
|
-
const avgCostUsd = normalizeOptionalFiniteNumber(record.avgCostUsd);
|
|
168
|
-
const score = normalizeOptionalFiniteNumber(record.score);
|
|
169
|
-
const staleReason = normalizeOptionalString(record.staleReason) ?? null;
|
|
170
|
-
const notes = normalizeOptionalString(record.notes) ?? null;
|
|
171
|
-
const summary = coerceSkillCandidateJsonObject(record.summary);
|
|
172
|
-
const lastObservedAt = normalizeOptionalString(record.lastObservedAt);
|
|
173
|
-
const updatedAt = normalizeOptionalString(record.updatedAt);
|
|
174
|
-
const lastActivityAt = normalizeOptionalString(record.lastActivityAt);
|
|
175
|
-
const activityCount = normalizeOptionalFiniteNumber(record.activityCount);
|
|
176
|
-
return {
|
|
177
|
-
phase,
|
|
178
|
-
sampleCount,
|
|
179
|
-
successCount,
|
|
180
|
-
failureCount,
|
|
181
|
-
regressionCount,
|
|
182
|
-
successRate,
|
|
183
|
-
regressionRate,
|
|
184
|
-
...(avgLatencyMs !== undefined ? { avgLatencyMs } : {}),
|
|
185
|
-
...(avgCostUsd !== undefined ? { avgCostUsd } : {}),
|
|
186
|
-
...(score !== undefined ? { score } : {}),
|
|
187
|
-
...(staleReason ? { staleReason } : {}),
|
|
188
|
-
...(notes ? { notes } : {}),
|
|
189
|
-
...(Object.keys(summary).length > 0 ? { summary } : {}),
|
|
190
|
-
...(lastObservedAt ? { lastObservedAt } : {}),
|
|
191
|
-
...(updatedAt ? { updatedAt } : {}),
|
|
192
|
-
...(lastActivityAt ? { lastActivityAt } : {}),
|
|
193
|
-
...(activityCount !== undefined ? { activityCount } : {}),
|
|
194
|
-
};
|
|
195
|
-
}
|
package/dist/contracts/todo.d.ts
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
export declare const TODO_ITEM_STATUS_VALUES: readonly ["not-started", "in-progress", "completed"];
|
|
2
|
-
export type TodoItemStatus = (typeof TODO_ITEM_STATUS_VALUES)[number];
|
|
3
|
-
export interface TodoItem {
|
|
4
|
-
id: number;
|
|
5
|
-
title: string;
|
|
6
|
-
status: TodoItemStatus;
|
|
7
|
-
}
|
|
8
|
-
export interface TodoListSummary {
|
|
9
|
-
total: number;
|
|
10
|
-
completed: number;
|
|
11
|
-
inProgress: number;
|
|
12
|
-
notStarted: number;
|
|
13
|
-
}
|
|
14
|
-
export declare function summarizeTodoList(items: readonly TodoItem[]): TodoListSummary;
|
package/dist/contracts/todo.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
export const TODO_ITEM_STATUS_VALUES = ["not-started", "in-progress", "completed"];
|
|
2
|
-
export function summarizeTodoList(items) {
|
|
3
|
-
return {
|
|
4
|
-
total: items.length,
|
|
5
|
-
completed: items.filter((item) => item.status === "completed").length,
|
|
6
|
-
inProgress: items.filter((item) => item.status === "in-progress").length,
|
|
7
|
-
notStarted: items.filter((item) => item.status === "not-started").length,
|
|
8
|
-
};
|
|
9
|
-
}
|
package/dist/index.d.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* qlogicagent — Public API surface.
|
|
3
|
-
*
|
|
4
|
-
* Re-exports core types and constructors for programmatic embedding.
|
|
5
|
-
*/
|
|
6
|
-
export { Agent } from "./agent/agent.js";
|
|
7
|
-
export type { AgentLogger, ChatMessage, ToolDefinition, ToolInvoker, TurnConfig, TurnEvent, TurnRequest, HookRegistry, } from "./agent/types.js";
|
|
8
|
-
export { parseCliArgs } from "./config/config.js";
|
|
9
|
-
export type { AgentConfig } from "./config/config.js";
|
|
10
|
-
export { ProviderRegistry, createLLMClient, autoDetectProvider, } from "./llm/index.js";
|
|
11
|
-
export type { LLMTransport, LLMRequest, LLMChunk } from "./llm/index.js";
|
|
12
|
-
export { createHookRegistry } from "./runtime/hook-registry.js";
|
|
13
|
-
export { buildSkillInstruction, shouldCreateSkill, shouldImproveSkill, } from "./orchestration/index.js";
|
package/dist/index.js
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* qlogicagent — Public API surface.
|
|
3
|
-
*
|
|
4
|
-
* Re-exports core types and constructors for programmatic embedding.
|
|
5
|
-
*/
|
|
6
|
-
// ── Agent ──────────────────────────────────────────────────
|
|
7
|
-
export { Agent } from "./agent/agent.js";
|
|
8
|
-
// ── Config ─────────────────────────────────────────────────
|
|
9
|
-
export { parseCliArgs } from "./config/config.js";
|
|
10
|
-
// ── LLM layer ──────────────────────────────────────────────
|
|
11
|
-
export { ProviderRegistry, createLLMClient, autoDetectProvider, } from "./llm/index.js";
|
|
12
|
-
// ── Runtime ────────────────────────────────────────────────
|
|
13
|
-
export { createHookRegistry } from "./runtime/hook-registry.js";
|
|
14
|
-
// ── Orchestration ──────────────────────────────────────────
|
|
15
|
-
export { buildSkillInstruction, shouldCreateSkill, shouldImproveSkill, } from "./orchestration/index.js";
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Builtin provider definitions — hardcoded fallback list (~30 providers).
|
|
3
|
-
*
|
|
4
|
-
* This is Layer 1 (lowest priority) of the three-layer merge strategy.
|
|
5
|
-
* Used when remote model catalog is unavailable.
|
|
6
|
-
*
|
|
7
|
-
* Aligned with Hermes hermes_cli/models.py hardcoded fallback.
|
|
8
|
-
*/
|
|
9
|
-
import type { ProviderDef } from "./provider-def.js";
|
|
10
|
-
export declare const BUILTIN_PROVIDERS: ProviderDef[];
|