If you plot your data, it looks noisy but fairly linear.

Why not use linear regression for it? You have very little data (unless you have more than you've shown us), so a simple model like linear regression sounds like a good bet. Your predicted column B seems to range between 0 and 1, if those are strict bounds, you could use logistic regression or beta regression, but depending on how you intend to use the model, this may not be necessary. If you have only one feature, using a more complicated model seems like an overkill.
Moreover, from what you are saying, you want to extrapolate beyond the data. Your column A ranges from 1 to 4 and you want to make a prediction when it's equal to 5. Models like random forest can't really extrapolate, so this is another reason for not using it here. Extrapolation is hard in general, with a simple model you can at least understand what it is doing and have a better understanding of its shortcomings.
Random forest is good at figuring out interactions between features, if you have only one feature, the regression trees which are used by it will behave like a piecewise regression (but always constant at edges). Averaging many such trees would lead to a smoother regression line, but again, not much better than something simple like local regression. There are many better alternatives if you have a single feature.
So if you have little data, only one feature, and want to extrapolate, linear regression seems to be a good choice.