promptschema

package
v1.131.2 Latest Latest
Warning

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

Go to latest
Published: Sep 12, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package promptschema builds the manage_prompt input schema.

It is a separate package for the reason the structural gate exists: the prompt layer is at its size ceiling, and the tool schema is the piece that comes out whole — a pure function over the command set, with no store, no context, and no behavior. Extracting it also closes a drift seam: the command enum is now DERIVED from the dispatch table the caller passes in, so a command the layer handles can no longer be missing from the schema an agent reads.

Index

Constants

View Source
const (
	KeyType        = "type"
	KeyDescription = "description"
	KeyItems       = "items"
	KeyEnum        = "enum"
	ValString      = "string"
	ValArray       = "array"
)

JSON schema keys and values, exported because the sibling show_prompts schema is written in the same vocabulary.

Variables

This section is empty.

Functions

func ManagePrompt

func ManagePrompt(commands []string) any

ManagePrompt returns the JSON schema for the manage_prompt tool. commands is the set the tool dispatches, sorted here so the advertised enum is deterministic and can never omit a command the layer handles.

Types

This section is empty.

Jump to

Keyboard shortcuts

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