Architecture
8 min read

How Versioned Provider-Ranking Policies Work

Ranking policies control how Orita scores eligible providers. Learn about weights, tie-breaking, policy versioning, simulation, activation, and rollback.

July 31, 2026
·By Orita Team

Hard constraints determine which providers qualify. Ranking policies determine the order in which they are presented.

The distinction matters: a ranking policy must never exclude providers. It can only score them.

Weights

A policy assigns a point value to each preference signal:

{
  "weights": {
    "preferredLanguage":  20,
    "preferredDayPart":   15,
    "earliestAvailable":  30,
    "providerContinuity": 20,
    "workloadBalance":    10,
    "preferredLocation":   5
  },
  "tieBreakers": ["earliest_start", "provider_id"]
}

A provider that speaks the preferred language gets +20 points. A provider in the preferred day-part gets +15 points. These signals are cumulative.

Tie-breaking

Tie-breaking is deterministic. When two options have the same score:

  1. Earliest start time wins
  2. If still tied, lowest current workload wins
  3. If still tied, provider ID (alphabetical) wins

This guarantees that the same resolution request always returns options in the same order for the same policy version.

Policy versioning

Every time a policy is activated, an immutable version snapshot is created. Every resolution records:

This makes every past resolution auditable and reproducible.

Activating a new policy version does not change past resolutions. Historical data remains tied to the policy version that was active at the time.

Simulate before activating

Before activating a policy, simulate it against candidate data:

POST /api/v2/ranking-policies/{policyId}/simulate

The response shows how each candidate would be ranked under the new policy — without committing anything.

Rollback

Roll back by activating a previous policy version. Since versions are immutable, the previous behavior is exactly reproducible.

Per-organization policies

Each organization in a multi-tenant platform can have its own ranking policy. A behavioral health organization might weight continuity heavily; a same-day urgent-care platform might weight earliest-available more.

Related

Provider resolution infrastructure

Ready to build provider resolution into your application?

Import your provider network, apply eligibility rules, return explained options, and safely confirm the booking.

Get API Access

No credit card required · Free tier included