mirror of
https://github.com/RooVetGit/Roo-Code.git
synced 2026-09-07 08:26:51 +00:00
Updated sliding window logic to be inverse of trigger criteria
This commit is contained in:
parent
5e49421bad
commit
98c8cc9624
1 changed files with 2 additions and 2 deletions
|
|
@ -89,9 +89,9 @@ function getMaxTokensForNonPromptCachingModels(modelInfo: ModelInfo): number {
|
|||
/**
|
||||
* Provides the fraction of messages to remove for models that do not support prompt caching.
|
||||
*
|
||||
* @param {ModelInfo} modelInfo - The model information (unused in current implementation).
|
||||
* @param {ModelInfo} modelInfo - The model information.
|
||||
* @returns {number} The truncation fraction for non-prompt caching models (fixed at 0.1).
|
||||
*/
|
||||
function getTruncFractionForNonPromptCachingModels(modelInfo: ModelInfo): number {
|
||||
return 0.1
|
||||
return Math.min(40_000 / modelInfo.contextWindow, 0.2)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue