skillrequest

package
v0.60.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 6, 2026 License: Apache-2.0 Imports: 8 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package skillrequest is the grammar of a skill request (skills design D15): the first lines of a maintainer's issue, which the factory reads and nothing else does. A request generates a skill (plan 3), imports one from GitHub or removes one (plan 4). It is Kubernetes-free and pure.

Index

Constants

View Source
const (
	MaxSentence = 1024 // bytes of a generate request's sentence
	MaxLessons  = 8    // lessons one generate request may codify, the recall cap
	MaxName     = 64   // a skill name, the Agent Skills standard's bound
)

Bounds of a request.

Variables

View Source
var ErrInvalid = errors.New("skill request")

ErrInvalid reports a body that starts as a skill request and breaks the grammar.

Functions

This section is empty.

Types

type Kind

type Kind string

Kind is what a request asks for.

const (
	Generate Kind = "generate"
	Import   Kind = "import"
	Remove   Kind = "remove"
)

The request kinds.

type Request

type Request struct {
	Kind     Kind
	Sentence string
	Lessons  []int
	Source   Source
	Roles    []string
	Name     string
}

Request is one parsed skill request; only the kind's own fields are set.

func Parse

func Parse(body string) (r Request, isRequest bool, err error)

Parse reads body's first non-blank line. isRequest is false when that line does not start with "skill:"; then the issue is an ordinary task. A request that breaks the grammar is isRequest with an error wrapping ErrInvalid, and the returned Request carries only its Kind once the kind is recognised, so a refusal can be counted under it.

type Source

type Source struct{ Repository, Path, Ref string }

Source is an import's GitHub source.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL