UNPKG

@sema-agent/core

Version:

Stateless, task-oriented AI agent core

25 lines (24 loc) • 1.06 kB
export const DATE_ANCHOR_CUSTOM_TYPE = "engine:date-anchor"; export const LEG_CLOSE_RECORDS = { message: false, custom_message: false, compaction: false, thinking_level_change: false, model_change: false, custom: { [DATE_ANCHOR_CUSTOM_TYPE]: "the settle's leg-end records (runner/continues-from.ts legEndRecords → owedDateAnchor)" }, label: false, session_info: false, leaf: false, prompt_epoch: false, announced_listing: "the leg exit's owed-snapshot flush (runner/run-leg.ts → flushOwedAnnouncedSnapshot)", workspace_state: false, reminder_mark: false, git_announcement: "the leg exit's git mirror flush (runner/run-git-lane.ts flushGitMirror)", session_checkout: false, run_ledger: "the settle's member-ledger snapshot (runner/run-settle-and-teardown.ts appendRunLedger)", }; export function isLegCloseRecord(entry) { if (entry.type === "custom") return Object.hasOwn(LEG_CLOSE_RECORDS.custom, entry.customType); return typeof LEG_CLOSE_RECORDS[entry.type] === "string"; }