BonsaiBONSAI
← All news
Engineering2 min read

Swarm intelligence: domain first, algorithm second

Why swarm intelligence problems require understanding the system before choosing an algorithm — with warehouse robots and LogiFlex as examples.

One of the key challenges — and at the same time one of the trends — in swarm intelligence today can be summed up as: domain first, algorithm second. It is not enough to take Ant Colony Optimization, Particle Swarm Optimization or another elegant approach and try to fit it into a business problem.

First you need to understand the system itself: what counts as an agent, what its constraints are, how agents interact and what a good result actually looks like. Only then should you choose an algorithm. Swarm intelligence does not know what a good route, an efficient warehouse or proper robot coordination is — it only searches for a solution within the space we have designed for it.

Example: a warehouse with autonomous robots

You could say right away: “Let’s apply swarm intelligence.” But first you need to understand the physics of the process:

  1. 01What is being moved and where the robots can drive
  2. 02Where congestion occurs
  3. 03How the robots recharge
  4. 04Which tasks take priority
  5. 05What counts as a good result

Only after that does a mathematical formulation emerge: agent, state, allowed actions, constraints, objective function.

And only then can you decide whether a swarm is needed at all. Perhaps classical optimization would solve the problem better. Perhaps a genetic algorithm. Perhaps a few simple heuristics. Or perhaps you really do need a system where many agents make local decisions and together produce global behavior.

How it worked in LogiFlex

We have already applied similar logic when developing LogiFlex, a system that optimizes how goods are loaded into freight vehicles. First we studied the warehouse structure, product categories and real logistics scenarios, then formalized dimensions, weight, product compatibility and other constraints — and only after that built a solution based on a genetic algorithm.

As a result, the system evaluates more than 10,000 placement options while respecting the physical constraints of the cargo, and calculates the load plan in about 10 seconds.

That is why our rule for R&D projects like this is quite simple:

We don’t look for a problem to fit an elegant algorithm. We understand the problem first — then choose the algorithm.