Documentation
¶
Index ¶
Constants ¶
View Source
const DefaultDir = "library"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Catalog ¶
type Catalog struct {
Tasks []TaskDefinition
// contains filtered or unexported fields
}
Catalog contains all loaded library task definitions.
func LoadCatalog ¶
LoadCatalog loads and validates library tasks from ./library/*.json.
func (Catalog) ExpandRunConfig ¶
ExpandRunConfig resolves one library task name into a standard harness run config.
func (Catalog) Summaries ¶
func (c Catalog) Summaries() []TaskSummary
Summaries returns stable task metadata for UI and runtime registration.
type TaskDefinition ¶
type TaskDefinition struct {
Name string `json:"name"`
DisplayName string `json:"displayName"`
Type string `json:"type"`
Icon string `json:"icon"`
Description string `json:"description"`
TargetSubdir string `json:"targetSubdir"`
Prompt string `json:"prompt"`
CommitMessage string `json:"commitMessage"`
PRTitle string `json:"prTitle"`
PRBody string `json:"prBody"`
Labels []string `json:"labels"`
GitHubHandle string `json:"githubHandle"`
Reviewers []string `json:"reviewers"`
}
TaskDefinition is one callable library entry loaded from ./library/*.json.
func (*TaskDefinition) UnmarshalJSON ¶
func (t *TaskDefinition) UnmarshalJSON(data []byte) error
UnmarshalJSON supports canonical camelCase keys.
type TaskSummary ¶
type TaskSummary struct {
Name string `json:"name"`
DisplayName string `json:"displayName,omitempty"`
Type string `json:"type,omitempty"`
Icon string `json:"icon,omitempty"`
Description string `json:"description,omitempty"`
Prompt string `json:"prompt,omitempty"`
}
TaskSummary is the public UI/runtime registration view of one library task.
func OrderSummariesByUsage ¶
func OrderSummariesByUsage(summaries []TaskSummary, usage map[string]int) []TaskSummary
OrderSummariesByUsage reorders library tasks by descending local usage count. Ties preserve the incoming order.
Click to show internal directories.
Click to hide internal directories.