I think to scale it, outputs need to be concatenated, for example,
sentence -> yes yes yes yes yes no yes yes yes yes yes yes

expected outcome after training -> [0 0 0 0 0 1 0 0 0 0 0 0]

break into parts -> [yes yes yes] [yes yes no] [yes yes yes] [yes yes yes]

random initialize -> [1 2 3] [4 5 6] [7 8 9] [10 11 12]

# assume we represent each word by a vector of size 1

get score -> [3 2 3] [3 2 3] [3 2 3] [3 2 3]

# assume our formula for difference between two words is difference between their vectors, ideally we would want to multiply those vectors also

pass scores up -> [3 2 3 3 2 3] [3 2 3 3 2 3]

get score -> [2 4 2 2 4 2] [2 4 2 2 4 2]

pass scores up -> [2 4 2 2 4 2 2 4 2 2 4 2]

get score -> [8 16 8 8 16 8 8 16 8 8 16 8]

someway represent it as -> [0 1 0 0 1 0 0 1 0 0 1 0]

outcome -> [yes no yes yes no yes yes no yes yes no yes]

expected outcome -> [yes yes yes yes yes no yes yes yes yes yes yes]

get a loss, backprop, update initialization.
same thing applies for pixels, discrete values also
can you give me example of some other problem where we do not know the value in advance, I think so same thing would apply to such problem also.
or maybe we only need to change the order after concatenation, as computing score for so many numbers would be difficult after concatenation.
sentence -> yes yes yes yes yes no yes yes yes yes yes yes

expected outcome after training -> [0 0 0 0 0 1 0 0 0 0 0 0]

break into parts -> [yes yes yes] [yes yes no] [yes yes yes] [yes yes yes]

random initialize -> [1 2 3] [4 5 6] [7 8 9] [10 11 12]
# assume we represent each word by a vector of size 1

get score -> [3 2 3] [3 2 3] [3 2 3] [3 2 3] 
# assume our formula for difference between two words is difference between their vectors
# we would want to multiply those vectors also

pass scores up -> [[3 2 3] [3 2 3]] [[3 2 3] [3 2 3]]
# let us represent these vectors as a b c d

represented as -> [   a       b   ] [   c       d   ]
# we do not change a b c d, only change the order in which they get concatenated
# here a, b, c, d are same, but assume they were different
# so after changing order it could be, 
[b a][d c]
[a b][d c]
[b a][c d]
# neural network needs to learn to change the order also, I do not know how will this happen.
# we apply same technique on a b c d

# we store a b c d, as we will have to reveal them later

# randomly initialize these four vectors by a vector of size 1
represented as -> [1 2] [3 4]
# apply the same formula again

get score -> [1 1] [1 1]

do concatenation again -> [[1 1] [1 1]]

represented_as -> [a b]
which could be [b a]

represented_as -> [1 2]
# random initialization, representing each vector as a vector of size 1

pass scores up -> [1]

represented_as -> [a]
now no concatenation is possible, we have reduced it to one vector,
so, reveal it, based on all concatenations.

assume we get outcome -> [yes no yes yes no yes yes no yes yes no yes]

expected outcome -> [yes yes yes yes yes no yes yes yes yes yes yes]

get a loss, backprop, update initialization.

in the 2nd case, task of neural network would be to learn to initialize vectors at each level.