tiny-mod6-verified

Formally verified MOD-6 circuit. Single-layer threshold network computing modulo-6 arithmetic with 100% accuracy.

Architecture

Component Value
Inputs 8
Outputs 1
Parameters 9
Weights [1, 1, 1, 1, 1, -5, 1, 1]
Bias 0
Activation Heaviside step

Key Properties

  • 100% accuracy (256/256 inputs correct)
  • Coq-proven correctness
  • Algebraic weight pattern: position 6 has weight 1-6 = -5
  • Computes Hamming weight mod 6

Usage

import torch
from safetensors.torch import load_file

weights = load_file('model.safetensors')

def mod6_circuit(bits):
    inputs = torch.tensor([float(b) for b in bits])
    weighted_sum = (inputs * weights['weight']).sum() + weights['bias']
    return weighted_sum.item()

Verification

Proven axiom-free via Coq using algebraic correctness of the weight pattern.

Full proof: coq-circuits/Modular/Mod6.v

Files

tiny-mod6-verified/
β”œβ”€β”€ model.safetensors
β”œβ”€β”€ model.py
β”œβ”€β”€ config.json
└── README.md

License

MIT

Downloads last month
-
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Collection including phanerozoic/tiny-mod6-verified