  We introduce a functor ${\sf As}$ from the category of posets to the category
of nonsymmetric binary and quadratic operads, establishing a new connection
between these two categories. Each operad obtained by the construction ${\sf
As}$ provides a generalization of the associative operad because all of its
generating operations are associative. This construction has a very singular
property: the operads obtained from ${\sf As}$ are almost never basic. Besides,
the properties of the obtained operads, such as Koszulity, basicity,
associative elements, realization, and dimensions, depend on combinatorial
properties of the starting posets. Among others, we show that the property of
being a forest for the Hasse diagram of the starting poset implies that the
obtained operad is Koszul. Moreover, we show that the construction ${\sf As}$
restricted to a certain family of posets with Hasse diagrams satisfying some
combinatorial properties is closed under Koszul duality.
