Skip to content

Disambiguate NAVY callsign matching by origin country preference#33

Closed
koala73 wants to merge 1 commit into
mainfrom
codex/update-military-config-to-resolve-navy-overlap
Closed

Disambiguate NAVY callsign matching by origin country preference#33
koala73 wants to merge 1 commit into
mainfrom
codex/update-military-config-to-resolve-navy-overlap

Conversation

@koala73

@koala73 koala73 commented Jan 27, 2026

Copy link
Copy Markdown
Owner

Motivation

  • Resolve ambiguous ^NAVY callsign overlap between US and UK operators by preferring operator matches when the flight origin_country is known.
  • Keep existing callsign patterns intact to avoid breaking current matching while improving accuracy for common ambiguity cases.

Description

  • Extend identifyByCallsign to accept an optional originCountry parameter and prefer operator-specific patterns when the origin is provided (currently prefers rn/raf for UK and usn/usaf/usa/usmc for USA).
  • Thread originCountry through the classification flow by updating determineAircraftInfo to accept originCountry and by passing originCountry from isMilitaryFlight and parseOpenSkyResponse.
  • Leave the global ALL_MILITARY_CALLSIGNS list unchanged so non-country matches still work as a fallback.
  • Modified files: src/config/military.ts and src/services/military-flights.ts.

Testing

  • No automated tests were run as part of this change.
  • Behavior verified by updating call sites to pass originCountry so the new preference logic is exercised at runtime (no test suite executed).

Codex Task

@vercel

vercel Bot commented Jan 27, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
worldmonitor Ready Ready Preview, Comment Jan 27, 2026 5:20am
worldmonitor-startup Ready Ready Preview, Comment Jan 27, 2026 5:20am
worldmonitor-test Ready Ready Preview, Comment Jan 27, 2026 5:20am

Request Review

@koala73 koala73 closed this in 283d05a Jan 27, 2026
@koala73
koala73 deleted the codex/update-military-config-to-resolve-navy-overlap branch February 15, 2026 08:04
@SebastienMelki SebastienMelki added the area: military Military flights, vessel tracking label Feb 17, 2026
facusturla pushed a commit to facusturla/worldmonitor that referenced this pull request Feb 27, 2026
…with fixes

- PR koala73#33: Disambiguate NAVY callsign by origin country (US vs UK)
- PR koala73#34: Use typecode fallback in determineAircraftInfo + Wingbits
  enrichment (guarded: only when type is still 'unknown')
- PR koala73#35: Persist typeCode in enriched data (skip the broken
  pre-filter removal and false-positive regex from original PR)

Closes koala73#33, koala73#34, koala73#35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: military Military flights, vessel tracking codex

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants