Overview
AUTO-TOW-019, Select Nearest Qualified Operator, compares candidate towing operators using proximity, certification match, current job load, safety history, and customer rating.
- Decision ID
AUTO-TOW-019- Decision Name
- Select Nearest Qualified Operator
- Decision Preparation Model
auto-towing-select-nearest-qualified-opera-auto-tow-019version1.0.0- Default Profile
balanced- Runnable Scenario
standard- Catalog
DKR-AUTO-RUNTIME-001, version13.9.3- API Compatibility
7.4.0or later Prepared Criteria Mode execution flow
Understanding This Decision
Select Nearest Qualified Operator helps a towing operation compare available candidate operators before dispatching one to an incident. The decision is useful when dispatch teams need a repeatable recommendation that balances proximity, qualification fit, operator workload, safety history, and recent customer service performance.
Business question
Which operator should be recommended for select nearest qualified operator in the selected Auto Towing context?
Expected outcome
A recommended operator or ranked set of operators with the criteria that most influenced the result.
Typical users
Dispatch managers, towing coordinators, fleet supervisors, service-center staff, and integration teams building towing dispatch workflows.
Decision boundary
Use this decision to rank supplied candidate operators. It does not discover missing operators and does not replace safety, legal, police, roadside, or customer-service procedures.
Criteria
Criterion IDs are intentionally stable machine identifiers. Display labels are for users; request values should be keyed by canonical criterionId.
| Criterion ID | Name | Direction | Weight | Validation |
|---|---|---|---|---|
proximity_score | Proximity Score | maximize | 25 | score_0_to_100 |
certification_match_score | Certification Match Score | maximize | 25 | score_0_to_100 |
current_job_load | Current Job Load | minimize | 20 | non_negative_number |
safety_history_score | Safety History Score | maximize | 15 | score_0_to_100 |
customer_rating_score | Customer Rating Score | maximize | 15 | score_0_to_100 |
Data Preparation Guide
Constraint Processing
This decision currently has no catalog-defined hard constraints. All validated candidates proceed to criteria-based ranking.
| Verified Catalog Constraint | Status | Effect |
|---|---|---|
None returned by Decision Catalog for AUTO-TOW-019 | No hard constraints defined | Candidate eligibility is determined by request validation; all validated candidates are ranked by criteria. |
{
"constraintSummary": {
"definedConstraintCount": 0,
"activeConstraintCount": 0,
"eligibleOptionCount": 3,
"excludedOptionCount": 0,
"eligibleOptions": [
"OPTION-001",
"OPTION-002",
"OPTION-003"
],
"excludedOptions": []
}
}
const constraints = decisionDetail.constraints || [];
if (constraints.length === 0) {
// No catalog-defined hard constraints.
// Submit all validated candidates for criteria-based ranking.
}
const summary = response.constraintSummary;
const excluded = response.decisionResult?.excludedOptions || [];
Excluded candidates do not participate in ranking because hard constraints are evaluated before scoring. For AUTO-TOW-019, no candidates are excluded by catalog-defined constraints because Decision Catalog currently defines none for this decision.
Decision Preparation Model
The published Decision Preparation Model validates and transforms illustrative Business Data into the canonical criteria required by AUTO-TOW-019 before Decision Service applies ranking.
- Profile ID
auto-towing-select-nearest-qualified-opera-auto-tow-019- Version
1.0.0- Options Path
$.towRequests- Option ID Path
$.optionId- Display Name Path
$.name
| Client Business Data Path | Transformation | Canonical Criterion ID | Unit | Validation |
|---|---|---|---|---|
option.assessment.proximityScore | direct value | proximity_score | Score | Input Contract |
option.assessment.certificationMatchScore | direct value | certification_match_score | Score | Input Contract |
option.resource.allocation.currentJobLoad | direct value | current_job_load | Job | Input Contract |
option.assessment.safetyHistoryScore | direct value | safety_history_score | Score | Input Contract |
option.assessment.customerRatingScore | direct value | customer_rating_score | Score | Input Contract |
{
"requestContext": {
"sourceSystem": "automotive-profile-factory",
"correlationId": "factory-auto-tow-019"
},
"towRequests": [
{
"optionId": "TOW-019-01",
"name": "Select Nearest Qualified Operator Option 1",
"assessment": {
"proximityScore": 44.0,
"certificationMatchScore": 43.0,
"safetyHistoryScore": 17.0,
"customerRatingScore": 17.0
},
"resource": {
"allocation": {
"currentJobLoad": 27.0
}
}
},
{
"optionId": "TOW-019-02",
"name": "Select Nearest Qualified Operator Option 2",
"assessment": {
"proximityScore": 48.0,
"certificationMatchScore": 59.0,
"safetyHistoryScore": 62.0,
"customerRatingScore": 25.0
},
"resource": {
"allocation": {
"currentJobLoad": 23.0
}
}
}
]
}
{
"optionId": "TOW-019-01",
"name": "Select Nearest Qualified Operator Option 1",
"values": {
"proximity_score": 44.0,
"certification_match_score": 43.0,
"current_job_load": 27.0,
"safety_history_score": 17.0,
"customer_rating_score": 17.0
}
}
Profiles and Scenarios
This example selects a Profile for evaluation emphasis and a Scenario for operating context. Discover both from the selected Decision Catalog definition.
| Profile ID | Name | Purpose |
|---|---|---|
balanced | Balanced | General-purpose profile that preserves the default Decision Catalog criterion weights. |
speed_focused | Speed Focused | Places stronger emphasis on response time, proximity, and operational availability. |
safety_focused | Safety Focused | Places stronger emphasis on safety, traffic risk, hazardous conditions, and compliance exposure. |
cost_control | Cost Control | Places stronger emphasis on controlling dispatch, resource, and recovery costs. |
| Scenario ID | Name | Use When |
|---|---|---|
standard | Standard Dispatch Scenario | Normal towing operations with routine dispatch constraints. |
emergency_response | Emergency Response Scenario | Use when public safety, traffic exposure, or police/fire involvement increases urgency. |
limited_capacity | Limited Capacity Scenario | Use when tow units, operators, or equipment are constrained. |
severe_weather | Severe Weather Scenario | Use when weather, road conditions, or visibility materially affect towing operations. |
standard in runnable examples because it is present in the active Decision Catalog scenario list for AUTO-TOW-019.Prepared Input
For Prepared Criteria Mode, send decisionId, selected profile/scenario IDs, and option values keyed by canonical criterion ID.
{
"decisionId": "AUTO-TOW-019",
"profileId": "balanced",
"scenarioId": "standard",
"algorithm": "TOPSIS",
"weightStrategy": "Expert",
"runSensitivity": false,
"requestContext": {
"correlationId": "auto-tow-019-demo-001"
},
"options": [
{
"optionId": "OPTION-001",
"name": "Operator North Zone",
"values": {
"proximity_score": 88,
"certification_match_score": 88,
"current_job_load": 1,
"safety_history_score": 88,
"customer_rating_score": 88
}
},
{
"optionId": "OPTION-002",
"name": "Operator Central Zone",
"values": {
"proximity_score": 80,
"certification_match_score": 80,
"current_job_load": 3,
"safety_history_score": 80,
"customer_rating_score": 80
}
},
{
"optionId": "OPTION-003",
"name": "Operator East Zone",
"values": {
"proximity_score": 72,
"certification_match_score": 72,
"current_job_load": 5,
"safety_history_score": 72,
"customer_rating_score": 72
}
}
]
}
Execute
curl -X POST "https://dde.vinquery.com/api/v1/decide" \
-H "Authorization: Bearer ${DECISIOQ_TOKEN}" \
-H "Content-Type: application/json" \
-H "X-Correlation-Id: auto-tow-019-demo-001" \
--data @auto-tow-019-execute.json
The Decision Service validates the request, retrieves authoritative criteria, constraints, profiles, scenarios, and validation metadata from Decision Catalog, applies hard constraints, ranks eligible options, and returns the decision result plus execution metadata.
Interpret the Result
The successful response includes both the deterministic decisionResult and a top-level explanation object. The explanation adds context but does not select, rerank, recalculate, or override the ranking.
{
"service": "decisioq",
"version": "7.6.3",
"requestId": "0HNE...",
"operation": "Decide",
"success": true,
"decisionType": "AUTO-TOW-019",
"decisionVersion": "13.9.3",
"timestampUtc": "2026-07-18T00:00:00Z",
"decisionResult": {
"winner": "OPTION-001",
"confidence": 72.4,
"ranking": [
{
"optionId": "OPTION-001",
"score": 0.8421,
"breakdown": {
"proximity_score": 0.25,
"certification_match_score": 0.25,
"current_job_load": 0.20,
"safety_history_score": 0.15,
"customer_rating_score": 0.15
},
"normalizationBreakdown": {}
}
],
"excludedOptions": []
},
"explanation": {
"summary": "The selected towing operator provided the strongest overall dispatch fit.",
"whyRecommended": "It combined strong proximity and certification match with low current job load, strong safety history, and strong customer rating.",
"keyDrivers": [],
"tradeoffs": [],
"competitors": [],
"sensitivitySummary": "Sensitivity analysis was not included in this response.",
"scenarioSummary": "The standard dispatch scenario was selected.",
"risks": [],
"nextSteps": [],
"assumptions": []
},
"constraintSummary": {
"definedConstraintCount": 0,
"activeConstraintCount": 0,
"eligibleOptionCount": 3,
"excludedOptionCount": 0,
"eligibleOptions": [
"OPTION-001",
"OPTION-002",
"OPTION-003"
],
"excludedOptions": []
},
"warnings": [],
"requestContext": {
"correlationId": "auto-tow-019-demo-001"
}
}
decisionResult.winner.Sensitivity Analysis
runSensitivity is an optional execution flag supported by both Business Data Mode and Prepared Criteria Mode. Set it to true when the client wants recommendation-stability information in the same response. The sensitivity engine analyzes the prepared criteria produced by either input path, perturbs criterion weights by controlled factors, and reports whether the winner remains stable.
{
"sensitivityResult": {
"stableWinner": true,
"winner": "OPTION-001",
"mostSensitiveCriterion": "proximity_score",
"confidence": 95,
"criterionImpacts": {
"proximity_score": 0.1842
},
"winnerChangeCounts": {
"proximity_score": 0
}
}
}
Use sensitivity output to decide whether a recommendation is robust enough for automation or should be reviewed by a person.
Explanation of Decision Result
Every successful response includes a provider-neutral top-level explanation object. It explains the already-finalized deterministic result and does not change the ranking.
{
"explanation": {
"summary": "The selected towing operator provided the strongest overall dispatch fit.",
"whyRecommended": "It combined strong proximity and certification match with low current job load, strong safety history, and strong customer rating.",
"keyDrivers": [],
"tradeoffs": [],
"competitors": [],
"sensitivitySummary": "Sensitivity analysis was not included in this response.",
"scenarioSummary": "The standard dispatch scenario was selected.",
"risks": [],
"nextSteps": [],
"assumptions": []
}
}
Tracing and Logs
Use request identifiers to connect client, catalog, and execution activity during support or integration testing.
X-Request-Id- Optional client-supplied request ID. If omitted, the server generates one.
X-Correlation-Id- Optional client correlation value propagated from Decision Service to Decision Catalog.
requestContext.correlationId- Optional payload value echoed in the response and used for tracing.
configurationUsed- The authoritative effective weight strategy, ranking algorithm, profile, scenario, sensitivity setting, and source for each value.
diagnostics- Safe execution counts returned only when
responseOptions.includeDiagnosticsis true.
Code Examples
These examples demonstrate the current DecisioQ flow:
- Request
jwtTokenfromhttps://identity.vinquery.com/connect/token. - Load
AUTO-TOW-019metadata fromhttps://dks.vinquery.com/decisioncatalog/decisions/AUTO-TOW-019. - Execute a Prepared Criteria Mode at
https://dde.vinquery.com/api/v1/decide.
Set these environment variables before running any companion example:
DECISIOQ_CLIENT_ID
DECISIOQ_CLIENT_SECRET
Optional:
DECISIOQ_IDENTITY_URL=https://identity.vinquery.com/connect/token
DECISIOQ_DKS_URL=https://dks.vinquery.com
DECISIOQ_DDE_URL=https://dde.vinquery.com
Download the source files directly:
Troubleshooting
| Symptom | Likely Cause | What to Check |
|---|---|---|
| 401 Unauthorized | Missing, expired, or invalid bearer token. | Request a fresh jwtToken from Identity and send it as Authorization: Bearer .... |
| Decision not found | The decision ID is not in the active catalog. | Load /decisioncatalog/decisions/AUTO-TOW-019 and confirm the ID is published. |
| Validation failed | A required criterion value is missing or outside its rule. | Use canonical criterion IDs and keep score values in the expected range. |
| HTML error response | An upstream hosted service failed before returning JSON. | Check service health and server logs for Identity, Decision Catalog, or Decision Service. |
Production Checklist
Security
Keep API Consumer credentials and jwtTokens on the server side. Use HTTPS, short-lived bearer tokens, and an API Consumer linked to a DecisioQ account for usage accounting.
Catalog
Load decision metadata from Decision Catalog and cache cautiously. Refresh when catalog versions change.
Request Quality
Use canonical criterion IDs, validate value ranges, and send at least two candidate options.
Operations
Send correlation IDs, record request IDs, and monitor non-JSON upstream failures.
Explanation
Display explanation text as supporting context only. Never let generated explanation text override deterministic results.
User Experience
Show business labels to users and keep raw execution trace collapsed for advanced diagnostics.
