AI model deployment: Import, signal mapping, and review
I built the model import and deployment interfaces for Sonatus AI On Demand. The import workflow let users upload a package, configure it for the vehicle and runtime, and map model inputs to vehicle signals. Users could then review deployment jobs in the interface.
- Problem
- Several vehicle signals could plausibly match the name of a model input. Later, even when an engineer selected the right model, the deployment request could fail because it confused the model record with its checkpoint file.
- Decision
- I wrote the matcher to try exact names before broader matches and skip signals already assigned. Engineers could edit each suggestion. For deployment, I carried the selected checkpoint’s identifier alongside the model identifier through review.
- Result
- An engineer could correct one signal assignment and keep the rest. The corrected job request referenced the selected file, resolving the missing-checkpoint error.
- Context
- Sonatus - AI on Demand
- Period
- 2024–2025
- My focus & role
- Frontend implementation, API integration, model-input matching, deployment workflows, and automated tests.
- Technology
- React · TypeScript · GraphQL · REST
Model inputs and vehicle signals
Concept interface - synthetic data001_vehicle_speedNo mapping selectedcoolant_temperatureNo mapping selectedenginerpmxNo mapping selected002_vehicle_speedNo mapping selected0 of 4 inputs suggested. Start with exact names, then widen the search.
A model package needs an operational configuration
Importing a model involved more than selecting a file. The interface needed to describe its inputs and outputs, target vehicle configuration, execution environment, and performance limits. A user then had to connect model inputs to vehicle signals and review the configuration before saving it.
I built the model list and details page around the saved configuration. An engineer could reopen a model from the list, inspect its package and signal mappings, then use that record to prepare a job for a chosen target.
Keep a long configuration flow coherent
I structured import into four steps: upload the package and validation data, configure the model and target, map input parameters, then review and save. A shared state representation carried the algorithm, vehicle configuration, runtime environment, limits, and input/output parameters from one step to the next.
This mattered because each screen was editing part of one configuration. The review screen needed the same values that the setup and mapping screens had collected, and the save operation needed to translate that configuration into the backend contract. Keeping the state together made those relationships explicit instead of treating each form as an independent submission.
I integrated parsed package configuration and a YAML viewer, and replaced placeholder target choices with the existing ECU inventory. That gave engineers the package’s declared inputs and the available target hardware in the same workflow.
Model import wizard
Adapted implementation screenshot
Handle file transfer outside the GraphQL client
The model list, parsed configuration, and save operation used GraphQL. The package upload used a multipart REST request with upload-progress reporting. That request bypassed the GraphQL client, so it could not rely on the same authentication behavior automatically applying to both paths.
Separate file transfer from model configuration
Package, validation data, target configuration, limits, input mapping
File transfer, progress, authentication refresh and bounded retry
Parsed configuration, model metadata, review and save
Selected model and checkpoint, target selection, review
I added explicit handling for an unauthorized upload response: refresh authentication and retry within a bounded policy. The implementation allowed up to two retries rather than looping indefinitely. A failed file transfer and a rejected configuration save remained different failures, even though the user encountered them within one wizard.
Keeping upload concerns in a dedicated hook separated progress and retry state from the form screens. The trade-off was an additional transport boundary to maintain. Its authentication, errors, and completion state needed deliberate integration with the rest of the application.
Suggest mappings without hiding ambiguity
Model input names and vehicle signal names did not necessarily match directly. Manually selecting every signal was repetitive, but a plausible name match was still only a candidate. I implemented automatic suggestions alongside the editable mapping interface.
The matcher first normalized numeric prefixes and suffixes and tried exact names. It then used word-boundary fuzzy matching, ranking candidates by match count, position, and length. A final fallback progressively shortened a prefix while respecting a minimum length. The ordering favored a specific match before trying broader ones.
A used-signal set prevented the batch mapper from assigning the same signal repeatedly while filling unmapped inputs. The example at the top exposes that constraint: a repeated speed input stays unresolved after its candidate has already been assigned. It also distinguishes exact matching from broader suggestions.
An engineer still needed to check the units and sampling behavior of a candidate signal. They could remove a single assignment and replace it while keeping the mappings they had already reviewed.
Mapping a model input to a vehicle signal
Adapted implementation screenshot
Keep model identity separate from artifact identity
I extended the deployment-job flow around model information, target selection, and review. Choosing a model in the interface still left the request builder with two references to carry forward.
Why did a selected model produce a missing-file error?
Reconstructed request · synthetic identifiersThe model record is model-A. Its selected checkpoint, the file the job needs, is checkpoint-B.
The request mixed up the model and checkpoint references. The backend reported a missing checkpoint file even though a model was selected.
Keep model-A for the model record and pass checkpoint-B for the selected file when preparing the job request.
I also corrected a mismatch between a human-readable vehicle category and the value the API expected for that target.
As the configuration grew, I replaced the small model-details drawer with a dedicated page. This gave package information, target configuration, limits, and mappings enough space to be inspected together before a deployment action. The original model-details capture shows that review surface.
Project artifacts
The package upload and input mapping screens show the configuration being assembled. The later details page brought those choices together for review before starting a deployment.
Model details and deployment review
Adapted implementation screenshot
Testing the import and deployment workflows
I added tests for the wizard, upload handling, signal matcher and deployment interface. For the matcher I used a fixture of vehicle signal names, where a short input name could have several plausible matches. That let me exercise the matching rules separately from the screens where engineers reviewed their suggestions.
Related case: Collector’s signal transformation layer covers how vehicle data is prepared for visualization after collection.