Only had a night to spend on this, so its really basic version. Its only local completion, i.e. anything with a '.' wont get completed.
However, having the readline editing alone is nice to have. ctrl-a, ctrl-e, history etc.
InteractiveShell, shouldn't neccesarily need more changes. Most of the changes can hopefully be localised to the completer class. Hopefully someone more familiar with the parsing etc, can replace this class, with a lot more usable implementation.
License wise, its LGPL. We should be able to use it in BSD project, right? That said most people have readline library, which is GPL, so for LGPL you would have to install EditLine library. Anyway, it can work in pure java mode, and you could provide a configuration option that users can use to change to use EditLine.
library can be downloaded from http://java-readline.sourceforge.net/, and you will need to add -Djava.library.path= to groovysh script.