This was exactly what i was looking for. With this, i have something like a console, to control the panes, windows
My biggest usecase right now is when i get dropped to a pdb shell, right now i call os.system("tmux split-window ..." ) with specific commands to either open up the source code of the last frame, or to open up a log file dump . Using libtmux would be easier and cleaner.