Documentation
¶
Index ¶
- func Boolean(description string) map[string]any
- func BoundedInteger(description string, minimum, maximum int) map[string]any
- func CompactValidationError(err error) string
- func InputObject(properties map[string]any, required ...string) map[string]any
- func Integer(description string) map[string]any
- func ObjectArray(description string) map[string]any
- func OpenObject(description string) map[string]any
- func OutputObject(properties map[string]any, required ...string) map[string]any
- func String(description string) map[string]any
- func StringArray(description string) map[string]any
- type InputValidator
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CompactValidationError ¶
func InputObject ¶
InputObject 构造内建工具的根输入对象。结构已知的工具默认拒绝未知字段; 真正动态的字段应在对应 property 上显式声明 additionalProperties。
func ObjectArray ¶
func OpenObject ¶
func OutputObject ¶
OutputObject 保持结果根对象可扩展。输出字段用于帮助客户端理解稳定结果, 但运行时允许能力在不破坏旧客户端的前提下增加新的领域字段。
func StringArray ¶
Types ¶
type InputValidator ¶
type InputValidator struct {
// contains filtered or unexported fields
}
func CompileInputSchema ¶
func CompileInputSchema(raw map[string]any) (*InputValidator, error)
Click to show internal directories.
Click to hide internal directories.