Fine-Tune the Regression Model
In this example, we use our sample PostgreSQL database. You can connect to it like this:
First, we create and train the model using a subset of the home_rentals
data, considering properties that have been on the market less than 10 days.
On execution, we get:
We can check its status using this command:
Once the status is complete, we can query for predictions.
On execution, we get:
Let’s adjust this model with more training data. Now we consider properties that have been on the market for 10 or more days.
While the model is being generated and trained, it is not active. The model becomes active only after it completes generating and training.
To check the status and versions of the model, run this command:
On execution, we get:
Please note that the longer the property is on the market, the lower its rental price. Hence, we can expect the rental_price
prediction to be lower.
On execution, we get:
If you have dynamic data that gets updated regularly, you can set up an automated fine-tuning as below.
Note that the data source must contain an incremental column, such as timestamp or integer, so MindsDB can pick up only the recently added data with the help of the LAST
keyword.
Here is how to create and schedule a job to fine-tune the model periodically.
Now your model will be fine-tuned with newly added data every day or every time there is new data available.
Was this page helpful?