Essentially, the time it takes to develop a technology is based on its complexity and your species' skill in the area related to that. The higher its complexity, the longer it takes. The higher your skill in that area, the less time it takes. If the technology is based off technology that you already have, or you have spent time researching, then it takes less time.
This does not apply to weapons or defenses. Those are measured differently.