Skip to content

Conversation

@hyperpolymath
Copy link
Owner

No description provided.

claude and others added 5 commits December 27, 2025 14:14
Add the gating-contract crate which formalizes the policy enforcement
contract with:

- Inputs: GatingRequest with proposal, context, and metadata
- Outputs: GatingDecision with verdict, refusal details, evaluations
- Refusal Taxonomy: 11 categories with 25+ specific refusal codes
  - Language violations (100-199)
  - Toolchain violations (200-299)
  - Security violations (300-399)
  - Pattern violations (400-499)
  - Spirit violations (500-599)
  - System errors (900-999)
- Audit Log: AuditEntry with full decision traceability
- Minimal Runner: ContractRunner and TestHarness for validation

CLI additions:
- conative contract schema: Display contract specification
- conative contract test: Run tests from training data
- conative contract eval: Evaluate gating requests with audit output

All 8 contract unit tests pass. Test harness exposes known Oracle
limitations (marker-based detection has false positives for TypeScript
and Python markers in Rust/Elixir code).
Add comprehensive adversarial testing and regression detection:

Red-Team Suite (14 test cases):
- bypass/: Documentation and comment embedding attacks
- obfuscation/: Marker splitting, case variation, extension masking
- encoding/: Base64/hex encoded secrets
- boundary/: Empty files, whitespace-only, unicode edge cases
- injection/: Polyglot files, URL secrets, concatenated secrets

Security Score: 64/100 (9 blocked, 4 bypassed, 0 false positives)
Known limitations: Encoded/split secrets require SLM evaluation

Regression Harness:
- RegressionBaseline: Versioned baseline with git commit tracking
- RegressionHarness: Compare current vs baseline results
- RegressionReport: Detect regressions, improvements, behavior changes

CLI additions:
- conative contract redteam: Run adversarial test suite
- conative contract regression: Compare against saved baseline
- conative contract regression --save: Create new baseline
- Replace SECURITY.md template with project-specific content
- Add missing ConativeGating.Application module for Elixir arbiter
- Add SPDX license headers to arbiter Elixir files
- Update ROADMAP.adoc: arbiter now STARTED with 5 tasks complete
- Improve contract lib.rs comments with phase references
Signed-off-by: Jonathan D.A. Jewell <6759885+hyperpolymath@users.noreply.github.com>
@hyperpolymath hyperpolymath merged commit d660a3c into main Dec 28, 2025
13 of 21 checks passed
@hyperpolymath hyperpolymath deleted the claude/freeze-gating-contract-JSyXa branch December 28, 2025 01:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants