Blog

Forecasting demo

  • 14 July 2023
  • 2 replies
  • 202 views
Forecasting demo
Userlevel 7
Badge +5

Hi all,

Recently, we’ve released Thinkwise Platform version 2023.2. This release includes the ability to apply timeseries forecasting to your data.

In our recent release session, we showed a demo application that uses forecasting. This application is now available in the Thinkstore.

Simply download the solution, generate, execute and start the application via the Universal GUI.

The solution is available under the name ‘Forecasting’

The example application

Since the model in the Thinkstore is shipped with some example data, so you can try it out right away.

You will be prompted with a single menu item that shows a small list of articles with article sales for the last year.

The application is shipped with some example data

Clicking Predict sales for the next 30 days will generate a prediction of upcoming sales, as well as set the date on which stock may become critical.

Sales prediction for this article
Impact of the sales on the current stock. We run out within 27 days!

Information about the confidence of the forecast is also stored within the application and visualized - a graph for 50% confidence range and 90% confidence range.

The confidence range for printer sales is more extensive than other articles

How it’s made

The data model for this application is relatively simple:

Forecasting data model

Articles have stock and sales over time. The prediction is stored in a separate table containing the expected sales for upcoming dates as well as the confidence ranges.

A couple of views combine this data in graphs to make this information palatable for the end user.

The forecasting itself is done in via a process action:

The process flow for forecasting

The process action takes the article sales for an article in JSON format and the desired horizon - the number of days to forecast. The process action outputs this data which is subsequently stored.

If forecasting fails, a message is shown with information about what went wrong.

You can read more about how to use this new connector in the documentation. Or simply download the Thinkstore solution and fiddle around with it!

Note that the timeseries connector is only available via Indicium and cannot be used in a 2-tier Windows set-up. If you want to leverage forecasting in such a set-up, you’ll have to perform the forecasting using a scheduled system flow.

This example application allows you to manually use timeseries forecasting for a single situation. In practice, consider applying timeseries forecasting as part of a fully automated process.

To production

By default, Indicium will use a public forecasting test container hosted by Thinkwise. This allows every developer to quickly implement forecasting and determine the value of this feature.

There is no guaranteed uptime for this public service, nor is it aimed at high workloads, so for production environments you’ll need to set up and host your own container instance.

Documentation will be updated shortly with the following information:

The container image can be downloaded from the container registry and configured to be used by Indicium.

The URL for the container is: registry.thinkwisesoftware.com/public/forecast

This can be pinned on a specific version such as 2023.2 like the other container images.

Indicium can be configured to point to the service hosted by the container via the appsettings.json as following:

{
"MetaSourceConnection": {
"Server": "myServer",
"Database": "MY_IAM",
},
"AutoML": {
"ForecastingServiceURL": "http://localhost:8080/"
}
}

Depending on the deployment of the container image, the Forecasting Service URL can be a fully qualified domain name or simply an IP and port.

We look forward to hearing your experiences with this new feature of Thinkwise Platform version 2023.2!


2 replies

Userlevel 5
Badge +16

Is their any indication on the minimal CPU/MEM availability for the container running the forecasting service? 

Userlevel 1
Badge

Hi Freddy,

Both memory and CPU usage will largely depend on your data, and typical use.

A multi-core CPU would increase throughput. Any load is balanced between cores.
So if your responses are taking a long time, increase it.

As for memory, there is a hard limit of about 150 MiB. You need at least that much to even run the container normally. Anything over that, again, depends on your data and requests per unit time. My advise would be to set it to a few gigabytes and then scale back/up to your typical use.

Reply