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

# Priority System

> How scheduling priorities work and how to adjust them

CharleOS uses a priority-based scheduling system that automatically orders work based on importance, urgency, and capacity constraints.

## How priorities work

### Fill-first algorithm

The system allocates capacity using a "fill-first" approach:

<Steps>
  <Step title="Sort by priority">
    All scheduled items sorted by priority (lower number = higher priority)
  </Step>

  <Step title="Allocate sequentially">
    Starting with highest priority, allocate as much capacity as possible
  </Step>

  <Step title="Track across days">
    Multi-day items track remaining minutes across multiple days
  </Step>

  <Step title="Fill to capacity">
    Continue until daily capacity is reached
  </Step>

  <Step title="Queue remainder">
    Items without capacity marked as "queued"
  </Step>
</Steps>

**Key principle:** Higher priority items always get capacity first. Lower priority items only get time if capacity remains.

## Priority tiers

### The five tiers

| Tier  | Priority Range | Description                        | Example                                      |
| ----- | -------------- | ---------------------------------- | -------------------------------------------- |
| **1** | 1-99           | Help desk tickets                  | Client reported a bug                        |
| **2** | 100-199        | Work-in-progress multi-day items   | Task started Monday, still working Wednesday |
| **3** | 200-299        | Single-day items starting today    | 2hr task scheduled for today only            |
| **4** | 300-399        | New multi-day items starting today | 8hr task starting today, ends tomorrow       |
| **5** | 400+           | Future items                       | Items starting after today                   |

### Tier 1: Help desk tickets

**Always highest priority:**

* Range: 1-99
* Covers urgent client issues
* Should be addressed immediately
* Can only be deprioritized explicitly by PM

**Why highest:**

* Client impact is immediate
* Often blocking client work
* Demonstrates responsiveness
* Builds client trust

<Warning>
  Moving help desk tickets below subtasks requires explicit confirmation. This is an intentional override of best practices.
</Warning>

### Tier 2: Work-in-progress multi-day items

**Priority for continuity:**

* Range: 100-199
* Items that started before today
* Priority calculated: `100 + (99 - daysSinceStart)`
* Earlier start = higher priority

**Why prioritized:**

* Person already has context
* Switching tasks wastes time
* Completing in-progress work first
* Maintains flow state

**Example:**

* Task started 5 days ago: priority = 194
* Task started 2 days ago: priority = 197
* Earlier start gets slightly higher priority

### Tier 3: Single-day items starting today

**Medium priority:**

* Range: 200-299
* Tasks that fit within one working day
* Start and end today
* Priority: `200 + index`

**Why medium:**

* Can be completed today
* No multi-day coordination needed
* Lower context switching cost

### Tier 4: New multi-day items starting today

**Lower priority:**

* Range: 300-399
* Tasks starting today but spanning multiple days
* Priority: `300 + index`

**Why lower:**

* Will have tomorrow to continue
* Let single-day items complete first
* Reduces partial completions

### Tier 5: Future items

**Lowest priority:**

* Range: 400+
* Items starting after today
* Display only (shouldn't get capacity today)
* Priority: `400 + index`

**Why lowest:**

* Not meant to start yet
* Future dates for reference
* Get capacity on their start date

## Explicit vs calculated priority

### Calculated priority (default)

Most items use calculated priority:

* System determines tier based on dates and type
* Automatically adjusts as days pass
* No manual intervention needed

### Explicit priority (PM override)

PMs can set explicit priority:

* Drag-and-drop to reorder within a day
* Sets a fixed priority number
* Overrides calculated priority
* Persists until changed

<Info>
  Explicit priorities are set when PMs drag-and-drop tasks in the day breakdown. The new order is saved and maintained even as days change.
</Info>

## Priority calculation examples

### Example 1: Typical day

**Wednesday schedule for Developer:**

| Item               | Type      | Start Date | Priority | Tier                             |
| ------------------ | --------- | ---------- | -------- | -------------------------------- |
| Bug fix ticket     | Help Desk | Tuesday    | 15       | Tier 1 (Help Desk)               |
| Navigation feature | Subtask   | Monday     | 197      | Tier 2 (WIP, started 2 days ago) |
| Header styling     | Subtask   | Wednesday  | 200      | Tier 3 (Single-day, today)       |
| Checkout flow      | Subtask   | Wednesday  | 300      | Tier 4 (Multi-day, starts today) |

**Capacity allocation (6.5h available):**

1. Bug fix: 2h allocated (2h remaining)
2. Navigation: 4h allocated (2.5h remaining)
3. Header styling: 2h allocated (0.5h remaining)
4. Checkout flow: 0.5h allocated (6h remaining, will continue tomorrow)

### Example 2: With explicit priority

**After PM reorders:**

PM moves "Header styling" above "Navigation feature" via drag-and-drop.

| Item               | Type      | Explicit Priority | New Order        |
| ------------------ | --------- | ----------------- | ---------------- |
| Bug fix ticket     | Help Desk | 15                | 1st (unchanged)  |
| Header styling     | Subtask   | 150               | 2nd (moved up)   |
| Navigation feature | Subtask   | 151               | 3rd (moved down) |
| Checkout flow      | Subtask   | 300               | 4th (unchanged)  |

**Result:** Header styling gets capacity before navigation feature, overriding the calculated priority.

## Auto-scheduling recommendations

### For help desk tickets

When scheduling help desk tickets, the system recommends assignees based on:

<CardGroup cols={2}>
  <Card title="Work Type Match" icon="user-check">
    Developer for bugs, Designer for design issues, QA for testing
  </Card>

  <Card title="Capacity Available" icon="gauge">
    Team members with available capacity
  </Card>

  <Card title="Engagement Type" icon="handshake">
    Retainer team prioritized over project team
  </Card>

  <Card title="Impact" icon="chart-line">
    Least disruption to existing schedules
  </Card>
</CardGroup>

### Recommendation factors

The system calculates:

* **Hours of work pushed** - How much existing work would be delayed
* **Number of tasks affected** - How many items would be rescheduled
* **Deadline risks** - Whether deadlines would be missed
* **Team preference** - Retainer vs project assignments

**Recommendation display:**

* Grouped by engagement type (Retainer / Project / Other)
* Sorted by impact (least disruption first)
* Shows capacity impact for each option

<Tip>
  The system suggests the best assignee, but PMs can override based on other factors like specific client relationships or specialized skills.
</Tip>

## Conflict detection

### When conflicts occur

Conflicts arise when:

* Scheduling new work overlaps existing scheduled work
* Available capacity is insufficient
* Multiple items compete for same time

### How conflicts are detected

<Steps>
  <Step title="Check date ranges">
    Identify overlapping date ranges
  </Step>

  <Step title="Calculate impact">
    Determine how many days overlap (working days only)
  </Step>

  <Step title="Simulate rescheduling">
    Calculate new end dates for affected items
  </Step>

  <Step title="Sort by priority">
    Show which items would be pushed (lower priority first)
  </Step>
</Steps>

### Conflict resolution

**Conflict dialog shows:**

* List of affected tasks
* Current end dates
* New end dates (after push)
* Number of days pushed
* Suggested conflict-free start date

**Resolution options:**

1. **Use suggested date** - Schedule on recommended conflict-free date
2. **Push and schedule anyway** - Accept the conflicts and reschedule affected items
3. **Cancel** - Don't schedule, find alternative

<Warning>
  Pushing work has a cascade effect. Pushing Item A might push Item B, which pushes Item C. Consider the full impact.
</Warning>

### Protected priorities

Help desk tickets are protected:

* System tries not to push help desk tickets
* If unavoidable, warns explicitly
* Requires confirmation to proceed

## Capacity-based prioritization

### Daily capacity limits

The system respects daily capacity:

* Developers: 6.5 hours (390 minutes)
* Other roles: 7.5 hours (450 minutes)
* Role-based capacity applied automatically
* Reduced by leave or holidays
* Hard limit (cannot exceed)

### Allocation process

Within capacity limits:

1. Help desk tickets allocated first
2. WIP items get priority
3. New work fills remaining capacity
4. Excess work marked "queued"

### Queued items

Items without capacity:

* Shown as "Queued" status
* 0 hours allocated
* Still scheduled for the day
* Will get capacity when higher priority items complete

<Info>
  Queued status helps identify capacity bottlenecks. If many items are queued, either reduce work or increase capacity.
</Info>

## Adjusting priorities

### When to adjust

Consider adjusting priorities when:

* Client urgency changes
* Deadlines shift
* Dependencies require different order
* Team member expertise needed
* Strategic importance changes

### How to adjust

<Steps>
  <Step title="Open day breakdown">
    Click allocation badge for the day
  </Step>

  <Step title="Drag to reorder">
    Drag items to new position using grip handle
  </Step>

  <Step title="Confirm if needed">
    Confirm if moving help desk below subtasks
  </Step>

  <Step title="Verify impact">
    Check if reordering creates capacity issues
  </Step>
</Steps>

### Best practices for adjusting

<CardGroup cols={2}>
  <Card title="Use sparingly" icon="hand">
    Let system handle most prioritization automatically
  </Card>

  <Card title="Document reasons" icon="pen">
    Add comments explaining priority overrides
  </Card>

  <Card title="Respect help desk" icon="ticket">
    Keep help desk tickets at top unless critical exception
  </Card>

  <Card title="Consider dependencies" icon="diagram-project">
    Don't prioritize items that depend on incomplete work
  </Card>

  <Card title="Monitor impact" icon="chart-mixed">
    Watch for cascade effects on other days
  </Card>

  <Card title="Communicate changes" icon="message">
    Inform team when changing their priorities
  </Card>
</CardGroup>

## Best practices

<CardGroup cols={2}>
  <Card title="Trust the system" icon="robot">
    Default priorities work well for most situations
  </Card>

  <Card title="Complete help desk first" icon="gauge-high">
    Always prioritize client-facing issues
  </Card>

  <Card title="Finish started work" icon="circle-check">
    WIP items should complete before starting new work
  </Card>

  <Card title="Watch for queued items" icon="clock">
    Queued items indicate capacity problems
  </Card>

  <Card title="Don't over-schedule" icon="calendar-xmark">
    Avoid scheduling beyond realistic capacity
  </Card>

  <Card title="Review weekly" icon="calendar-week">
    Check priorities at start of each week
  </Card>
</CardGroup>

## Next steps

<CardGroup cols={2}>
  <Card title="Day Breakdown" icon="list" href="/user-guide/schedule/day-breakdown">
    Learn how to view and reorder priorities
  </Card>

  <Card title="Timeline View" icon="chart-gantt" href="/user-guide/schedule/timeline-view">
    Navigate the full schedule timeline
  </Card>

  <Card title="Subtasks" icon="list-check" href="/user-guide/tasks/subtasks">
    Understand how subtasks are scheduled
  </Card>

  <Card title="Help Desk" icon="ticket" href="/user-guide/help-desk">
    Learn about help desk ticket prioritization
  </Card>
</CardGroup>
