Add intelligent station name processor

This is intended to replace the simple regex truncation (`city.match(/[^,/;\\-]*/)[0].substr(0, 12)`)
with a file that has all the station name processing already pre-processed by the logic in the stations
post-processor script. It uses priority-based conflict resolution to avoid duplicate station names by
using airport classification hierarchy. It handles complex naming patterns including military facilities,
county airports, hyphenated cities, slash/comma separators, and "at/near" qualifiers with a minium number
of exceptions.

This changes station data pipeline to generate stations-raw.json first, then process through the
post-processor to create the final stations.json compatible with existing codebase.
This commit is contained in:
Eddy G
2025-07-15 08:15:28 -04:00
parent c3d863f89f
commit eb412a0cae
4 changed files with 19682 additions and 16129 deletions

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -54,7 +54,7 @@ for (let i = 0; i < chunkStates.length; i += 1) {
next = stations?.pagination?.next;
round += 1;
// write the output
writeFileSync('./datagenerators/output/stations.json', JSON.stringify(output, null, 2));
writeFileSync('./datagenerators/output/stations-raw.json', JSON.stringify(output, null, 2));
}
while (next && stations.features.length > 0);
console.log(`Complete: ${state}`);