将计划清单、运行中插话和个人记忆接入云端 Agent;全站模型选择器统一为左右二级菜单。画布摘要按预算截断不再整轮拒绝,首页视频未知宽高可入库。README 补充贡献者 morrow。 Co-authored-by: Cursor <cursoragent@cursor.com>
35 lines
1.4 KiB
Go
35 lines
1.4 KiB
Go
package model
|
|
|
|
import "time"
|
|
|
|
const (
|
|
AgentLessonStatusPending = "pending"
|
|
AgentLessonStatusApproved = "approved"
|
|
AgentLessonStatusRejected = "rejected"
|
|
)
|
|
|
|
// AgentLessonStep 是一条记忆路线里的一步。
|
|
type AgentLessonStep struct {
|
|
Tool string `json:"tool"`
|
|
Action string `json:"action"`
|
|
Note string `json:"note,omitempty"`
|
|
}
|
|
|
|
// AgentLesson 是用户私有的 Agent 记忆。只有该用户批准后才会注入自己的会话。
|
|
type AgentLesson struct {
|
|
ID string `json:"id" gorm:"primaryKey;size:36"`
|
|
Topic string `json:"topic" gorm:"size:120;index"`
|
|
Category string `json:"category" gorm:"size:32;index"`
|
|
Situation string `json:"situation" gorm:"type:text"`
|
|
Lesson string `json:"lesson" gorm:"type:text"`
|
|
Source string `json:"source" gorm:"size:200"`
|
|
StepsJSON string `json:"-" gorm:"column:steps_json;type:text"`
|
|
Status string `json:"status" gorm:"size:16;index:idx_agent_lessons_author_status,priority:2;index"`
|
|
AuthorUserID string `json:"-" gorm:"size:36;index:idx_agent_lessons_author_status,priority:1;index"`
|
|
Hits int64 `json:"hits"`
|
|
Injected int64 `json:"injected"`
|
|
LastVerifiedAt *time.Time `json:"lastVerifiedAt,omitempty"`
|
|
CreatedAt time.Time `json:"createdAt"`
|
|
UpdatedAt time.Time `json:"updatedAt"`
|
|
}
|