Machine Learning - Impacts on investments

Technology Reply Financial Services has developed a Use Case based on Machine Learning technologies,
to predict the performance of stocks.


In the last decade we have experienced, abroad more than in Italy, a revolution still in progress, involving the investor and the financial intermediary: automated financial consulting. The first financial intermediary company to focus on the automation of financial advice was Betterment, founded in 2008, which introduced the concept of robo-advisor.
Robo-advisors are a kind of financial consultants that provide financial advice or investment management online with few human intervention, from moderate to minimal.They provide digital financial advice based on mathematical formulas or algorithms executed directly by software that does not require a human advisor. The software uses its algorithms to distribute, manage, and optimize client assets.

Depending on the level of automation and the type of client being addressed, a robo-advisor can
  • replace the figure of the traditional financial advisor in relations between the financial intermediation company and the investor (B2C);
  • work alongside the traditional financial advisor in providing services to the investor (B2B).

Robo-advisory services bring benefits at the expense of traditional consulting:
  1. Convenience of using the service, since it is available 24/7;
  2. Reduction of intermediation costs incurred by the investor;
  3. Easier entry into the financial market for small investors.

Use case

The activities have been aimed at the creation of a model able to predict the performance of shares of listed companies, operating on financial time series and all the factors related to them.
This model is addressed to financial intermediation companies (B2B) in order to support the advisory service provided to investors.

The model is based on the choices an investor can make, which are:

  • Invest in new securities;
  • Change investments by switching from one security to another;
  • Sell without buying new securities;
  • Make no changes to his or her portfolio.

One of the main factors behind the decisions made by the investor is undoubtedly the performance of securities. Consequently, if a financial advisor had an estimate of these factors available, he could improve the quality of the advisory service he provides to investors. For example, he could recommend selling or increasing the investment on some securities already in the client's portfolio before they change their trend in a negative or positive way.

Other decisive factors in the price change of a stock may come from outside the financial market. For example, news that the financial year ended with higher-than-expected revenue may drive up the value of the company's stock. Conversely, news of a manufacturing defect in a product series could drive down the value of the stock. An investor and a financial intermediary in their evaluations must necessarily consider also this type of news, for such reason the model previews in its evolutions the component of integration of the feed news.


The price movement of a given stock can be imagined as a chronological sequence of numerical values.

For this reason, a time series is the perfect tool for the representation of the variation of the price of an action or a set of them as time passes, where time can be marked by a daily, weekly or monthly granularity.

Considering that within a time interval, which can be daily or more, the price can vary several times, it is appropriate to set a reference instant to make the observation; for example the opening or closing of the stock exchanges. Several reference instants could be chosen to then carry out an aggregation operation such as the average, for example.

Synthetic data was generated for low-to-medium level activities, while actual data was adopted for advanced activities.

  • Synthetic data (client portfolio, product time series); [medium level].
  • Real data (stock time series of approximately 400 stocks). [medium-advanced level]

The solution can be reached through the following steps:
  • Time series compression: representing a time series in a more compact manner for subsequent analysis (e.g., clustering) using "sequence to sequence" models;
  • Trend prediction: predict whether a stock will close positive or negative through the use of models based on both numbers and images;
  • Document classification and extraction of the most important parts: the goal is to build a single model that can perform a classification of documents and news and at the same time extract the most important parts (eg words, sentences and paragraphs) in an unsupervised manner.


A financial intermediary or financial advisor who decides to use the model presented here would, in the first instance, find it easier to make the decision to advise clients on a particular transaction than another.
The advice provided would tend to be more accurate and this would lead to greater effectiveness.
In this way, client satisfaction would tend to increase, leading to greater retention.
In addition, it would be possible to provide basic assistance to any client at any time of any day of the week, avoiding, thanks to automation, an increase in the cost of providing this service if it were to be done in the traditional way.