feat(agent): 云端 Agent - 增加上下文预算、任务事实与终态恢复保障

This commit is contained in:
ddCat committed 2026-09-19 20:43:20 +08:00
1 parent 3bf21d79af
commit b52bc9d5f2
61 files changed
+3512 -309

No files matched your search

+3 -1
View File
@@ -54,7 +54,9 @@ type BillingOrder struct {
Quantity int64 `json:"quantity"`
AmountMicrocredits int64 `json:"amountMicrocredits"`
ReservedAmountMicrocredits int64 `json:"reservedAmountMicrocredits"`
// ChargeLimitMicrocredits 非零时限制最终用户扣费;Agent 的 Token 报价用它把预授权金额固化为本轮硬上限。
// ChargeLimitSet distinguishes an authorized zero price from an uncapped order.
// All Agent prices remain capped across route changes and settlement.
ChargeLimitSet bool `json:"chargeLimitSet,omitempty" gorm:"not null;default:false"`
ChargeLimitMicrocredits int64 `json:"chargeLimitMicrocredits,omitempty"`
ActualAmountMicrocredits int64 `json:"actualAmountMicrocredits"`
RefundedAmountMicrocredits int64 `json:"refundedAmountMicrocredits"`