Skip to main content

🧠 Daily Algorithm

Updated today

Assign your parking spaces fairly and reward good usage.
Hybo features an advanced system for the automatic allocation of parking spaces, designed to be fair, transparent, and configurable according to each organization’s needs.


πŸ“Š Allocation by priority

πŸ”§ How it works

When the system needs to automatically assign a space, it applies the following rules progressively:

Priority by employee type


The system prioritizes users who have an assigned category or employee type.

  • Example: If there are 10 requests for one space and only 5 users have a defined employee type, the allocation will be made among those users, applying the following rules in case of a tie.

Priority by zone type and vehicle type


If a user has an electric vehicle assigned, the system will first try to allocate a space in a zone with charging points. If none are available, a space in another zone will be assigned.

Number of previous reservations


If a tie remains after applying the previous rules, the space will be assigned to the user with the lowest number of previous reservations.

Random draw

If the tie still persists, the space will be assigned randomly among the users.


βš™οΈ Configuration

In the Parking module administration section, you will find two selectors:

  • Priority by employee type

  • Priority by zone type

You can enable one, both, or neither.

  • If both are disabled, the system will assign spaces randomly.

  • Users without an assigned category will only receive spaces if any remain after applying the above priorities.

πŸ—“οΈ Historical date analysis

To improve data analysis and algorithm behavior, two new configuration fields have been added to the Parking module:

  1. Number of weeks back
    Defines how many weeks back the system should analyze.
    ​Example: If you enter β€œ4”, the system will consider data from the last 4 weeks to calculate priorities.

  2. Start date
    Allows you to define from which day the weeks should start counting backward.
    If left empty, the start of the current week will be used as a reference.

πŸ”„ Algorithm logic

  • Automatic date reset
    Once the configured number of weeks has passed, the system automatically resets the start date, updating the analysis period.

  • No start date configured
    If only the number of weeks is defined and no date is specified, the system will automatically take the start of the current week as a reference. This date will be saved when the algorithm runs.


⏱️ When does it run?

  • Daily, at the configured time (hourPreBookings) in the office

  • Reactively, when a user releases a space

βš™οΈ How it works

  • Evaluates reservation requests in the queue (ParkingQueueReservation)

  • Reorders requests based on the following criteria, in this order:

    • Employee type priority (if enabled)

    • Zone type and vehicle type priority (if enabled)

    • Number of previous reservations (fewer reservations = higher priority)

    • Final randomization to break ties

  • Considers the zone selected by the user if hideZone is disabled

  • Assigns spaces respecting shifts (morning, afternoon, full day)

  • Penalizes users who did not check in on previous days (if enabled)

  • Rejects requests that exceed the number of available spaces

πŸ”” Notifications

  • To users with an assigned reservation

  • To users rejected due to lack of spaces (only if the variable "NotifyRejectedUsers" or penalty is configured via support)

  • To users who released a space, if it is reassigned (β€œlend” mode)

πŸ“Š Reports

The system can generate and send a report after execution, depending on configuration.

πŸ”„ Improvement in zone availability management

An improvement has been implemented in how the system manages space availability across different zones.

Previous behavior and identified issue
When the algorithm was executed:

  • If spaces in one zone were full but availability existed in another, the system enabled direct booking mode globally

This caused:

  • If a user tried to book in a zone without availability, the system would show an error instead of allowing a pre-booking

New improvement implemented
With this enhancement, the system now evaluates availability independently for each zone, allowing different behaviors depending on each zone’s status:

  • If a zone has availability β†’ direct booking is allowed

  • If a zone is full β†’ pre-booking is allowed

βš™οΈWeekday Execution

A new configuration has been introduced to define on which days the daily assignment algorithm is executed.

Functionality

This option allows controlling whether the algorithm should run only on working days.

  • Disabled (current behavior):
    The algorithm runs from Sunday to Thursday, assigning parking spaces for the following day.
    Example: Sunday β†’ Monday.

  • Enabled:
    The algorithm runs from Monday to Friday, considering only working days.
    In this case, assignments are performed as follows:

    • Monday β†’ Tuesday

    • Tuesday β†’ Wednesday

    • Wednesday β†’ Thursday

    • Thursday β†’ Friday

    • Friday β†’ Monday

More information here.

Did this answer your question?