vanhees71 said:
This is the completeness relation for a bunch of vectors, usually a complete orthonormalized set of Hilbert-space basis vectors, [itex]|i\rangle[/itex]. These usually occur as eigenvectors of an self-adjoint operator.
To expand on vanhees's statement a bit, when we say "completeness," we are talking about a basis (usually an eigenbasis of a self-adjoint operator) for a particular vector space V. If we have a complete basis for a particular space (in this case, [itex]|i\rangle[/itex] collectively spans the vector space V), then we can express any arbitrary vector v (or function f if we're talking about a function space) as a sum of its components multiplied by the basis vectors. For example, if we're working in [itex]\Re^3[/itex], we can choose as a basis the standard basis vectors: [itex]e_1=(1,0,0)[/itex], [itex]e_2=(0,1,0)[/itex], and [itex]e_3=(0,0,1)[/itex]. In Dirac notation, these would typically be [itex]|1\rangle[/itex], [itex]|2\rangle[/itex], [itex]|3\rangle[/itex].
Now given an arbitrary vector in [itex]\Re^3[/itex], we can write it as a sum of [itex]|1\rangle, |2\rangle, |3\rangle[/itex] with the proper coefficients in front of each basis vector. For example, the vector [itex]u=(2,1,0)[/itex] can be expanded in the form [itex]|u\rangle = \sum_{i=1}^{3} | i \rangle \langle i | u \rangle[/itex] as [itex]| u \rangle = 2 | 1 \rangle + 1 | 2 \rangle + 0 | 3 \rangle[/itex].
The term [itex]\langle i | u \rangle[/itex] in the sum is the inner product of the basis vector with the arbitrary vector u. This inner product picks out the component of u in the direction of that particular i basis vector. Now this inner product is just a scalar value. The additional [itex]| i \rangle[/itex] is there because we're attempting to expand a vector as a sum of basis vectors multiplied by their respective components in u for each basis vector. So when you multiply an inner product by a ket, you're just scaling a ket. That's all.
I hope this helps!