Expand description
会话的配置与状态,按读写性质拆开,而不是一个什么都装的上下文对象:
- 只读配置 →
Arc<EngineConfig> - 可变运行期 →
Arc<dyn Session>(内部按需 split lock)
Re-exports§
Modules§
- config
- 引擎只读配置 + 模型窗口推断。
- goal
- Session goals: an objective the engine keeps working on across turns, one automatic round at a time, until the model marks it complete or blocked or its rounds or its token budget run out.
- ledger
- What a session has spent and asked for over its turns — kept on its
SessionState(insession-state), so it outlives the engine that ran them. Its token total is also in the session log (agix.spend), so it outlives the process. - session
- 会话状态的契约:引擎从设置推出来的
SessionEnv、写进会话日志的DurableState、 工具与策略经Arc<dyn Session>看到的Sessiontrait,以及绑定任务生命周期的TaskScope/TaskLease。实现在session-statecrate,是这个 trait 唯一的实现。 - task
- 后台任务 + todo 条目类型。