Files
Dragan Spiridonov 7f01310556 fix(adr-093): aqe init + skill evals + settings routing use new models
New user projects created via aqe init will now receive the post-ADR-093
model set (Opus 4.7 / Sonnet 4.6 / Haiku 4.5) instead of retiring IDs.

* src/init/kiro-installer.ts: 4 hardcoded model fallbacks updated.
  claude-sonnet-4 → claude-sonnet-4-6 (default + priority=critical),
  claude-opus-4 → claude-opus-4-7 (opus-detected path),
  claude-haiku-4 → claude-haiku-4-5 (haiku-detected path).
  Affects: runtime agent transformation, default QE agent template
  (writeDefaultQEAgent).
* src/init/init-wizard-steps.ts, src/init/phases/12-verification.ts:
  generated aqe.yaml advisor block comment updated to
  anthropic/claude-opus-4.7 so wizard-produced configs point to the
  right advisor model out of the box.
* .claude/settings.json:188-189: claudeFlow.modelPreferences
  default claude-opus-4-5-20251101 → claude-opus-4-7,
  routing claude-3-5-haiku-20241022 → claude-haiku-4-5-20251001.
* Skill eval YAMLs (both .claude/ and assets/ copies):
  api-testing-patterns, contract-testing, database-testing,
  testability-scoring — models_to_test list updated from
  claude-sonnet-4 / claude-3-haiku to claude-sonnet-4-6 / claude-haiku-4-5.
* Skill eval schemas (3 copies: .claude, assets, docs):
  skill-eval.schema.json enum extended with claude-opus-4-7,
  claude-sonnet-4-6, claude-haiku-4-5 as accepted values. Old
  entries retained for backward compat with existing eval files.
* Sample outputs (3 copies): modelUsed field updated to
  claude-sonnet-4-6.
* a11y-ally SKILL.md code example (both .claude and assets):
  model: 'claude-sonnet-4-20250514' → 'claude-sonnet-4-6' (this was
  caught by Commit 2's sweep; landed here for audit completeness).

Verification:
* 0 tsc errors
* 392/392 init module tests pass
* npm run build: CLI + MCP bundles rebuilt clean

Not re-running aqe init against a real fixture in this commit —
minimal+non-interactive mode doesn't materialize integration files
(kiro/opencode); full wizard-mode verification deferred until after
PR opens and a maintainer runs init smoke.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-17 13:40:14 +00:00

456 lines
14 KiB
JSON

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://agentic-qe.dev/schemas/skill-eval.json",
"title": "AQE Skill Evaluation Test Suite Schema",
"description": "Schema for skill evaluation YAML test suites used in Trust Tier 3 validation. Supports multi-model testing, AQE MCP integration, and ReasoningBank learning.",
"type": "object",
"required": ["skill", "version", "test_cases", "success_criteria"],
"properties": {
"skill": {
"type": "string",
"pattern": "^[a-z][a-z0-9-]*$",
"description": "Skill name being evaluated (must match .claude/skills/{skill}/SKILL.md)"
},
"version": {
"type": "string",
"pattern": "^\\d+\\.\\d+\\.\\d+$",
"description": "Evaluation suite version (semver)"
},
"description": {
"type": "string",
"maxLength": 1000,
"description": "Description of evaluation suite purpose and coverage goals"
},
"models_to_test": {
"type": "array",
"items": {
"type": "string",
"enum": [
"claude-opus-4-7",
"claude-sonnet-4-6",
"claude-haiku-4-5",
"claude-opus-4-5",
"claude-sonnet-4",
"claude-3.5-sonnet",
"claude-3-haiku",
"gpt-4o",
"gpt-4o-mini",
"gpt-4-turbo"
]
},
"default": ["claude-3.5-sonnet"],
"minItems": 1,
"uniqueItems": true,
"description": "Models to run evaluation against for cross-model validation"
},
"mcp_integration": {
"$ref": "#/$defs/mcp_integration_config",
"description": "AQE MCP integration configuration for shared learning"
},
"learning": {
"$ref": "#/$defs/learning_config",
"description": "ReasoningBank learning configuration"
},
"result_format": {
"$ref": "#/$defs/result_format",
"description": "Output format configuration"
},
"setup": {
"type": "object",
"description": "Setup configuration for test environment",
"properties": {
"required_tools": {
"type": "array",
"items": { "type": "string" },
"description": "Tools that must be available"
},
"environment_variables": {
"type": "object",
"additionalProperties": { "type": "string" },
"description": "Environment variables to set"
},
"fixtures": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": { "type": "string" },
"path": { "type": "string" },
"content": { "type": "string" }
}
},
"description": "Test fixtures to create"
}
}
},
"test_cases": {
"type": "array",
"minItems": 1,
"items": {
"$ref": "#/$defs/test_case"
},
"description": "Evaluation test cases"
},
"success_criteria": {
"type": "object",
"required": ["pass_rate"],
"properties": {
"pass_rate": {
"type": "number",
"minimum": 0,
"maximum": 1,
"description": "Minimum pass rate for suite to pass"
},
"critical_pass_rate": {
"type": "number",
"minimum": 0,
"maximum": 1,
"default": 1.0,
"description": "Pass rate required for critical priority tests"
},
"avg_reasoning_quality": {
"type": "number",
"minimum": 0,
"maximum": 1,
"description": "Minimum average reasoning quality score"
},
"max_execution_time_ms": {
"type": "integer",
"minimum": 0,
"description": "Maximum execution time for test suite"
},
"cross_model_variance": {
"type": "number",
"minimum": 0,
"maximum": 1,
"description": "Maximum allowed variance between models"
}
}
},
"metadata": {
"type": "object",
"properties": {
"author": { "type": "string" },
"created": { "type": "string", "format": "date" },
"last_updated": { "type": "string", "format": "date" },
"coverage_target": { "type": "string" }
}
}
},
"$defs": {
"test_case": {
"type": "object",
"required": ["id", "description", "input", "expected_output"],
"properties": {
"id": {
"type": "string",
"pattern": "^tc\\d{3}_[a-z_]+$",
"description": "Test case ID (e.g., tc001_sql_injection)"
},
"description": {
"type": "string",
"description": "What this test case validates"
},
"category": {
"type": "string",
"description": "Test category for grouping"
},
"priority": {
"type": "string",
"enum": ["critical", "high", "medium", "low"],
"default": "medium",
"description": "Test priority"
},
"skip": {
"type": "boolean",
"default": false,
"description": "Skip this test case"
},
"skip_reason": {
"type": "string",
"description": "Reason for skipping"
},
"input": {
"$ref": "#/$defs/test_input"
},
"expected_output": {
"$ref": "#/$defs/expected_output"
},
"validation": {
"$ref": "#/$defs/validation_config"
},
"timeout_ms": {
"type": "integer",
"minimum": 1000,
"default": 30000,
"description": "Test timeout in milliseconds"
}
}
},
"test_input": {
"type": "object",
"description": "Input provided to the skill",
"properties": {
"code": {
"type": "string",
"description": "Code snippet to analyze"
},
"file_path": {
"type": "string",
"description": "Path to file to analyze"
},
"url": {
"type": "string",
"format": "uri",
"description": "URL to analyze"
},
"prompt": {
"type": "string",
"description": "Custom prompt for the skill"
},
"context": {
"type": "object",
"properties": {
"language": {
"type": "string",
"description": "Programming language"
},
"framework": {
"type": "string",
"description": "Framework in use"
},
"environment": {
"type": "string",
"enum": ["development", "staging", "production"],
"description": "Target environment"
}
}
},
"options": {
"type": "object",
"additionalProperties": true,
"description": "Skill-specific options"
}
}
},
"expected_output": {
"type": "object",
"description": "Expected characteristics of skill output",
"properties": {
"must_contain": {
"type": "array",
"items": { "type": "string" },
"description": "Strings that must appear in output"
},
"must_not_contain": {
"type": "array",
"items": { "type": "string" },
"description": "Strings that must not appear in output"
},
"must_match_regex": {
"type": "array",
"items": { "type": "string" },
"description": "Regex patterns output must match"
},
"severity_classification": {
"type": "string",
"enum": ["critical", "high", "medium", "low", "info"],
"description": "Expected severity classification"
},
"finding_count": {
"type": "object",
"properties": {
"min": { "type": "integer", "minimum": 0 },
"max": { "type": "integer", "minimum": 0 }
},
"description": "Expected range of findings"
},
"recommendation_count": {
"type": "object",
"properties": {
"min": { "type": "integer", "minimum": 0 },
"max": { "type": "integer", "minimum": 0 }
},
"description": "Expected range of recommendations"
},
"schema_path": {
"type": "string",
"description": "Path to JSON schema for output validation"
},
"custom_assertions": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["jsonpath", "semantic", "function"]
},
"expression": { "type": "string" },
"expected": {}
}
},
"description": "Custom assertions for complex validation"
}
}
},
"validation_config": {
"type": "object",
"description": "Validation configuration for test case",
"properties": {
"schema_check": {
"type": "boolean",
"default": true,
"description": "Validate output against schema"
},
"keyword_match_threshold": {
"type": "number",
"minimum": 0,
"maximum": 1,
"default": 0.8,
"description": "Minimum keyword match ratio for pass"
},
"reasoning_quality_min": {
"type": "number",
"minimum": 0,
"maximum": 1,
"description": "Minimum reasoning quality score"
},
"semantic_similarity_min": {
"type": "number",
"minimum": 0,
"maximum": 1,
"description": "Minimum semantic similarity to expected"
},
"allow_partial": {
"type": "boolean",
"default": false,
"description": "Allow partial matches"
},
"grading_rubric": {
"type": "object",
"properties": {
"completeness": { "type": "number", "minimum": 0, "maximum": 1 },
"accuracy": { "type": "number", "minimum": 0, "maximum": 1 },
"actionability": { "type": "number", "minimum": 0, "maximum": 1 }
},
"description": "Weighted grading rubric (weights should sum to 1.0)"
}
}
},
"mcp_integration_config": {
"type": "object",
"description": "Configuration for AQE MCP tool integration per MCP Integration Spec",
"properties": {
"enabled": {
"type": "boolean",
"default": true,
"description": "Enable MCP integration for this eval suite"
},
"namespace": {
"type": "string",
"default": "skill-validation",
"description": "Memory namespace for storing patterns and outcomes"
},
"store_patterns": {
"type": "boolean",
"default": true,
"description": "Store successful patterns via mcp__agentic-qe__memory_store"
},
"query_patterns": {
"type": "boolean",
"default": true,
"description": "Query existing patterns before running via mcp__agentic-qe__memory_query"
},
"track_outcomes": {
"type": "boolean",
"default": true,
"description": "Track test outcomes via mcp__agentic-qe__test_outcome_track"
},
"share_learning": {
"type": "boolean",
"default": true,
"description": "Share learning with fleet via mcp__agentic-qe__memory_share"
},
"update_quality_gate": {
"type": "boolean",
"default": true,
"description": "Update quality gate metrics via mcp__agentic-qe__quality_assess"
},
"target_agents": {
"type": "array",
"items": { "type": "string" },
"default": ["qe-learning-coordinator", "qe-queen-coordinator"],
"description": "Agent IDs to share learning with"
}
}
},
"learning_config": {
"type": "object",
"description": "Configuration for ReasoningBank learning integration",
"properties": {
"store_success_patterns": {
"type": "boolean",
"default": true,
"description": "Store patterns from successful test runs"
},
"store_failure_patterns": {
"type": "boolean",
"default": true,
"description": "Store patterns from failures for learning"
},
"pattern_ttl_days": {
"type": "integer",
"minimum": 1,
"maximum": 365,
"default": 90,
"description": "Time-to-live for stored patterns in days"
},
"min_confidence_to_store": {
"type": "number",
"minimum": 0,
"maximum": 1,
"default": 0.7,
"description": "Minimum confidence score to store pattern"
},
"cross_model_comparison": {
"type": "boolean",
"default": true,
"description": "Store cross-model behavior comparisons"
}
}
},
"result_format": {
"type": "object",
"description": "Output format configuration for evaluation results",
"properties": {
"json_output": {
"type": "boolean",
"default": true,
"description": "Output results as JSON"
},
"markdown_report": {
"type": "boolean",
"default": false,
"description": "Generate markdown report"
},
"include_raw_output": {
"type": "boolean",
"default": false,
"description": "Include raw LLM output in results"
},
"include_timing": {
"type": "boolean",
"default": true,
"description": "Include timing information"
},
"include_token_usage": {
"type": "boolean",
"default": true,
"description": "Include token usage statistics"
}
}
}
}
}