What's what in JP:
J = total spin
P = parity
As to the light-baryon octet, it's a rather long story.
Quarks have color, flavor, spin, and orbit states.
Since they have spin 1/2, they follow Fermi-Dirac statistics, meaning that their combined wavefunction is antisymmetric. They are antisymmetric in color:
(rgb + gbr + brg - rbg - bgr - grb)/sqrt(6)
making them symmetric in the other states combined together. Orbit states we can ignore for the longer-lived baryons; the quarks are all in ground-state orbits. That leaves flavor and spin.
I'll consider only the three light flavors of quark: u, d, s, because those were the first ones discovered.
At first thought, one might want to have a state that's symmetric in flavor and spin separately.
For flavor, one gets uuu, uud, udd, ddd, uus, uds, dds, uss, dss, sss -- 10 flavor states.
The spin is all the quarks' spins parallel, giving spin 3/2. Thus, one ends up with 10 spin-flavor states. This is the light-baryon decuplet.
But we want an octet, so we must consider other possibilities. We must consider a system where spin and flavor separately have mixed symmetry, but combining into full symmetry.
The simplest case to examine is the case of all three quarks having different flavors: uds
Let's see how the u and d spins combine.
Parallel, symmetric: spin 1
Antiparallel, antisymmetric: spin 0
Add the s spin, and use angular-momentum addition. One gets three states:
Spin 3/2 -- we already did that
Spin 1/2, u and d parallel
Spin 1/2, u and d antiparallel
So we get not one, but two uds states.
If two of the quarks have the same flavor, then those quarks must have symmetric, parallel spins, giving total spin 1. That means that there is only one spin-1/2 state.
If all three quarks have the same flavor, then no spin-1/2 state is possible.
We thus get these states: uud, udd, uus, 2(uds), dds, uss, dss
These 8 states are the light-baryon octet that we were looking for.
This includes two uds baryons: the Lambda0 and the Sigma0. The Sigma0 is close in mass to the Sigma+ (uus) and the Sigma- (dds), meaning that the u and d quarks are symmetric in all three particles. The Lambda0's mass is more difference, because the QCD equivalent of the magnetic moment is somewhat less for the strange quark than for the up and down quarks.