Attempt. To be clear, I should recall what the axioms for a topological basis are.
A collection $\mathscr{B} \subseteq \mathscr{P}(X)$ of subsets of a set $X$ is a topological basis if it satisfies the following two properties:
- $X = \bigcup\limits_{B \in \mathscr{B}} B\,,$ i.e. the sets in $\mathscr{B}$ cover $X$.
- Given: $B_1, B_2 \in \mathscr{B}$. Then for all $x \in B_1 \cap B_2$, there exists a set $B_x \in \mathscr{B}$ such that: $$x \in B_x \subseteq B_1 \cap B_2 \,. $$
To recall, what I want to show is: if a collection of sets $\mathscr{A} \subseteq \mathscr{P}(X)$ satisfies the property given above, i.e. if the set of all arbitrary unions of sets in the collection $\mathscr{A}$ $$ \left\{ U : U = \bigcup\limits_{A \in\mathcal{A}\subseteq \mathscr{A}} A \right\}$$ satisfies the axioms of a topology on $X$, then $\mathscr{A}$ satisfies the axioms of a topological basis.
So assume that this property is satisfied, specifically this means that:
- $$\emptyset, X \in \left\{ U : U = \bigcup\limits_{A \in\mathcal{A}\subseteq \mathscr{A}} A \right\} $$
- $$T_1, T_2 \in \left\{ U : U = \bigcup\limits_{A \in\mathcal{A}\subseteq \mathscr{A}} A \right\} \implies T_1 \cap T_2 \in \left\{ U : U = \bigcup\limits_{A \in\mathcal{A}\subseteq \mathscr{A}} A \right\} $$
- $$\forall i \in I, T_i \in \left\{ U : U = \bigcup\limits_{A \in\mathcal{A}\subseteq \mathscr{A}} A \right\} \implies \bigcup\limits_{i \in I} T_i \in \left\{ U : U = \bigcup\limits_{A \in\mathcal{A}\subseteq \mathscr{A}} A \right\} $$
Clearly, for any $\mathcal{A} \subseteq \mathscr{A}$, we have that: $$\bigcup\limits_{A \in \mathcal{A}} A \subseteq \bigcup\limits_{A \in \mathscr{A}} A \,. $$ By our assumption, for some $\mathcal{A} \subseteq \mathscr{A}$, we have that $X = \bigcup\limits_{A \in \mathcal{A}} A$, so combining the above two statements, we have at once: $$X \subseteq \bigcup\limits_{A \in \mathscr{A}} A \,. $$ The reverse inclusion is trivial (since $\mathscr{A} \subseteq \mathscr{P}(X)$), and thus the first of the two axioms for a topological basis must be satisfied by $\mathscr{A}$.
To verify the second of the two axioms, let $A_1, A_2 \in \mathscr{A}$ be given. Consider an arbitrary $x \in A_1 \cap A_2$ (note that we can not necessarily assume that $A_1 \cap A_2 \in \mathscr{A}$, otherwise we would be done trivially).
For any $\mathcal{A}_1 \subseteq \mathscr{A}$ such that $A_1 \in \mathcal{A}_1$ and for any $\mathcal{A}_2 \subseteq \mathscr{A}$ such that $A_2 \in \mathcal{A}_2$, we have that: $$ \left(\bigcup\limits_{A \in \mathcal{A}_1} A \right) \cap \left( \bigcup\limits_{A \in \mathcal{A}_2} A \right) = \left( \bigcup\limits_{A \in \mathcal{A}_3} A \right) \,, $$ for some $A_3 \subseteq \mathscr{A}$, and likewise, reasoning in the other direction: $$\left(\bigcup\limits_{A \in \mathcal{A}_1} A \right) \cap \left( \bigcup\limits_{A \in \mathcal{A}_2} A \right) = \left(A_1 \cup \bigcup\limits_{A \in \mathcal{A}_1 \setminus \{A_1 \} } A \right) \cap \left( A_2 \cup \bigcup\limits_{A \in \mathcal{A}_2\setminus \{A_2 \} } A \right) \\ = (A_1 \cap A_2 ) \cup \bigcup\limits_{A \in \mathcal{A}_1 \setminus \{A_1 \} } (A \cap A_2) \cup \bigcup\limits_{A \in \mathcal{A}_2 \setminus \{A_2 \} } (A \cap A_1) \cup \left( \left(\bigcup\limits_{A \in \mathcal{A}_1 \setminus \{A_1 \} } A\right) \cap \left(\bigcup\limits_{A \in \mathcal{A}_2 \setminus \{A_2 \} } A \right) \right) \,. $$ Therefore we can conclude that, irrespective of the choice of $\mathcal{A}_1 \ni A_1, \mathcal{A}_2 \ni A_2$: $$(A_1 \cap A_2) \subseteq \bigcup\limits_{A \in \mathcal{A}_3} A \,. $$ In particular, we can choose $\mathcal{A}_1 = \{A_1 \}$ and $\mathcal{A}_2 = \{A_2 \}$ to get that: $$(A_1 \cap A_2) = \bigcup\limits_{A \in \mathcal{A}_3} A $$ for some $\mathcal{A}_3 \subseteq \mathscr{A}$. Therefore, there exists an $A_x \in \mathcal{A}_3$ such that $x \in A_x$ (irrespective of our choice of $x \in (A_1 \cap A_2)$). $A_x \in \mathcal{A}_3$ and $\mathcal{A}_3 \subseteq \mathscr{A}$ together imply that $A_x \in \mathscr{A}$, and clearly one has: $$A_x \subseteq \bigcup\limits_{A \in \mathcal{A}_3} A = (A_1 \cap A_2) \, , $$ so $A_x$ satisfies all of the required properties and the second axiom of a topological basis is verified. Thus being a topological basis is not only sufficient, but even necessary, for the collection of arbitrary unions to satisfy the axioms of a topology.
As Henno Brandsma astutely remarked in the comments, there is a simpler way to see not just the necessity, but both the necessity and sufficiency (the equivalence) at the same time, namely via an equivalent formulation of the second axiom of a topological basis.
2'. Given $B_1, B_2 \in \mathscr{B}$, there exists a $\mathcal{B} \subseteq \mathscr{B}$ such that: $$B_1 \cap B_2 = \bigcup\limits_{B \in \mathcal{B}} B \,.$$
Below I show briefly that 2. and 2'. are really equivalent.
Assume 2. Then we can write $$B_1 \cap B_2 = \bigcup\limits_{x \in B_1 \cap B_2} B_x \,. $$ Therefore 2'. holds. (I.e. take $\mathcal{B}=\{B_x : x \in B_1 \cap B_2 \}$.)
Assume 2'. Then for any $x \in B_1 \cap B_2$, there exists a $B_x \in \mathcal{B}$ such that $x \in B_x$ (assuming otherwise leads to a contradiction), and clearly we have, since $B_x \in \mathcal{B}$, $$B_x \subseteq \bigcup\limits_{B \in \mathcal{B}} B = B_1 \cap B_2\,. $$ Thus 2. holds.