babylon.models.entities.territory

Territory entity model.

A Territory is the Phase 3.5 node type - the spatial substrate of the simulation. It represents a strategic sector in the world system, defined by: 1. Its sector type (industrial, residential, commercial, etc.) 2. Its ownership stack (host/parasite relationship) 3. Its operational profile (visibility stance) 4. Its heat level (state attention) 5. Its territory type (settler-colonial hierarchy classification)

Sprint 3.5.2: Layer 0 - The Territorial Substrate. Sprint 3.7: The Carceral Geography - Necropolitical Triad.

Classes

Territory(**data)

A strategic sector in the world system.

class babylon.models.entities.territory.Territory(**data)[source]

Bases: BaseModel

A strategic sector in the world system.

Territories are the spatial nodes of the simulation. Unlike SocialClass nodes which represent abstract class positions, Territory nodes represent physical locations that can be occupied, contested, and liberated.

The “Host/Parasite Stack” defines territorial control: - Host (Legal Sovereign): Recognized by State, collects rent/taxes - Occupant (De Facto User): Actually uses the space, may be revolutionary

The “Operational Profile” trades visibility for recruitment: - LOW_PROFILE: Safe from eviction, low recruitment - HIGH_PROFILE: High recruitment, high heat (state attention)

Parameters:
  • id (str)

  • county_fips (str | None)

  • h3_index (str | None)

  • name (str)

  • sector_type (SectorType)

  • territory_type (TerritoryType)

  • host_id (str | None)

  • occupant_id (str | None)

  • profile (OperationalProfile)

  • heat (Annotated[float, FieldInfo(annotation=NoneType, required=True, description='Contradiction intensity from dormant (0) to rupture (1)', metadata=[Ge(ge=0.0), Le(le=1.0)]), AfterValidator(func=~babylon.kernel.math.quantize)])

  • rent_level (Annotated[float, FieldInfo(annotation=NoneType, required=True, description='Non-negative economic value (wealth, wages, rent, GDP)', metadata=[Ge(ge=0.0)]), AfterValidator(func=~babylon.kernel.math.quantize)])

  • population (int)

  • under_eviction (bool)

  • biocapacity (Annotated[float, FieldInfo(annotation=NoneType, required=True, description='Non-negative economic value (wealth, wages, rent, GDP)', metadata=[Ge(ge=0.0)]), AfterValidator(func=~babylon.kernel.math.quantize)])

  • max_biocapacity (Annotated[float, FieldInfo(annotation=NoneType, required=True, description='Non-negative economic value (wealth, wages, rent, GDP)', metadata=[Ge(ge=0.0)]), AfterValidator(func=~babylon.kernel.math.quantize)])

  • regeneration_rate (float)

  • extraction_intensity (float)

  • median_wage (Annotated[float, FieldInfo(annotation=NoneType, required=True, description='Non-negative economic value (wealth, wages, rent, GDP)', metadata=[Ge(ge=0.0)]), AfterValidator(func=~babylon.kernel.math.quantize)])

  • reserve_ratio (float)

  • wealth (Annotated[float, FieldInfo(annotation=NoneType, required=True, description='Non-negative economic value (wealth, wages, rent, GDP)', metadata=[Ge(ge=0.0)]), AfterValidator(func=~babylon.kernel.math.quantize)])

  • foreclosure_rate (float)

  • eviction_rate (float)

  • displacement_rate (float)

  • concentrated_ownership (float)

  • absentee_landlord_share (float)

id

Unique identifier matching pattern ^T[0-9]{3}$

county_fips

Real 5-digit county FIPS when this territory maps to a US county (None for abstract territories); the county identity the TickDynamics economy reads, decoupled from the graph-local node id

name

Human-readable sector name

sector_type

Economic/social character of the territory

territory_type

Classification in settler-colonial hierarchy (Sprint 3.7)

host_id

Optional ID of the Legal Sovereign (collects rent)

occupant_id

Optional ID of the De Facto Occupant (uses space)

profile

Operational profile (visibility stance)

heat

State attention level [0, 1]

rent_level

Economic pressure on occupants [0, inf)

population

Human shield count (sympathizers)

under_eviction

Whether eviction pipeline is active

median_wage

Median wage paid in this territory (Feature 021)

reserve_ratio

Reserve-army fraction of the labor force [0, 1]

wealth

Aggregate territory wealth (dispossession transfer source)

foreclosure_rate

Foreclosure rate [0, 1] (Feature 021)

eviction_rate

Eviction rate [0, 1] (Feature 021)

displacement_rate

Displacement rate [0, 1] (Feature 021)

concentrated_ownership

Ownership concentration index [0, 1]

absentee_landlord_share

Absentee landlord share of rentals [0, 1]

model_config: ClassVar[ConfigDict] = {'extra': 'forbid', 'frozen': True, 'str_strip_whitespace': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

id: str
county_fips: str | None
h3_index: str | None
name: str
sector_type: SectorType
territory_type: TerritoryType
host_id: str | None
occupant_id: str | None
profile: OperationalProfile
heat: Annotated[float, FieldInfo(annotation=NoneType, required=True, description='Contradiction intensity from dormant (0) to rupture (1)', metadata=[Ge(ge=0.0), Le(le=1.0)]), AfterValidator(func=quantize)]
rent_level: Annotated[float, FieldInfo(annotation=NoneType, required=True, description='Non-negative economic value (wealth, wages, rent, GDP)', metadata=[Ge(ge=0.0)]), AfterValidator(func=quantize)]
population: int
under_eviction: bool
biocapacity: Annotated[float, FieldInfo(annotation=NoneType, required=True, description='Non-negative economic value (wealth, wages, rent, GDP)', metadata=[Ge(ge=0.0)]), AfterValidator(func=quantize)]
max_biocapacity: Annotated[float, FieldInfo(annotation=NoneType, required=True, description='Non-negative economic value (wealth, wages, rent, GDP)', metadata=[Ge(ge=0.0)]), AfterValidator(func=quantize)]
regeneration_rate: float
extraction_intensity: float
median_wage: Annotated[float, FieldInfo(annotation=NoneType, required=True, description='Non-negative economic value (wealth, wages, rent, GDP)', metadata=[Ge(ge=0.0)]), AfterValidator(func=quantize)]
reserve_ratio: float
wealth: Annotated[float, FieldInfo(annotation=NoneType, required=True, description='Non-negative economic value (wealth, wages, rent, GDP)', metadata=[Ge(ge=0.0)]), AfterValidator(func=quantize)]
foreclosure_rate: float
eviction_rate: float
displacement_rate: float
concentrated_ownership: float
absentee_landlord_share: float
property clarity_bonus: float

Recruitment bonus from profile visibility.

HIGH_PROFILE attracts cadre through ideological clarity. LOW_PROFILE is safe but boring.

Returns:

0.3 if HIGH_PROFILE, 0.0 if LOW_PROFILE

property is_liberated: bool

Whether territory is a Liberated Zone.

A territory is liberated when there is an occupant but no host (legal sovereign). This represents successful transition from parasitic to sovereign tenure.

Returns:

True if occupant exists and host does not

property is_sink_node: bool

Whether territory is a sink node in the displacement graph.

Sprint 3.7: The Carceral Geography - Necropolitical Triad.

Sink nodes are territories where displaced populations are routed. They have no economic value - only containment/elimination function. Population flows INTO these territories but does not flow OUT easily.

The three sink node types form the Necropolitical Triad: - RESERVATION: Containment (warehousing surplus population) - PENAL_COLONY: Extraction (forced labor, suppresses organization) - CONCENTRATION_CAMP: Elimination (population decay, generates terror)

Returns:

True if territory_type is RESERVATION, PENAL_COLONY, or CONCENTRATION_CAMP