Files
cleveragents-core/docs/schema/validation.schema.yaml
Jeff dfb91781aa
CI / lint (pull_request) Successful in 14s
CI / typecheck (pull_request) Successful in 26s
CI / security (pull_request) Successful in 21s
CI / quality (pull_request) Successful in 15s
CI / integration_tests (pull_request) Successful in 4m10s
CI / build (pull_request) Successful in 16s
CI / unit_tests (pull_request) Successful in 8m23s
CI / docker (pull_request) Successful in 39s
CI / coverage (pull_request) Successful in 6m21s
CI / lint (push) Waiting to run
CI / typecheck (push) Waiting to run
CI / security (push) Waiting to run
CI / quality (push) Waiting to run
CI / unit_tests (push) Waiting to run
CI / integration_tests (push) Waiting to run
CI / coverage (push) Blocked by required conditions
CI / build (push) Waiting to run
CI / docker (push) Blocked by required conditions
feat(tool): add tool and validation domain models
2026-02-14 00:35:04 +00:00

95 lines
2.6 KiB
YAML

# Validation YAML Schema
# Extends the Tool schema with validation-specific fields.
# See docs/specification.md for full details.
type: object
required:
- name
- description
properties:
name:
type: string
pattern: "^[a-zA-Z0-9_-]+/[a-zA-Z0-9_-]+$"
description: "Namespaced validation name (namespace/short_name)"
description:
type: string
minLength: 1
description: "Short description of what the validation checks"
source:
type: string
enum: [mcp, agent_skill, builtin, custom, wrapped]
description: "Source of the validation implementation (inferred as 'wrapped' when wraps is set)"
mode:
type: string
enum: [required, informational]
default: required
description: "Whether failure blocks execution"
wraps:
type: string
description: "Name of existing tool this validation wraps"
transform:
type: string
description: "Python function code to transform wrapped tool output (required when wraps is set)"
argument_mapping:
type: object
description: "Argument mapping for the wrapped tool (only valid when wraps is set)"
code:
type: string
description: "Inline Python code (required when source=custom, mutually exclusive with wraps)"
mcp_server:
type: string
description: "MCP server name (required when source=mcp)"
mcp_tool_name:
type: string
description: "Tool name on MCP server (required when source=mcp)"
agent_skill_path:
type: string
description: "Path to Agent Skills Standard folder (required when source=agent_skill)"
input_schema:
type: object
description: "JSON Schema for validation inputs"
output_schema:
type: object
description: "JSON Schema for validation outputs"
capability:
type: object
description: "Capability metadata (read_only, writes, checkpointable forced for validations)"
resource_slots:
type: array
items:
type: object
required: [name, resource_type, access]
properties:
name:
type: string
resource_type:
type: string
access:
type: string
enum: [read_only, read_write]
description:
type: string
binding:
type: string
enum: [contextual, static, parameter]
default: contextual
static_resource:
type: string
required:
type: boolean
default: true
lifecycle:
type: object
properties:
discover:
type: string
activate:
type: string
deactivate:
type: string
timeout:
type: integer
minimum: 1
default: 300
description: "Execution timeout in seconds"