feat(biology): evolve photosynthetic producers that capture light
Foundation / checks (ecs) (push) Successful in 2m25s
Foundation / checks (deploy) (push) Successful in 5m15s
Foundation / checks (network) (push) Successful in 21m56s
Foundation / checks (client) (push) Successful in 22m54s
Foundation / checks (tsan) (push) Successful in 47m4s
Foundation / checks (postgres) (push) Successful in 1h15m49s
Foundation / checks (checks) (push) Failing after 1h30m4s
Foundation / postgres-tools (push) Skipped
Foundation / server-image (push) Skipped
Foundation / image (push) Skipped
Foundation / checks (ecs) (push) Successful in 2m25s
Foundation / checks (deploy) (push) Successful in 5m15s
Foundation / checks (network) (push) Successful in 21m56s
Foundation / checks (client) (push) Successful in 22m54s
Foundation / checks (tsan) (push) Successful in 47m4s
Foundation / checks (postgres) (push) Successful in 1h15m49s
Foundation / checks (checks) (push) Failing after 1h30m4s
Foundation / postgres-tools (push) Skipped
Foundation / server-image (push) Skipped
Foundation / image (push) Skipped
ADR-0175 implements ADR-0136 step C with trial costs to be balanced after playtesting. Genome schema 5 adds a photosynthesis efficiency (empty in schemas 1-4, so earlier offers and draws are unchanged; mutation operators 29-32 are appended). Development version 5 builds the organelles as internal membrane (p/4 of structure, upkept twice) and slows movement by p/2 per thousand. Founder 4 and cellular rules 11 let lineages earn the capability as an offspring plan that children express. Owner format 9 declares the region's light. Inside each tick's detached candidate, active unfrozen producers capture cross-section x irradiance x efficiency (a quarter while moving), credited to the reserve and boundary inflow together and replayed from recorded intentions. Well-lit wildlife producers hold still. The joint owner keeps infall, water and radiation and nests a rules-11 owner unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
+14
-3
@@ -116,7 +116,8 @@ void capability_and_range_rules() {
|
||||
draft.capabilities.push_back({Capability::thermal_tolerance, 1, 1U << capability_count});
|
||||
reject(draft, GenomeError::unknown_capability);
|
||||
// Every boundary of every declared range, from both sides, in each schema's own table.
|
||||
for (const auto schema : {genome_schema_v1, genome_schema_v2, genome_schema_v3}) {
|
||||
for (const auto schema :
|
||||
{genome_schema_v1, genome_schema_v2, genome_schema_v3, genome_schema_v5}) {
|
||||
const auto& table = *capability_schema_for(schema);
|
||||
const auto fresh = [&] {
|
||||
auto d = founder();
|
||||
@@ -126,6 +127,16 @@ void capability_and_range_rules() {
|
||||
for (std::size_t index = 0; index < capability_count; ++index) {
|
||||
const auto kind = static_cast<Capability>(index);
|
||||
const auto& limits = table[index];
|
||||
// An empty range (photosynthesis before schema 5) admits no value at all.
|
||||
if (limits.maximum < limits.minimum) {
|
||||
CHECK(kind == Capability::photosynthesis && schema != genome_schema_v5);
|
||||
for (const auto value : {0U, 1U, 100U, 1000U}) {
|
||||
draft = fresh();
|
||||
draft.capabilities.push_back({kind, value, 0});
|
||||
reject(draft, GenomeError::parameter_out_of_range);
|
||||
}
|
||||
continue;
|
||||
}
|
||||
for (const auto value : {limits.minimum, limits.maximum}) {
|
||||
draft = fresh();
|
||||
std::erase_if(draft.capabilities,
|
||||
@@ -351,10 +362,10 @@ void schema_v2_rates() {
|
||||
v1.capabilities[4].parameter = 1'000'001;
|
||||
reject(v1, GenomeError::parameter_out_of_range);
|
||||
auto unknown = founder();
|
||||
unknown.schema_version = 5; // Schema 4 exists since rules 7 (ADR-0137).
|
||||
unknown.schema_version = 6; // Schema 5 exists since rules 11 (ADR-0175).
|
||||
reject(unknown, GenomeError::unsupported_version);
|
||||
auto bytes = Genome::create(founder())->encode();
|
||||
bytes[8] = 5; // Schema field; decode refuses before the checksum matters.
|
||||
bytes[8] = 6; // Schema field; decode refuses before the checksum matters.
|
||||
CHECK(!Genome::decode(bytes) &&
|
||||
Genome::decode(bytes).error() == GenomeError::unsupported_version);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user