(msg string)
| 1451 | ) |
| 1452 | state.Messages = compressed |
| 1453 | if stats.LevelReached >= 1 { |
| 1454 | e.MarkSkillHistoryCompacted("main") |
| 1455 | } |
| 1456 | if stats.AutoTriggered { |
| 1457 | agentContext.RunPostCompactCleanUp(ctx, state, recentReadFilesForPostCompact(state, 5)) |
| 1458 | e.rebuildSystemPromptAfterHistoryReplace(state) |
| 1459 | e.clearRuntimeCompressionStateAfterHistoryReplace(state) |
| 1460 | return |
| 1461 | } |
| 1462 | e.l3Regions = append([]agentContext.CollapsedRegion(nil), stats.CollapsedRegions...) |
| 1463 | } |
| 1464 |
no outgoing calls