pynd is a command line utility for searching the Python abstract tree to easily find what you are looking for. It is a bit like using grep, but it understands Python syntax and structure. This means you can search for classes, functions or just within docstrings without relying on regular expressions.
See the documentation at: http://d0ugal.github.io/pynd/