Replace the LLM-per-request flow in /pm with a stateful Python backend
(OpenSquawk-LiveATC-api). The backend owns session state, does regex-first
routing with readback evaluation, and returns the next state + ATC speech.
The frontend keeps its local cursor (communicationsEngine) for TTS and
monitoring UI, but no longer calls /api/llm/decide.
Changes:
app/composables/useRadioBackend.ts (new)
Typed Nuxt composable wrapping the Python REST API:
createSession, transmit, deleteSession, fetchFlows.
Base URL read from NUXT_PUBLIC_RADIO_BACKEND_URL (default 127.0.0.1:8000).
nuxt.config.ts
Expose radioBackendUrl as a public runtime config key so the composable
and communicationsEngine can both reach the Python backend.
shared/utils/communicationsEngine.ts
- fetchRuntimeTree now accepts an optional baseUrl so it fetches from the
Python backend instead of the Nuxt server when a URL is provided.
- renderTpl handles both {var} (old MongoDB schema) and {{var}} (new YAML
schema) — double-brace matched first to avoid partial matches.
- stateSayTpl / stateUtteranceTpl helpers unify say_tpl|say_template and
utterance_tpl|expected_pilot_template across both schema versions.
- auto_transitions from the new YAML schema are included when collecting
eligible transitions in collectAtcStatesUntilPilotTurn.
shared/types/decision.ts
RuntimeDecisionState extended with say_template and expected_pilot_template
fields (new YAML schema field names alongside the existing legacy names).
app/pages/pm.vue
- startMonitoring: loads tree from Python backend, then creates a backend
session (backendSessionId). Cursor synced to session.current_state.
- handlePilotTransmission: calls radioBackend.transmit instead of
/api/llm/decide. Applies auto_advanced_states via moveToSilent, then
the final state. Speaks controller_say_template via TTS.
- Both fetchRuntimeTree calls now pass radioBackendUrl so they hit the
Python backend, not the Nuxt flow-from-MongoDB path.
AGENTS.md (new)
Project guide updated to document the new two-backend architecture,
the Python backend session lifecycle, and the dual template schema.
docs/plans/2026-05-06-pm-python-runtime-contract.md (new)
Implementation plan and API contract written before the work started.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* Updated and with new company details (Faktor Mensch MEDIA UG), updated email to , and refreshed dates.
* Replaced references to old OpenSquawk UG with new entity information.
* Added module to for image optimization support.
* Adjusted dependencies: added , ensured is correctly listed.
* Regenerated to include new dependencies (, High performance, secure and easy-to-use image optimizer. (ipx v2.1.1)
USAGE ipx serve
COMMANDS
serve Start IPX Server
Use ipx <command> --help for more information about a command., Usage: svgo [options] [INPUT...]
Nodejs-based tool for optimizing SVG vector graphics files
Arguments:
INPUT Alias to --input
Options:
-v, --version output the version number
-i, --input <INPUT...> Input files, "-" for STDIN
-s, --string <STRING> Input SVG data string
-f, --folder <FOLDER> Input folder, optimize and rewrite all *.svg files
-o, --output <OUTPUT...> Output file or folder (by default the same as the
input), "-" for STDOUT
-p, --precision <INTEGER> Set number of digits in the fractional part,
overrides plugins params
--config <CONFIG> Custom config file, only .js is supported
--datauri <FORMAT> Output as Data URI string (base64), URI encoded
(enc) or unencoded (unenc)
--multipass Pass over SVGs multiple times to ensure all
optimizations are applied
--pretty Make SVG pretty printed
--indent <INTEGER> Indent number when pretty printing SVGs
--eol <EOL> Line break to use when outputting SVG: lf, crlf.
If unspecified, uses platform default.
--final-newline Ensure SVG ends with a line break
-r, --recursive Use with '--folder'. Optimizes *.svg files in
folders recursively.
--exclude <PATTERN...> Use with '--folder'. Exclude files matching
regular expression pattern.
-q, --quiet Only output error messages, not regular status
messages
--show-plugins Show available plugins and exit
--no-color Output plain text without color
-h, --help display help for command, etc.).