In a quick test, it seemed that two library routines with the same name but in different files are not both loaded into memory. So the suggestion won't work without further changes. But ...
If you have mycommand in file1 and mycommand in file2, and you're willing to use file1$mycommand and file2$mycommand to distinguish between them, why not name the routines file1mycommand and file2mycommand (and put them whereever you like). That way you can skip typing the '$' when you invoke them! :-)