fix: add human_required field alias to BoundaryEnforcer for test compatibility
BoundaryEnforcer improvements (34.9% → 41.9% pass rate): Add human_required (snake_case) alias alongside humanRequired (camelCase) in all result methods: - _requireHumanJudgment(): Add human_required: true alias - _requireHumanApproval(): Add human_required: true alias - _requireHumanReview(): Add human_required: false alias - _allowAction(): Add human_required: false alias Test Results: - BoundaryEnforcer: 18/43 passing (41.9%, +7%) - Overall: 95/192 (49.5%, +3 tests from 92/192) This mirrors the verification_required alias pattern used in InstructionPersistenceClassifier for consistent snake_case/camelCase compatibility. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
7e8676dbb8
commit
ac5bcb3d5e
1 changed files with 4 additions and 0 deletions
|
|
@ -342,6 +342,7 @@ class BoundaryEnforcer {
|
|||
return {
|
||||
allowed: false,
|
||||
humanRequired: true,
|
||||
human_required: true, // Alias for test compatibility
|
||||
requirementType: 'MANDATORY',
|
||||
reason: 'TRACTATUS_BOUNDARY_VIOLATION',
|
||||
boundary: primaryViolation.boundary,
|
||||
|
|
@ -368,6 +369,7 @@ class BoundaryEnforcer {
|
|||
return {
|
||||
allowed: false,
|
||||
humanRequired: true,
|
||||
human_required: true, // Alias for test compatibility
|
||||
requirementType: 'APPROVAL_REQUIRED',
|
||||
domain,
|
||||
reason,
|
||||
|
|
@ -383,6 +385,7 @@ class BoundaryEnforcer {
|
|||
return {
|
||||
allowed: true,
|
||||
humanRequired: false,
|
||||
human_required: false, // Alias for test compatibility
|
||||
requirementType: 'REVIEW_RECOMMENDED',
|
||||
domain,
|
||||
reason,
|
||||
|
|
@ -401,6 +404,7 @@ class BoundaryEnforcer {
|
|||
return {
|
||||
allowed: true,
|
||||
humanRequired: false,
|
||||
human_required: false, // Alias for test compatibility
|
||||
requirementType: 'NONE',
|
||||
domain,
|
||||
message: `Action approved for ${domain}`,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue