> ## Documentation Index
> Fetch the complete documentation index at: https://docs.solvice.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Scheduling Framework

> Hierarchical planning levels from strategic budgeting to operational execution

The Solvice Scheduling Framework provides a comprehensive approach to workforce optimization across five interconnected planning levels. Each level feeds into the next, creating a seamless flow from high-level strategy to day-to-day operations.

<Frame caption="Solvice Framework: From strategic planning to operational execution">
  <img src="https://mintcdn.com/solvice-68592f22/1KJ_2AIotizI1Bng/images/scheduling-framework.svg?fit=max&auto=format&n=1KJ_2AIotizI1Bng&q=85&s=089b0628add632f42a6befde9e17797e" alt="Hierarchical planning levels from labour budgeting to task sequencing" width="698" height="530" data-path="images/scheduling-framework.svg" />
</Frame>

## Planning Hierarchy

<Steps>
  <Step title="Labour Budgeting" icon="calculator">
    **Level: Strategic** | **Horizon: Annual/Quarterly**

    Define overall workforce capacity and budget constraints. This foundational level determines:

    * Total headcount and FTE allocations
    * Budget constraints for labor costs
    * Skill mix requirements
    * Seasonal capacity adjustments
  </Step>

  <Step title="Demand Forecasting" icon="chart-line">
    **Level: Tactical** | **Horizon: Monthly/Weekly**

    Predict workload requirements based on historical patterns and business drivers:

    * Customer demand patterns
    * Service level targets
    * Peak period identification
    * Capacity planning inputs
  </Step>

  <Step title="Shift Creation" icon="calendar-plus">
    **Level: Tactical** | **Horizon: Weekly**

    Generate optimal shift structures to meet forecasted demand using the **Create API**:

    * Convert demand curves into concrete shifts
    * Balance coverage requirements with labor costs
    * Apply template patterns or flexible generation
    * Ensure minimum/maximum staffing levels

    <Card title="Create API" icon="calendar-plus" href="/guides/create/quickstart">
      Automatically generate shifts from demand forecasts
    </Card>
  </Step>

  <Step title="Shift Filling" icon="user-check">
    **Level: Operational** | **Horizon: Daily/Weekly**

    Assign employees to created shifts using the **Fill API**:

    * Match employee skills to shift requirements
    * Enforce labor regulations and rest periods
    * Respect employee preferences and availability
    * Balance workload fairly across the workforce

    <Card title="Fill API" icon="user-check" href="/guides/fill/quickstart">
      Optimize employee-to-shift assignments
    </Card>
  </Step>

  <Step title="Task Sequencing" icon="route">
    **Level: Operational** | **Horizon: Daily**

    Optimize task execution order using the **VRP API**:

    * Route field workers efficiently
    * Schedule appointments within time windows
    * Balance workloads across resources
    * Minimize travel time and costs

    <Card title="VRP API" icon="route" href="/guides/vrp/quickstart">
      Optimize routes and task sequences
    </Card>
  </Step>
</Steps>

## Framework Benefits

<CardGroup cols={2}>
  <Card title="End-to-End Optimization" icon="link">
    Each planning level optimizes within constraints set by higher levels, ensuring strategic alignment throughout operations.
  </Card>

  <Card title="Cascading Constraints" icon="arrow-down">
    Budget constraints flow to demand planning, demand drives shift creation, and shifts define the assignment problem.
  </Card>

  <Card title="Feedback Loops" icon="arrows-rotate">
    Operational outcomes inform tactical and strategic adjustments, creating continuous improvement cycles.
  </Card>

  <Card title="Unified Platform" icon="puzzle-piece">
    Consistent API design across all levels simplifies integration and enables holistic optimization.
  </Card>
</CardGroup>

## Solver Mapping

Each planning level maps to specific Solvice APIs:

| Planning Level      | Horizon      | Solvice API      | Primary Output       |
| :------------------ | :----------- | :--------------- | :------------------- |
| Labour Budgeting    | Annual       | External systems | Headcount, Budget    |
| Demand Forecasting  | Monthly      | External systems | Demand curves        |
| **Shift Creation**  | Weekly       | **Create API**   | Shift templates      |
| **Shift Filling**   | Daily/Weekly | **Fill API**     | Employee assignments |
| **Task Sequencing** | Daily        | **VRP API**      | Optimized routes     |

<Info>
  Labour budgeting and demand forecasting are typically handled by external HR and BI systems. Solvice APIs focus on the execution layers where optimization delivers the highest operational value.
</Info>

## Data Flow

```mermaid theme={null}
graph TD
    A[Labour Budget] --> B[Demand Forecast]
    B --> C[Shift Creation]
    C --> D[Shift Filling]
    D --> E[Task Sequencing]

    C -.-> |Feedback| B
    D -.-> |Feedback| C
    E -.-> |Feedback| D
```

### Integration Points

<AccordionGroup>
  <Accordion title="Demand to Shifts">
    The Create API accepts demand curves and generates shifts that provide optimal coverage:

    ```json theme={null}
    {
      "demands": [
        {
          "name": "morning-rush",
          "from": "2024-01-15T08:00:00",
          "to": "2024-01-15T12:00:00",
          "min": 5,
          "max": 8
        }
      ],
      "templates": [...],
      "options": { "mode": "FLEXIBLE" }
    }
    ```
  </Accordion>

  <Accordion title="Shifts to Assignments">
    The Fill API takes created shifts and assigns available employees:

    ```json theme={null}
    {
      "shifts": [
        {
          "name": "morning-kitchen",
          "from": "2024-01-15T08:00:00",
          "to": "2024-01-15T14:00:00",
          "skills": [{ "name": "kitchen" }]
        }
      ],
      "employees": [...],
      "rules": [...]
    }
    ```
  </Accordion>

  <Accordion title="Assignments to Routes">
    The VRP API optimizes daily task execution for assigned workers:

    ```json theme={null}
    {
      "vehicles": [
        {
          "id": "alice",
          "startLocation": { "lat": 51.05, "lng": 3.72 },
          "availability": { "from": "08:00", "to": "14:00" }
        }
      ],
      "jobs": [...],
      "objectives": [{ "type": "min-max", "value": "duration" }]
    }
    ```
  </Accordion>
</AccordionGroup>

## Industry Applications

<Tabs>
  <Tab title="Healthcare">
    **Home Health Care Scheduling**

    1. **Budget**: Annual nursing FTE allocations per region
    2. **Demand**: Patient visit requirements and acuity levels
    3. **Shifts**: Nurse shift schedules covering all regions
    4. **Fill**: Assign nurses based on skills and certifications
    5. **Route**: Optimize daily visit sequences with travel time

    <Check>
      Solvice delivers 15-25% reduction in travel time while ensuring skill-matched assignments.
    </Check>
  </Tab>

  <Tab title="Retail">
    **Store Workforce Management**

    1. **Budget**: Labor cost targets per location
    2. **Demand**: Customer traffic patterns and transaction forecasts
    3. **Shifts**: Generate shifts matching demand curves
    4. **Fill**: Assign staff respecting availability and preferences
    5. **Route**: Optimize stock replenishment and task assignments

    <Check>
      Achieve optimal coverage during peak hours while minimizing overstaffing.
    </Check>
  </Tab>

  <Tab title="Field Service">
    **Technician Dispatch**

    1. **Budget**: Service capacity and contractor budgets
    2. **Demand**: Work order forecasts and SLA requirements
    3. **Shifts**: On-call and regular shift schedules
    4. **Fill**: Match technician skills to work order types
    5. **Route**: Minimize travel, maximize appointments per day

    <Check>
      Increase daily appointments by 20% through intelligent routing.
    </Check>
  </Tab>

  <Tab title="Hospitality">
    **Restaurant Staff Scheduling**

    1. **Budget**: Labor percentage targets
    2. **Demand**: Reservation and walk-in forecasts
    3. **Shifts**: Kitchen, floor, and bar shift templates
    4. **Fill**: Assign based on skills, preferences, and labor rules
    5. **Route**: Optimize prep and service task sequences

    <Check>
      Balance coverage requirements with employee preferences and labor regulations.
    </Check>
  </Tab>
</Tabs>

## Getting Started

<Steps>
  <Step title="Start with Shift Filling">
    Most organizations begin with the Fill API to optimize existing shift assignments:

    <Card title="Fill API Quickstart" icon="rocket" href="/guides/fill/quickstart">
      Assign employees to shifts in minutes
    </Card>
  </Step>

  <Step title="Add Shift Creation">
    Once filling is optimized, add automated shift generation:

    <Card title="Create API Quickstart" icon="calendar-plus" href="/guides/create/quickstart">
      Generate shifts from demand forecasts
    </Card>
  </Step>

  <Step title="Integrate Task Routing">
    For field operations, add route optimization:

    <Card title="VRP API Quickstart" icon="route" href="/guides/vrp/quickstart">
      Optimize daily routes and schedules
    </Card>
  </Step>
</Steps>

## Next Steps

<CardGroup cols={2}>
  <Card title="Fill API Guide" icon="user-check" href="/guides/fill/quickstart">
    Employee-to-shift assignment optimization
  </Card>

  <Card title="Create API Guide" icon="calendar-plus" href="/guides/create/quickstart">
    Automated shift generation from demand
  </Card>

  <Card title="VRP API Guide" icon="route" href="/guides/vrp/quickstart">
    Route and schedule optimization
  </Card>

  <Card title="Platform Overview" icon="grid-2" href="/guides/platform/platform">
    Unified API design and architecture
  </Card>
</CardGroup>
