shortcutxl 0.3.87 → 0.3.89
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/BINARY-INVENTORY.json +13 -13
- package/CHANGELOG.md +10 -0
- package/dist/app/agent-session-runtime-adapter.js +4 -1
- package/dist/app/background-agents/shorty/fix-prompts.d.ts +2 -2
- package/dist/app/background-agents/shorty/inspector/runtime.d.ts +1 -0
- package/dist/app/background-agents/shorty/inspector/runtime.js +25 -12
- package/dist/app/background-agents/shorty/runtime.js +3 -0
- package/dist/app/background-agents/shorty/types.d.ts +3 -2
- package/dist/app/modes/action/prompt.js +1 -1
- package/dist/app/modes/index.d.ts +1 -0
- package/dist/app/modes/index.js +4 -1
- package/dist/app/modes/installation/prompt-windows.js +1 -1
- package/dist/app/modes/skill-forge/agent.d.ts +13 -0
- package/dist/app/modes/skill-forge/agent.js +33 -0
- package/dist/app/modes/skill-forge/prompt.d.ts +3 -0
- package/dist/app/modes/skill-forge/prompt.js +102 -0
- package/dist/app/prompts/spreadjs-api-reference.json +0 -6
- package/dist/app/session/session-catalog.d.ts +3 -0
- package/dist/app/session/session-catalog.js +2 -1
- package/dist/app/session/session-metadata.js +11 -0
- package/dist/app/session/session-reader.d.ts +3 -0
- package/dist/app/session/session-reader.js +1 -0
- package/dist/app/subagents/defaults.d.ts +2 -1
- package/dist/app/subagents/defaults.js +1 -1
- package/dist/app/tools/skill-forge.d.ts +9 -0
- package/dist/app/tools/skill-forge.js +24 -0
- package/dist/app/tools/task/manager.js +2 -1
- package/dist/app/tools/task/task.d.ts +3 -0
- package/dist/app/tools/task/task.js +31 -9
- package/dist/cli.js +892 -259
- package/dist/constants.d.ts +2 -0
- package/dist/constants.js +4 -0
- package/dist/contracts/agent-api.d.ts +31 -25
- package/dist/contracts/agent-api.js +17 -13
- package/dist/contracts/agent-execute-code.d.ts +0 -2
- package/dist/contracts/agent-execute-code.js +0 -2
- package/dist/contracts/agent-session-store.d.ts +3 -0
- package/dist/contracts/agent-skill-forge.d.ts +67 -0
- package/dist/contracts/agent-skill-forge.js +53 -0
- package/dist/core/embedded-agent-facade.d.ts +2 -1
- package/dist/core/embedded-agent-facade.js +5 -2
- package/dist/core/pending-host-tool-requests.d.ts +1 -1
- package/dist/core/pending-host-tool-requests.js +1 -1
- package/dist/core/prompts/agent-guidelines.d.ts +3 -3
- package/dist/core/prompts/agent-guidelines.js +23 -14
- package/dist/core/skill-forge/index.d.ts +3 -0
- package/dist/core/skill-forge/index.js +3 -0
- package/dist/core/skill-forge/skill-forge-state-manager.d.ts +20 -0
- package/dist/core/skill-forge/skill-forge-state-manager.js +39 -0
- package/dist/credits/shortcut-credits.d.ts +15 -0
- package/dist/credits/shortcut-credits.js +53 -0
- package/dist/embedded-agent/ai-invoke.d.ts +1 -1
- package/dist/embedded-agent/ai-invoke.js +6 -5
- package/dist/embedded-agent/compose.js +53 -37
- package/dist/embedded-agent/host-runtime-options.d.ts +1 -1
- package/dist/embedded-agent/host-runtime-options.js +12 -13
- package/dist/embedded-agent/host-tools/execute-bash-command/contract.js +4 -2
- package/dist/embedded-agent/host-tools/execute-code/allowed-functions.json +0 -2
- package/dist/embedded-agent/host-tools/execute-code/classify.d.ts +1 -3
- package/dist/embedded-agent/host-tools/execute-code/classify.js +4 -7
- package/dist/embedded-agent/host-tools/execute-code/contract.d.ts +0 -1
- package/dist/embedded-agent/host-tools/execute-code/contract.js +0 -1
- package/dist/embedded-agent/host-tools/mode-host-tools.js +0 -6
- package/dist/embedded-agent/host-tools/switch-mode/contract.d.ts +2 -2
- package/dist/embedded-agent/host-tools/switch-mode/contract.js +1 -2
- package/dist/embedded-agent/index.d.ts +3 -3
- package/dist/embedded-agent/inspector/agent.d.ts +14 -0
- package/dist/embedded-agent/{review → inspector}/agent.js +14 -7
- package/dist/embedded-agent/{review → inspector}/coordinator.d.ts +17 -11
- package/dist/embedded-agent/{review → inspector}/coordinator.js +49 -29
- package/dist/embedded-agent/inspector/findings.d.ts +7 -0
- package/dist/embedded-agent/{review → inspector}/findings.js +9 -9
- package/dist/embedded-agent/prompt/build.js +0 -10
- package/dist/embedded-agent/prompt/modes/action.js +1 -1
- package/dist/embedded-agent/prompt/modes/ask.js +1 -1
- package/dist/embedded-agent/suggestions.js +2 -1
- package/dist/embedded-agent/worker-bridge/dispatch.js +7 -4
- package/dist/embedded-agent/worker-bridge/host-client.d.ts +3 -1
- package/dist/embedded-agent/worker-bridge/host-client.js +31 -14
- package/dist/endpoints.d.ts +1 -0
- package/dist/endpoints.js +1 -0
- package/dist/main.d.ts +4 -1
- package/dist/main.js +73 -40
- package/dist/mode-names.d.ts +5 -0
- package/dist/mode-names.js +4 -2
- package/dist/rpc/index.d.ts +1 -1
- package/dist/rpc/rpc-client.d.ts +7 -0
- package/dist/rpc/rpc-client.js +2 -1
- package/dist/rpc/rpc-host.d.ts +30 -1
- package/dist/rpc/rpc-host.js +129 -25
- package/dist/rpc/rpc-mode.d.ts +1 -1
- package/dist/rpc/rpc-types.d.ts +21 -2
- package/dist/shell/components/shorty-issues.d.ts +3 -3
- package/dist/shell/components/shorty-issues.js +5 -5
- package/dist/shell/interactive/interactive-mode.js +11 -11
- package/dist/startup/startup-progress.d.ts +62 -0
- package/dist/startup/startup-progress.js +92 -0
- package/dist/subagent-model-policy.d.ts +12 -2
- package/dist/subagent-model-policy.js +37 -2
- package/dist/subagent-thinking-policy.d.ts +5 -3
- package/dist/subagent-thinking-policy.js +5 -4
- package/dist/tool-names.d.ts +1 -0
- package/dist/tool-names.js +1 -0
- package/native-app/main/index.js +41 -8
- package/native-app/package.json +1 -1
- package/native-app/renderer/assets/Alegreya-Italic-Variable-BNGsTFBD.woff2 +0 -0
- package/native-app/renderer/assets/Alegreya-Variable-BCUEsrKK.woff2 +0 -0
- package/native-app/renderer/assets/AvQest-DwQOLw3s.woff2 +0 -0
- package/native-app/renderer/assets/Cinzel-Variable-BOqWLKHx.woff2 +0 -0
- package/native-app/renderer/assets/DiabloHeavy-aRIenZkJ.woff2 +0 -0
- package/native-app/renderer/assets/anvil-BULXnOOB.png +3 -0
- package/native-app/renderer/assets/frame-DDQ6ScMl.png +3 -0
- package/native-app/renderer/assets/{index-Ch24bXR6.css → index-DsYjsaRU.css} +1580 -173
- package/native-app/renderer/assets/{index-BRbc7n0z.js → index-SuRESuDS.js} +4414 -374
- package/native-app/renderer/assets/plaque-C6n7SCaF.png +3 -0
- package/native-app/renderer/assets/rock-CXFUiLgi.png +3 -0
- package/native-app/renderer/index.html +2 -2
- package/package.json +6 -2
- package/skills/skill-creator/SKILL.md +89 -440
- package/user-docs/dist/index.html +1 -1
- package/xll/python/Lib/site-packages/httpx-0.28.1.dist-info/RECORD +1 -1
- package/xll/python/Lib/site-packages/idna-3.18.dist-info/RECORD +1 -1
- package/xll/python/Lib/site-packages/pip-26.2.dist-info/RECORD +3 -3
- package/xll/python/Lib/site-packages/pywin32-311.dist-info/RECORD +2 -2
- package/xll/python/Scripts/httpx.exe +0 -0
- package/xll/python/Scripts/idna.exe +0 -0
- package/xll/python/Scripts/pip.exe +0 -0
- package/xll/python/Scripts/pip3.13.exe +0 -0
- package/xll/python/Scripts/pip3.exe +0 -0
- package/xll/python/Scripts/pywin32_postinstall.exe +0 -0
- package/xll/python/Scripts/pywin32_testall.exe +0 -0
- package/dist/embedded-agent/prompt/modes/shorty.d.ts +0 -12
- package/dist/embedded-agent/prompt/modes/shorty.js +0 -35
- package/dist/embedded-agent/review/agent.d.ts +0 -14
- package/dist/embedded-agent/review/findings.d.ts +0 -7
- package/dist/startup/timings.d.ts +0 -7
- package/dist/startup/timings.js +0 -25
- package/native-app/renderer/assets/shortcutagent-DxFsGSkw.png +0 -0
- package/skills/skill-creator/LICENSE.txt +0 -202
- package/skills/skill-creator/agents/analyzer.md +0 -274
- package/skills/skill-creator/agents/comparator.md +0 -202
- package/skills/skill-creator/agents/grader.md +0 -223
- package/skills/skill-creator/assets/eval_review.html +0 -292
- package/skills/skill-creator/eval-viewer/generate_review.py +0 -471
- package/skills/skill-creator/eval-viewer/viewer.html +0 -1478
- package/skills/skill-creator/references/schemas.md +0 -430
- package/skills/skill-creator/scripts/__init__.py +0 -0
- package/skills/skill-creator/scripts/aggregate_benchmark.py +0 -401
- package/skills/skill-creator/scripts/generate_report.py +0 -326
- package/skills/skill-creator/scripts/improve_description.py +0 -232
- package/skills/skill-creator/scripts/package_skill.py +0 -136
- package/skills/skill-creator/scripts/quick_validate.py +0 -103
- package/skills/skill-creator/scripts/run_eval.py +0 -223
- package/skills/skill-creator/scripts/run_loop.py +0 -324
- package/skills/skill-creator/scripts/utils.py +0 -47
|
@@ -345,13 +345,14 @@ function writeTaskOutput(task) {
|
|
|
345
345
|
export function formatTaskNotification(task) {
|
|
346
346
|
const durationMs = task.completedAt ? Math.max(0, task.completedAt - task.startedAt) : 0;
|
|
347
347
|
const totalTokens = (task.usage?.input ?? 0) + (task.usage?.output ?? 0);
|
|
348
|
+
const costUsd = (task.usage?.cost ?? 0).toFixed(8);
|
|
348
349
|
const outputPreview = truncateForParent(task.errorMessage ?? task.resultText ?? '(no output)');
|
|
349
350
|
const lines = [
|
|
350
351
|
`<sa status="${escapeXmlAttribute(task.status)}" type="${escapeXmlAttribute(task.subagentType)}" name="${escapeXmlAttribute(task.name || task.agentId)}" id="${escapeXmlAttribute(task.agentId)}">`,
|
|
351
352
|
` <prompt>${escapeXmlText(task.prompt)}</prompt>`,
|
|
352
353
|
` <output>${escapeXmlText(outputPreview)}</output>`,
|
|
353
354
|
` <files output="${escapeXmlAttribute(task.outputFile)}" output_chars="${task.outputFileChars ?? 0}" output_lines="${task.outputFileLines ?? 0}"${task.transcriptFile ? ` transcript="${escapeXmlAttribute(task.transcriptFile)}"` : ''}/>`,
|
|
354
|
-
` <usage tokens="${totalTokens}" tools="${task.toolUses}" ms="${durationMs}"/>`,
|
|
355
|
+
` <usage tokens="${totalTokens}" tools="${task.toolUses}" ms="${durationMs}" cost_usd="${costUsd}"/>`,
|
|
355
356
|
'</sa>'
|
|
356
357
|
];
|
|
357
358
|
return lines.join('\n');
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
*/
|
|
11
11
|
import type { ToolDefinition } from '../../../core/core-types.js';
|
|
12
12
|
import { type RuntimePermissionPolicy } from '../../../core/permission-policy.js';
|
|
13
|
+
import { type SubagentModelScope } from '../../../subagent-model-policy.js';
|
|
13
14
|
import { type TaskModelChoice } from '../../subagents/defaults.js';
|
|
14
15
|
import { type TaskManager } from './manager.js';
|
|
15
16
|
import { type TaskSubagentResult } from './types.js';
|
|
@@ -48,6 +49,8 @@ interface CreateTaskToolOptions {
|
|
|
48
49
|
readonly provider: string;
|
|
49
50
|
readonly id: string;
|
|
50
51
|
} | undefined;
|
|
52
|
+
/** Live model-policy scope; defaults to deriving it from the current mode. Tests inject it. */
|
|
53
|
+
getModelScope?: () => SubagentModelScope;
|
|
51
54
|
}
|
|
52
55
|
/** Build the child runtime tool catalog by replacing the task tool with a scoped clone. */
|
|
53
56
|
export declare function buildChildRuntimeTools(tools: readonly ToolDefinition[], options: {
|
|
@@ -13,7 +13,8 @@ import { randomUUID } from 'node:crypto';
|
|
|
13
13
|
import { StringEnum } from '../../../ai/typebox.js';
|
|
14
14
|
import { RUNTIME_CAPABILITY } from '../../../core/permission-policy.js';
|
|
15
15
|
import { getActiveUserMessageId } from '../../../core/user-message-id.js';
|
|
16
|
-
import {
|
|
16
|
+
import { getCurrentMode, MODE } from '../../../mode-names.js';
|
|
17
|
+
import { getSubagentModelOverrideGuidance, getSubagentModelPolicy, SUBAGENT_MODEL_SCOPE } from '../../../subagent-model-policy.js';
|
|
17
18
|
import { resolveSubagentThinkingLevel } from '../../../subagent-thinking-policy.js';
|
|
18
19
|
import { MCP_TOOL_NAMES, TASK } from '../../../tool-names.js';
|
|
19
20
|
import { ABORT_AGENT_MESSAGE } from '../../../utils/abort.js';
|
|
@@ -117,11 +118,16 @@ export function buildInheritedSubagentPermissionPolicy(input) {
|
|
|
117
118
|
export function getSubagentDisplayError(result) {
|
|
118
119
|
return result.errorMessage || result.text || '(subagent failed with no output)';
|
|
119
120
|
}
|
|
121
|
+
const SUBAGENT_THINKING_LEVELS = [
|
|
122
|
+
'low',
|
|
123
|
+
'medium',
|
|
124
|
+
'high'
|
|
125
|
+
];
|
|
120
126
|
/** Build the typebox schema for the task tool, optionally excluding subagent types. */
|
|
121
|
-
function buildSchema(excludeSubagents, parentModelId, preferCurrentModelForSubagents, subagentModel) {
|
|
127
|
+
function buildSchema(excludeSubagents, parentModelId, preferCurrentModelForSubagents, subagentModel, modelScope) {
|
|
122
128
|
const allNames = getSubagentNames();
|
|
123
129
|
const names = excludeSubagents ? allNames.filter((n) => !excludeSubagents.includes(n)) : allNames;
|
|
124
|
-
const modelPolicy = getSubagentModelPolicy(parentModelId);
|
|
130
|
+
const modelPolicy = getSubagentModelPolicy(parentModelId, modelScope);
|
|
125
131
|
const modelChoices = preferCurrentModelForSubagents || subagentModel
|
|
126
132
|
? []
|
|
127
133
|
: modelPolicy.allowedModels.map((model) => model.ref);
|
|
@@ -141,7 +147,14 @@ function buildSchema(excludeSubagents, parentModelId, preferCurrentModelForSubag
|
|
|
141
147
|
...(modelChoices.length > 1
|
|
142
148
|
? {
|
|
143
149
|
model: Type.Optional(StringEnum(modelChoices, {
|
|
144
|
-
description: `Optional override. Omit to use "${modelPolicy.defaultModel.ref}". ${getSubagentModelOverrideGuidance(parentModelId)}`
|
|
150
|
+
description: `Optional override. Omit to use "${modelPolicy.defaultModel.ref}". ${getSubagentModelOverrideGuidance(parentModelId, modelScope)}`
|
|
151
|
+
}))
|
|
152
|
+
}
|
|
153
|
+
: {}),
|
|
154
|
+
...(modelScope === SUBAGENT_MODEL_SCOPE.SKILL_FORGE
|
|
155
|
+
? {
|
|
156
|
+
thinking_level: Type.Optional(StringEnum(SUBAGENT_THINKING_LEVELS, {
|
|
157
|
+
description: 'Optional reasoning-effort override for this worker. Pin one level per iteration so grades stay comparable. Luna and Pivot always run at max regardless of this value.'
|
|
145
158
|
}))
|
|
146
159
|
}
|
|
147
160
|
: {}),
|
|
@@ -177,15 +190,20 @@ function getMissingDeclaredTools(declaredToolNames, runtimeTools) {
|
|
|
177
190
|
}
|
|
178
191
|
/** Build the `task` tool that spawns subagents in the foreground or background. */
|
|
179
192
|
export function createTaskTool(options = {}) {
|
|
180
|
-
const { cwd: cwdOverride, excludeSubagents, getRuntimeTools, notifyParent, disableMemory, preferCurrentModelForSubagents, subagentModel, parentModel, getCurrentModel, taskManager = defaultTaskManager } = options;
|
|
193
|
+
const { cwd: cwdOverride, excludeSubagents, getRuntimeTools, notifyParent, disableMemory, preferCurrentModelForSubagents, subagentModel, parentModel, getCurrentModel, getModelScope, taskManager = defaultTaskManager } = options;
|
|
181
194
|
let parametersCache;
|
|
182
195
|
const getActiveParentModel = () => getCurrentModel?.() ?? parentModel;
|
|
196
|
+
const getActiveModelScope = () => getModelScope?.() ??
|
|
197
|
+
(getCurrentMode() === MODE.SKILL_FORGE
|
|
198
|
+
? SUBAGENT_MODEL_SCOPE.SKILL_FORGE
|
|
199
|
+
: SUBAGENT_MODEL_SCOPE.DEFAULT);
|
|
183
200
|
const getParameters = () => {
|
|
184
201
|
const activeParentModel = getActiveParentModel();
|
|
185
|
-
const
|
|
202
|
+
const modelScope = getActiveModelScope();
|
|
203
|
+
const key = `${activeParentModel?.id ?? ''}\0${preferCurrentModelForSubagents === true}\0${subagentModel ?? ''}\0${modelScope}`;
|
|
186
204
|
if (parametersCache?.key === key)
|
|
187
205
|
return parametersCache.schema;
|
|
188
|
-
const schema = buildSchema(excludeSubagents, activeParentModel?.id, preferCurrentModelForSubagents === true, subagentModel);
|
|
206
|
+
const schema = buildSchema(excludeSubagents, activeParentModel?.id, preferCurrentModelForSubagents === true, subagentModel, modelScope);
|
|
189
207
|
parametersCache = { key, schema };
|
|
190
208
|
return schema;
|
|
191
209
|
};
|
|
@@ -197,7 +215,7 @@ export function createTaskTool(options = {}) {
|
|
|
197
215
|
return getParameters();
|
|
198
216
|
},
|
|
199
217
|
async execute(toolCallId, params, signal, onUpdate, ctx) {
|
|
200
|
-
const { subagent_type, name, query: rawQuery, query_file: queryFile, model: modelOverride, run_in_background } = params;
|
|
218
|
+
const { subagent_type, name, query: rawQuery, query_file: queryFile, model: modelOverride, thinking_level: thinkingOverride, run_in_background } = params;
|
|
201
219
|
const effectiveRunInBackground = run_in_background === true;
|
|
202
220
|
// Look up agent config
|
|
203
221
|
const agentConfig = getSubagent(subagent_type);
|
|
@@ -261,6 +279,7 @@ export function createTaskTool(options = {}) {
|
|
|
261
279
|
const extCtx = ctx;
|
|
262
280
|
const activeParentModel = extCtx.model ?? getActiveParentModel();
|
|
263
281
|
const modelSelection = selectTaskModel({
|
|
282
|
+
modelScope: getActiveModelScope(),
|
|
264
283
|
parentModel: activeParentModel,
|
|
265
284
|
overrideModelRef: subagentModel ?? modelOverride,
|
|
266
285
|
preferCurrentModelForSubagents: preferCurrentModelForSubagents === true && subagentModel === undefined
|
|
@@ -281,7 +300,10 @@ export function createTaskTool(options = {}) {
|
|
|
281
300
|
...agentConfig,
|
|
282
301
|
thinkingLevel: resolveSubagentThinkingLevel({
|
|
283
302
|
modelId: modelSelection.modelId,
|
|
284
|
-
declaredLevel: agentConfig.thinkingLevel
|
|
303
|
+
declaredLevel: agentConfig.thinkingLevel,
|
|
304
|
+
requestedLevel: getActiveModelScope() === SUBAGENT_MODEL_SCOPE.SKILL_FORGE
|
|
305
|
+
? thinkingOverride
|
|
306
|
+
: undefined
|
|
285
307
|
})
|
|
286
308
|
};
|
|
287
309
|
const effectiveModel = modelSelection.modelRef;
|