mirror of
https://github.com/openclaw/openclaw.git
synced 2026-07-28 07:31:17 +00:00
refactor(speech-core): remove redundant API back-edge
This commit is contained in:
@@ -83,8 +83,8 @@ vi.mock("openclaw/plugin-sdk/channel-targets", () => ({
|
||||
},
|
||||
}));
|
||||
|
||||
vi.mock("../api.js", async () => {
|
||||
const actual = await vi.importActual<typeof import("../api.js")>("../api.js");
|
||||
vi.mock("openclaw/plugin-sdk/speech-core", async () => {
|
||||
const actual = await vi.importActual("openclaw/plugin-sdk/speech-core");
|
||||
const mockProvider: SpeechProviderPlugin = {
|
||||
id: "mock",
|
||||
label: "Mock",
|
||||
|
||||
@@ -27,17 +27,6 @@ import {
|
||||
import { isVerbose, logVerbose } from "openclaw/plugin-sdk/runtime-env";
|
||||
import { tempWorkspaceSync, resolvePreferredOpenClawTmpDir } from "openclaw/plugin-sdk/sandbox";
|
||||
import { privateFileStoreSync } from "openclaw/plugin-sdk/security-runtime";
|
||||
import {
|
||||
normalizeLowercaseStringOrEmpty,
|
||||
normalizeOptionalLowercaseString,
|
||||
normalizeOptionalString,
|
||||
} from "openclaw/plugin-sdk/string-coerce-runtime";
|
||||
import { stripMarkdown } from "openclaw/plugin-sdk/text-chunking";
|
||||
import {
|
||||
resolveConfigDir,
|
||||
resolveUserPath,
|
||||
truncateUtf16Safe,
|
||||
} from "openclaw/plugin-sdk/text-utility-runtime";
|
||||
import {
|
||||
canonicalizeSpeechProviderId,
|
||||
getSpeechProvider,
|
||||
@@ -57,7 +46,18 @@ import {
|
||||
type TtsDirectiveOverrides,
|
||||
type TtsDirectiveParseResult,
|
||||
type TtsConfigResolutionContext,
|
||||
} from "../api.js";
|
||||
} from "openclaw/plugin-sdk/speech-core";
|
||||
import {
|
||||
normalizeLowercaseStringOrEmpty,
|
||||
normalizeOptionalLowercaseString,
|
||||
normalizeOptionalString,
|
||||
} from "openclaw/plugin-sdk/string-coerce-runtime";
|
||||
import { stripMarkdown } from "openclaw/plugin-sdk/text-chunking";
|
||||
import {
|
||||
resolveConfigDir,
|
||||
resolveUserPath,
|
||||
truncateUtf16Safe,
|
||||
} from "openclaw/plugin-sdk/text-utility-runtime";
|
||||
import { withSpeakerSelectionCompat } from "../speaker.js";
|
||||
import {
|
||||
resolvePrimaryVoiceProviderCandidate,
|
||||
|
||||
Reference in New Issue
Block a user