Should history manager cache results?
Author: krassowskiCreated Sep 9, 2026Updated Sep 11, 2026
JupyterLab has inline completion which searches the history based on what user types. Since user usually types extra characters, it could be faster if instead of redoing the computation we filtered within previous results. In ipykernel this is exposed in https://github.com/ipython/ipykernel/blob/213cbf668219fe4e62afc97ee875bb9ead893899/ipykernel/ipkernel.py#L626-L641
Same optimization might be useful for IPython history completions too.
Source: ipython/ipython