refactor(runtime): drop unused exported helpers

This commit is contained in:
Vincent Koc
2026-06-19 14:41:55 +08:00
parent ccdec2e294
commit 38fefc5aaf
2 changed files with 0 additions and 37 deletions

View File

@@ -63,11 +63,6 @@ export const SHORT_TERM_PHASE_SIGNAL_RELATIVE_PATH = path.join(
".dreams",
"phase-signals.json",
);
export const SHORT_TERM_LOCK_RELATIVE_PATH = path.join(
"memory",
".dreams",
"short-term-promotion.lock",
);
const SHORT_TERM_LOCK_WAIT_TIMEOUT_MS = 10_000;
const SHORT_TERM_LOCK_STALE_MS = 60_000;
const SHORT_TERM_LOCK_RETRY_DELAY_MS = 40;

View File

@@ -79,23 +79,6 @@ export function getPluginCommandSpecs(
return listProviderPluginCommandSpecs(providerName);
}
export function getPluginCommandSpecsFromRegistrations(
commands: readonly PluginCommandRegistration[],
provider?: string,
options: PluginCommandSpecOptions = {},
): Array<{
name: string;
description: string;
descriptionLocalizations?: Record<string, string>;
acceptsArgs: boolean;
}> {
const providerName = normalizeOptionalLowercaseString(provider);
if (!pluginNativeCommandsEnabled(providerName, options)) {
return [];
}
return listProviderPluginCommandSpecsFromRegistrations(commands, providerName);
}
export function getPluginCommandEntrySpecs(
provider?: string,
options: PluginCommandSpecOptions = {},
@@ -133,21 +116,6 @@ export function listProviderPluginCommandSpecs(provider?: string): Array<{
.map((cmd) => serializePluginCommandSpec(cmd, provider));
}
export function listProviderPluginCommandSpecsFromRegistrations(
commands: readonly PluginCommandRegistration[],
provider?: string,
): Array<{
name: string;
description: string;
descriptionLocalizations?: Record<string, string>;
acceptsArgs: boolean;
}> {
return commands
.map((entry) => entry.command)
.filter((cmd) => pluginCommandSupportsChannel(cmd, provider))
.map((cmd) => serializePluginCommandSpec(cmd, provider));
}
function serializePluginCommandSpec(
cmd: OpenClawPluginCommandDefinition,
provider?: string,