# Kyrgyzstan maps: sources and method

Files: `oblasts.json` (9 units), `rayons.json` (56 units), `jk-2025.json` (30 units). Each is
TopoJSON with one object, `units`. Each feature `id` is the key the results use, and
`properties.name` is the name as the CEC writes it.

- Oblasts and the two cities of republican significance use the ESS `region_code`: BSH (Bishkek),
  OSH (Osh city), BT, JA, ISS, NR, OSHO, TL, CHU.
- Rayons and cities use the ESS `tec_code` of their territorial election commission (АШК/ТИК),
  for example "04" for Bishkek and "36" for Osh city.
- The 2025 Jogorku Kenesh districts are numbered "1" to "30".

Built by `scripts/kyrgyzstan/maps.ts`.

## Sources

1. **2025 districts: Central Commission for Elections and Referendums (CEC).**
   - Polygons: the CEC publishes them for its interactive district map,
     <https://shailoo.gov.kg/ru/map/district/>. The data file is
     <https://shailoo.gov.kg/static/js/okrug.regiteccoords.min.json>, with 30 features. It returned
     HTTP 200 on 9 November 2026.
   - Territory of each district: the CEC's text at
     <https://shailoo.gov.kg/ru/vybory-noyabr-2025/mnogomandatnye-izbiratelnye-okruga/>, one page per
     district (`izbiratelnyj-okrug-1/` to `-30/`, all HTTP 200).
   - Licence: the CEC states none. These are official electoral documents of the Kyrgyz Republic,
     reproduced with attribution.
2. **Oblasts, rayons and cities: OCHA COD-AB Kyrgyzstan.**
   - Source: Ministry of Emergency Situations of the Kyrgyz Republic.
   - Boundaries created on 21 November 2018 and reviewed on 31 January 2024.
   - Licence: CC BY-IGO (Creative Commons Attribution for Intergovernmental Organisations).
   - Dataset: <https://data.humdata.org/dataset/cod-ab-kgz>, GeoJSON resource
     `kgz_admin_boundaries.geojson.zip`.
   - Attribution: "Ministry of Emergency Situations of the Kyrgyz Republic, via OCHA / HDX (COD-AB),
     CC BY-IGO".
3. **Territorial commissions: the CEC's Information Electoral System (ESS).**
   - <https://ess.shailoo.gov.kg/api/ele/20251130-2> and <https://ess.shailoo.gov.kg/api/ele/20210110>,
     list `tecs`.
   - Saved in `src/data/kyrgyzstan/snapshot/tecs.json`.

## Method

1. **Base cells (COD-AB).**
   - Admin 3 (aiyl aimaks and towns) where it exists.
   - Admin 2 where admin 3 has no coverage, which is most cities of oblast significance.
   - Admin 1 for Bishkek and Osh, which COD-AB does not divide.
2. **Keys for each cell.**
   - Each cell gets the TEC of its rayon or city, from a table in the script.
   - Two exceptions are new commissions: Kant ("60"), out of Ysyk-Ata, and Kara-Balta ("61"), out of
     Jayil. Both are admin-3 towns in COD-AB.
   - Kok-Jangak, an admin-2 city in COD-AB, belongs to Suzak's commission ("06"), as the CEC's
     district 11 text says.
3. **Lakes.**
   - Issyk-Kul (about 6,255 km²) and Son-Kul (about 286 km²) belong to no rayon in COD-AB.
   - They are left blank on every layer, so all three layers share one outline.
4. **Mosaic.**
   - The cells and the CEC's 30 district polygons are cut into one planar mosaic (mapshaper
     `-mosaic`).
   - Every piece takes its rayon and oblast from COD-AB and its district from the CEC.
   - Pieces outside COD-AB's outline are dropped. Where the CEC polygons and COD-AB's outline
     differ, COD-AB's outline is kept.
5. **Gaps and snapping.**
   - A piece the CEC file leaves uncovered takes the district that covers most of the same cell.
     These are lake shores, the national border and slivers between the CEC's polygons.
   - If 97% or more of a cell lies in one district, the whole cell goes to that district. This
     snaps district lines to admin lines wherever the two describe the same boundary.
   - A district that holds less than 0.5% of a cell is treated as a sliver.
   - The 14 cities that the CEC's text puts wholly in one district go to that district whole:
     Sülüktü, Batken, Kyzyl-Kiya, Jalal-Abad (Manas), Mailuu-Suu, Tash-Kömür, Kara-Köl, Talas,
     Kara-Balta, Kant, Tokmok, Karakol, Balykchy and Naryn. COD-AB's 2018 city outlines and the
     CEC's polygons disagree at their edges. The script checks each city against the text.
6. **Simplification.**
   - The three layers are dissolved from the same pieces and simplified once, on shared arcs
     (Visvalingam, weighted, about 450 m), so their outlines match.
   - Coordinates are quantised to 0.002°.

## Approximations

- **District lines** are the CEC's own, redrawn at small scale. They split rayons, aiyl aimaks,
  Osh city and Bishkek wherever the CEC's text does. Examples: Bazar-Korgon town is divided by
  precinct, Kerme-Too aiyl aimak by village, and the outskirts of Bishkek go to districts 19, 20 and
  25. Near the national border and the lake shores, district edges follow COD-AB, not the CEC's
  file.
- **Admin boundaries are those of 2018.**
  - The 2024 territorial reform (merged aiyl aimaks, new cities) is not in COD-AB.
  - The rayon layer shows the 2018 extent of each commission's area. Since then, Osh city has
    taken in villages such as Kyzyl-Kyshtak and Tölöykön, which the CEC's 2025 scheme lists
    under Osh city. The scheme also lists villages under Bishkek's city rayons.
  - The district layer does not depend on these changes.
- **Not drawn.** Abroad (MID) and remote voting (RMT/ДУИК) have no territory, so they are not on
  any map.
- **The 36 single-member districts of 2021 are not drawn.**
  - The CEC publishes polygons for the 2025 districts only.
  - Drawing them would need the 2021 scheme's text, and Bishkek split into its four city rayons
    (2021 districts 26 to 29), which COD-AB does not provide.
  - No 2021 district results are in the snapshots yet.
- **Borders.** The national outline is COD-AB's. It is not an authority on international
  boundaries, including sections still being demarcated with Tajikistan and Uzbekistan. The
  Uzbek and Tajik enclaves (Sokh, Shakhimardan, Vorukh and others) are holes.
