Hi,
looking into the doc, you'll find that you can set a dependency based on a tables name rather than a command, so digging into the generated code is not an obligation.
Now, as Frans stated (http://www.llblgen.com/tinyforum/Messages.aspx?ThreadID=5710 for reference), you can access the command object to finer define your dependency.
If you do so, you'll need to think about your dependency convention naming, since you may have various commands for a single table to deal with. Also, if you deal with many parameters such as paging I'm not sure about the overhead for the many dependencies. Probably better attach directly to the table in that case (check for the doc).
Now about how to handle that:
Create a caching controller abstracting the functionality, and in your business controller, update the methods calling the queries so that they get the corresponding keys (an enum + parameters might help serving the keys with more ease), check if the data is in cache, if it's there get it. If not run the query, put the result in cache attached to the dependency (you also need the depency's key right), and return the result.
My experience is that entities and collection get cached pretty well.
Now be aware that the cache will perform shallow copy, so if you edit an entity, it will get changed right into the cache. You may also experience concurrent access problems . If you want to avoid that, take care of deep copying in your caching controller. That of course removes part of the perfs benefit but it's still ok.
Hope that helps