mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 08:30:42 +00:00
refactor: hide embedded runner internals
This commit is contained in:
@@ -11,7 +11,7 @@ import { isGooglePromptCacheEligible } from "./prompt-cache-retention.js";
|
||||
|
||||
type CustomEntryLike = { type?: unknown; customType?: unknown; data?: unknown };
|
||||
|
||||
export const CACHE_TTL_CUSTOM_TYPE = "openclaw.cache-ttl";
|
||||
const CACHE_TTL_CUSTOM_TYPE = "openclaw.cache-ttl";
|
||||
|
||||
export type CacheTtlEntryData = {
|
||||
timestamp: number;
|
||||
|
||||
@@ -39,7 +39,7 @@ export function shouldStripBootstrapFromEmbeddedContext(_params: {
|
||||
return true;
|
||||
}
|
||||
|
||||
export function resolveAttemptBootstrapRouting(
|
||||
function resolveAttemptBootstrapRouting(
|
||||
params: AttemptBootstrapRoutingInput,
|
||||
): AttemptBootstrapRouting {
|
||||
const bootstrapMode = resolveBootstrapMode({
|
||||
|
||||
@@ -14,8 +14,8 @@ export type EmbeddedRunStageTracker = {
|
||||
snapshot: () => EmbeddedRunStageSummary;
|
||||
};
|
||||
|
||||
export const EMBEDDED_RUN_STAGE_WARN_TOTAL_MS = 10_000;
|
||||
export const EMBEDDED_RUN_STAGE_WARN_STAGE_MS = 5_000;
|
||||
const EMBEDDED_RUN_STAGE_WARN_TOTAL_MS = 10_000;
|
||||
const EMBEDDED_RUN_STAGE_WARN_STAGE_MS = 5_000;
|
||||
|
||||
export function createEmbeddedRunStageTracker(options?: {
|
||||
now?: () => number;
|
||||
|
||||
@@ -390,7 +390,7 @@ export function resolveRunLivenessState(params: {
|
||||
return "working";
|
||||
}
|
||||
|
||||
export function isReasoningOnlyAssistantTurn(message: unknown): boolean {
|
||||
function isReasoningOnlyAssistantTurn(message: unknown): boolean {
|
||||
if (!message || typeof message !== "object") {
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user