refactor: trim agent type exports · openclaw/openclaw@c6ceb3e
steipete
·
2026-05-02
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -7,7 +7,7 @@ export const CONTEXT_WINDOW_WARN_BELOW_TOKENS = 8_000;
|
7 | 7 | const CONTEXT_WINDOW_HARD_MIN_RATIO = 0.1; |
8 | 8 | const CONTEXT_WINDOW_WARN_BELOW_RATIO = 0.2; |
9 | 9 | |
10 | | -export type ContextWindowSource = "model" | "modelsConfig" | "agentContextTokens" | "default"; |
| 10 | +type ContextWindowSource = "model" | "modelsConfig" | "agentContextTokens" | "default"; |
11 | 11 | |
12 | 12 | export type ContextWindowInfo = { |
13 | 13 | tokens: number; |
@@ -62,19 +62,19 @@ export function resolveContextWindowInfo(params: {
|
62 | 62 | return baseInfo; |
63 | 63 | } |
64 | 64 | |
65 | | -export type ContextWindowGuardResult = ContextWindowInfo & { |
| 65 | +type ContextWindowGuardResult = ContextWindowInfo & { |
66 | 66 | hardMinTokens: number; |
67 | 67 | warnBelowTokens: number; |
68 | 68 | shouldWarn: boolean; |
69 | 69 | shouldBlock: boolean; |
70 | 70 | }; |
71 | 71 | |
72 | | -export type ContextWindowGuardThresholds = { |
| 72 | +type ContextWindowGuardThresholds = { |
73 | 73 | hardMinTokens: number; |
74 | 74 | warnBelowTokens: number; |
75 | 75 | }; |
76 | 76 | |
77 | | -export type ContextWindowGuardHint = { |
| 77 | +type ContextWindowGuardHint = { |
78 | 78 | endpointClass: ReturnType<typeof resolveProviderEndpoint>["endpointClass"]; |
79 | 79 | likelySelfHosted: boolean; |
80 | 80 | }; |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。