Documentation
¶
Index ¶
- Constants
- func InputSchema(name string, cfg config.Config) (map[string]any, bool)
- func ManageInputSchema(cfg config.Config) map[string]any
- func ManageOutputSchema(cfg config.Config) map[string]any
- func OutputSchema(name string, cfg config.Config) (map[string]any, bool)
- type ConfigProvider
- type EvolutionProvider
- type LearningCheckRequest
- type ManageRequest
- type Result
- type Service
- func (s *Service) Manage(ctx context.Context, request ManageRequest) (Result, error)
- func (s *Service) RuntimeTask(id string) (Result, error)
- func (s *Service) RuntimeTaskDelete(id string) (Result, error)
- func (s *Service) RuntimeTasks(status string, limit int) (Result, error)
- func (s *Service) WorkflowManage(ctx context.Context, request WorkflowRequest) (Result, error)
- type StepRequest
- type ToolError
- type WorkflowRequest
Constants ¶
View Source
const ToolTaskManage = "task_manage"
Variables ¶
This section is empty.
Functions ¶
func InputSchema ¶ added in v0.8.2
Types ¶
type ConfigProvider ¶
type EvolutionProvider ¶ added in v0.7.6
type EvolutionProvider interface {
Guidance(context.Context, taskstate.Task) ([]taskstate.EvolutionContextItem, error)
Candidates(context.Context, taskstate.Task) ([]taskstate.EvolutionContextItem, error)
ValidateBindings(context.Context, taskstate.Task, []taskstate.EvolutionBinding) ([]taskstate.EvolutionBinding, error)
ResolveBindings(context.Context, taskstate.Task) error
}
type LearningCheckRequest ¶ added in v0.8.2
type ManageRequest ¶ added in v0.8.2
type ManageRequest struct {
Action string `json:"action"`
Title string `json:"title,omitempty"`
Goal string `json:"goal,omitempty"`
Project string `json:"project,omitempty"`
Device string `json:"device,omitempty"`
CompletionConditions []string `json:"completion_conditions,omitempty"`
Steps []StepRequest `json:"steps,omitempty"`
TemplateID string `json:"template_id,omitempty"`
SourceTemplateIDs []string `json:"source_template_ids,omitempty"`
LearningChecks []LearningCheckRequest `json:"learning_checks,omitempty"`
Status string `json:"status,omitempty"`
Limit *int `json:"limit,omitempty"`
TaskID string `json:"task_id,omitempty"`
StepID string `json:"step_id,omitempty"`
CompletedStepIDs *[]string `json:"completed_step_ids,omitempty"`
CurrentStepID string `json:"current_step_id,omitempty"`
Summary string `json:"summary,omitempty"`
Verified []string `json:"verified,omitempty"`
Risks []string `json:"risks,omitempty"`
}
ManageRequest 只表达 task_manage 对模型公开的输入字段。 持久化状态中的 phase、bound_at 等内部字段在规范化阶段由 Task 域模型补齐,不能从边界注入。
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func New ¶
func New(configProvider ConfigProvider, tasks *taskstate.Store, evolution ...EvolutionProvider) *Service
func (*Service) RuntimeTasks ¶
func (*Service) WorkflowManage ¶
type StepRequest ¶ added in v0.8.2
type WorkflowRequest ¶ added in v0.8.2
type WorkflowRequest struct {
Action string `json:"action"`
TemplateID string `json:"template_id,omitempty"`
TemplateIDs []string `json:"template_ids,omitempty"`
TemplateVersion string `json:"template_version,omitempty"`
TemplateStatus string `json:"template_status,omitempty"`
Goal string `json:"goal,omitempty"`
Device string `json:"device,omitempty"`
Type string `json:"type,omitempty"`
Template *taskstate.Template `json:"template,omitempty"`
AllowLongTemplate *bool `json:"allow_long_template,omitempty"`
LongTemplateReason string `json:"long_template_reason,omitempty"`
}
WorkflowRequest 是 workflow_template_manage 的强类型输入。
Click to show internal directories.
Click to hide internal directories.