Documentation
¶
Overview ¶
Package pack provides the pack (framework) registry for the talon init wizard. Packs are starter templates targeting specific AI frameworks (OpenClaw, LangChain, etc.). The wizard calls ListForWizard() to populate the framework selection screen. Community packs can be registered via RegisterPack() from init() functions.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ComplianceOverlayNames ¶
func ComplianceOverlayNames() []string
ComplianceOverlayNames returns the list of overlay names for "all".
func ReadComplianceOverlay ¶
ReadComplianceOverlay returns the content of a compliance overlay file. name must be one of: gdpr, nis2, dora, eu-ai-act.
func RegisterPack ¶
func RegisterPack(p PackDescriptor)
RegisterPack adds a community pack to the registry. Call from an init() function in the pack's package.
func TemplateFS ¶
TemplateFS returns the embedded template filesystem for pack templates.
func ValidPackIDs ¶
func ValidPackIDs() []string
ValidPackIDs returns all non-hidden pack IDs (for flag validation).
Types ¶
type PackDescriptor ¶
type PackDescriptor struct {
ID string // matches --pack flag value and template directory name
DisplayName string
Description string // one line, <=80 chars
Order int // sort position in wizard list; lower = earlier
Hidden bool // when true, excluded from wizard (e.g. deferred packs)
// Optional: when set, init uses these instead of legacy pack_<id> templates.
Framework string // target AI framework (e.g. "LangChain", "CrewAI", "Any")
Files []PackFile // template files to render
PostMessage string // printed after init completes
}
PackDescriptor describes a starter pack shown in the talon init wizard.
func FindByID ¶
func FindByID(id string) (PackDescriptor, bool)
FindByID looks up a pack by ID among all packs (including hidden).
func ListForWizard ¶
func ListForWizard() []PackDescriptor
ListForWizard returns all non-hidden packs sorted by Order.
type PackFile ¶
type PackFile struct {
TemplatePath string // path in embed.FS (e.g. "templates/crewai/agent.talon.yaml")
OutputPath string // where to write (e.g. "agent.talon.yaml")
Description string // human-readable (e.g. "Agent policy")
}
PackFile describes a template file to render for a pack.