Final delivery 🏴‍☠️🦜Protector of the Seas

As the captain of a ship, I want to be sure at all times that I will not encounter pirate ships.
This makes me and my crew safer in the work we have to do, which in turn leads to higher efficiency in our deliveries.

This is the user story we had as a starting point.

When we had to build a solution for this, we needed to be creative.
At first we thought we could use satellite images to recognize pirate ships from above. But it’s not that easy. Because flags that hang vertically or worn sails are not necessarily so easy to see from above.
Then we came up with a good idea. Pirates probably do not send information on AIS. But all law-abiding ships do.
If we then compare the number of ships we find in satellite images with the number of ships we find through AIS, within the same geographical area, we find out if any of the ships are pirates 🥳

Satellite image of ships

What we do.
We download satellite images from the Sentinel Hub API, which is an open API for satellite images. We then process the images with our own machine learning model, built from scratch in Python. This is trained to recognize ships at sea.
We get back the number of ships within the selected sector.
Then we check the Norwegian Coast Guard’s API for AIS data within the same coordinates. We get the number of ships from there as well.

We then compare the number of ships from satellite and AIS and store this in an Azure SQL table.

This is our backend solution in a nutshell.

Pirate tracker 3000 – web front end

In the front end, we have built a web app in Reajc.js that allows the users, authorities or shipping companies, to check sectors for pirate ships.
All ships in the sector appear on the map, where you can also click on them to read more information about the ship. If pirate ships are discovered, they appear with their own pirate flag symbols. Green needles are police or military vessels.

Ships in the sector

It is possible to send an alarm to all ships in the area if pirates are detected. A notification is then sent out to the ships that subscribe to our service, which sends a notification via a Teams bot. It tells what the threat is and where it is.
The light on board the bridge will also flash red if you have purchased this additional service.
In Teams, it will be possible to click to read more about the alert and see on the map where it is.
When the coast is clear, the alarm can be removed from the Teams client with a click.

Alarm light

From Teams on board the ship, it will be possible to check if there are pirates at coordinates you provide by sending a message to our bot. It then politely answers yes or no.
If there is something wrong with the message you send, you will also be informed about it in a polite way.

Notification on alarm
Check sector
Clear alarm
Intranet

This solution has two potential customer groups – authorities and shipping companies. The authorities want to have safe coastal routes for ships, shipping companies want their ships to be safe.

We have learned a lot through this assignment. Much of what we have created has been built from scratch, precisely to learn as much as possible. But we have also used a lot of off-the-shelf products.
Microsoft Teams and Sharepoint are used to have familiar, simple surfaces for end users. Power Automate is used to be able to easily flash alarm lights.
Otherwise, the rest of the solution is hosted in Azure.

Overall architecture
Starting plan