Well, I solved it using the Shell Commands plugin and making the modifications on the current note with a Python script.
I am very, very satisfied with the result. You can write any script, add a command in Obsidian to call it and, call it from the command palette, with hotkeys or with a custom buttom if you use the Buttons plugin.
Very, very cool, and with Python it is very easy to make any modification or manipulation on notes.