Documentation
¶
Overview ¶
Package config provides the get_config tool: a read-only view of seshat's effective security policy (the same values write_file, bash, and every other write-capable tool actually enforce, not a separately maintained description of them), mirroring DesktopCommanderMCP's get_config. Unlike DesktopCommanderMCP, there is no set_config_value counterpart - seshat's policy isn't user-editable at runtime, so exposing it read-only avoids implying a control surface that doesn't exist.
Index ¶
- Constants
- type Tool
- func (t *Tool) BackfillInput(_ context.Context, input map[string]any) map[string]any
- func (t *Tool) Call(_ context.Context, input tool.CallInput, _ types.CanUseToolFn) (tool.CallResult, error)
- func (t *Tool) CheckPermissions(_ context.Context, input map[string]any, _ tool.ToolUseContext) types.PermissionResult
- func (t *Tool) Definition() tool.Definition
- func (t *Tool) Description(_ context.Context) (string, error)
- func (t *Tool) FormatResult(data any) string
- func (t *Tool) IsConcurrencySafe(_ map[string]any) bool
- func (t *Tool) IsEnabled() bool
- func (t *Tool) IsReadOnly(_ map[string]any) bool
- func (t *Tool) ValidateInput(_ context.Context, input map[string]any) (map[string]any, error)
Constants ¶
View Source
const ( // ToolName is the name of the get_config tool. ToolName = "get_config" // SearchHint is a hint for tool search functionality. SearchHint = "view the effective security policy (blocked commands, protected paths, read limits)" // ToolDescription is the description of the get_config tool. ToolDescription = "Get the currently effective security policy: which commands need approval or are always blocked, " + "which paths are protected from reads/writes, file-read size/line limits, the sandbox status, and the active working directory/shell.\n\n" + "## When to use\n\n" + "- Before running a command or touching a path you suspect might be restricted, to check without trial-and-error\n" + "- To explain to the user why a prior tool call was blocked or required approval\n\n" + "## Notes\n\n" + "- Read-only — this tool cannot change any policy setting.\n" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Tool ¶ added in v1.1.0
type Tool struct {
// contains filtered or unexported fields
}
Tool implements the get_config tool.
func (*Tool) BackfillInput ¶ added in v1.1.0
func (*Tool) Call ¶ added in v1.1.0
func (t *Tool) Call( _ context.Context, input tool.CallInput, _ types.CanUseToolFn, ) (tool.CallResult, error)
func (*Tool) CheckPermissions ¶ added in v1.1.0
func (t *Tool) CheckPermissions(_ context.Context, input map[string]any, _ tool.ToolUseContext) types.PermissionResult
func (*Tool) Definition ¶ added in v1.1.0
func (t *Tool) Definition() tool.Definition
func (*Tool) Description ¶ added in v1.1.0
func (*Tool) FormatResult ¶ added in v1.1.0
func (*Tool) IsConcurrencySafe ¶ added in v1.1.0
Click to show internal directories.
Click to hide internal directories.