/* Allhelp 万能助理模块 - 用户任务记录(仅记录,不做自动触发) + 每日聊天总结(异步AI) */ package allhelp import ( "yunyan/comm" "yunyan/modules" "yunyan/lego/base" "yunyan/lego/core" ) func NewModule() core.IModule { m := new(Allhelp) return m } type Allhelp struct { modules.ModuleBase service base.IRPCXService api *apiComp model *modelComp summary *summaryComp options *Options } func (this *Allhelp) GetType() core.M_Modules { return comm.ModuleAllhelp } func (this *Allhelp) NewOptions() (options core.IModuleOptions) { return new(Options) } func (this *Allhelp) Init(service core.IService, module core.IModule, options core.IModuleOptions) (err error) { this.service = service.(base.IRPCXService) this.options = options.(*Options) if err = this.ModuleBase.Init(service, module, options); err != nil { return } return } func (this *Allhelp) Start() (err error) { if err = this.ModuleBase.Start(); err != nil { return } return } func (this *Allhelp) OnInstallComp() { this.ModuleBase.OnInstallComp() this.api = this.RegisterComp(new(apiComp)).(*apiComp) this.model = this.RegisterComp(new(modelComp)).(*modelComp) this.summary = this.RegisterComp(new(summaryComp)).(*summaryComp) }