In ecological communities, interactions between consumers and resources lead to the emergence of ecological networks and a fundamental problem to solve is to understand which factors shape network structure. Empirical and theoretical studies on ecological networks suggest predator body size is a key factor structuring patterns of interaction. Because larger predators consume a wider resource range, including the prey consumed by smaller predators, we hypothesized that variation in body size favors the rise of nestedness. In contrast, if resource consumption requires specific adaptations, predators are expected to consume distinct sets of resources, thus favouring modularity. We investigate these predictions by characterising the trophic network of a species-rich Amazonian snake community (62 species). Our results revealed an intricate network pattern resulting from larger species feeding on higher diversity of prey, promoting nestedness, and specific lifestyles feeding on distinct resources, promoting modularity. Species removal simulations indicated that the nested structure is favored mainly by the presence of five species of the family Boidae, which because of their body size and generalist lifestyles connect modules in the network. Our study highlights the particular ways traits affect the structure of interactions among consumers and resources at the community level.