What I mean is, what kind of light do you have, stocking, invertebrate inhabitants, plant species (both terrestrial and aquatic), do you add anything to the system like leaf litter, etc.
The fact that your tank is a different scale than the OP's has a dramatic impact on the discourse. I personally think that such a system is possible given a solid understanding of ecology, but one with such a background would preclude the possibility of a nano system as the OP described (plants + inverts + algae + fish) being viable at almost any term. The rule of 10%, a fundamental rule of ecology, states that 10% of the energy from the previous tier in the food chain makes it to the upper tier. So if shrimp are eating algae, they are effectively harvesting 10% of the energy utilized by the algae. If something is eating the shrimp, then they are getting 10% of the energy gathered by the shrimp, and 1% of the energy gathered by the algae. This is why the size of the system is critically important to the discussion. Larger tanks can 'harvest' light and translate it into secondary consumers (like fish, vegetarians excluded) better than small tanks. In the previously linked tank, the 3x3x1 tank is designed to have more area to absorb light and therefore translate it into upper tiers.