How to apply product object in category to get product sigma algebra/topology/set systems?

Following is similar to my earlier questions, but try to understand them from category theory. Mariano said it was possible in a comment, but I don't know how.

An object $X$ is the product of a family $\{X\}_i, i \in I$ of objects iff there exist morphisms $\pi_i : X \to X_i$, such that for every object $Y$ and a $I$-indexed family of morphisms $f_i : Y \to X_i$ there exists a unique morphism $f : Y \to X$ such that the following diagrams commute for all $i \in I$:

When applying that definition to set systems $(E_i, \mathcal{B}_i), i \in I$ of the same type $\theta$, to get their product set system $\mathcal{B}$ on $E= \prod_{i \in I} E_i$, I was wondering how that leads to $$\mathcal{B}=\theta \left(\left\{\text{\prod_{i \in I}B_i, where B_i \in \mathcal{B}_i, B_i=E_i for all but finitely many i \in I}\right\}\right),$$ where $\theta(\cdot)$ means taking the smallest set system of the type $\theta$ containing $\cdot$.

Can it be $$\mathcal{B}=\theta\left(\left\{\text{\prod_{i \in I}B_i, where B_i \in \mathcal{B}_i, B_i=E_i at least for all but one i \in I}\right\}\right),$$ instead?

Examples of product systems are product sigma algebras, product topology, and product of set systems defined to be closed under union only.

Thanks and regards!

-

Yes. It should originally be rather the "all but one $i$" version as you suggested, because the point is that each individual projection $\pi_i$ has to be a morphism in the given category.