Агенты: новая сессия вместо resume (память в промте), живой агент по простою 4 мин сводит память; экономия лимита (deviations п.69)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { join } from "node:path";
|
||||
import { basename, join } from "node:path";
|
||||
import { createLogger, createPool, itNotify, loadServiceSettings } from "khb_common";
|
||||
import { createCliRunner } from "./agents/cli-runner.js";
|
||||
import { summarizeIdle } from "./agents/idle-memory.js";
|
||||
import { createLiveRunner } from "./agents/live-runner.js";
|
||||
import { loadFragment } from "./agents/prompts.js";
|
||||
import { listManagers } from "./managers.js";
|
||||
@@ -37,6 +38,7 @@ const ctx: AgentContext = {
|
||||
? createLiveRunner({
|
||||
bin: service.agent.claudeBin, model: service.agent.model, timeoutMs: service.agent.timeoutMs,
|
||||
idleMs: service.agent.live.idleMinutes * 60_000, warmupMs: service.agent.live.warmupSeconds * 1000,
|
||||
onIdle: (cwd) => summarizeIdle(ctx, basename(cwd)),
|
||||
onEvent: (e) => log.info({ ...e }, "долгоживущий агент"),
|
||||
})
|
||||
: undefined,
|
||||
|
||||
Reference in New Issue
Block a user