Split pythagorean triples into two sets Task
Write a program/function that when given a positive integer \$n\$ splits the numbers from \$1\$ to \$n\$ into two sets, so that no integers \$a, b, c\$, satisfying \$a^2 + b^2 = c^2\$ are all in the same set. For example, if \$3\$ and \$4\$ are in the first set, then \$5\$ must be in the second set since \$3^2+4^2=5^2\$.
Acceptable Output Formats:

One of the sets
Both the sets
An array of length \$n\$ where the \$i\$-th element (counting from 1) is one of two different symbols (e.g. 0 and 1, a and b, etc.) which represent which set \$i\$ belongs to.The reverse of this is also fine

Constraints
You can expect \$n\$ to be less than \$7825\$. This is because \$7824\$ is proven to be the largest number to have solution (which also implies that all numbers less than 7825 have a solution).
Scoring
This is code-golf so shortest bytes wins.
Sample Testcases
3 -&gt; {1}
3 -&gt; {}
5 -&gt; {1, 2, 3}
5 -&gt; {1, 2, 3}, {4, 5}
5 -&gt; [0, 0, 0, 1, 1]
5 -&gt; [1, 1, 0, 0, 1]
10 -&gt; {1, 3, 6}
10 -&gt; {1, 2, 3, 4, 6, 9}
41 -&gt; {5, 6, 9, 15, 16, 20, 24, 35}

A checker to verify your output can be found here

Inspired by The Problem with 7825 - Numberphile
J, 37 bytes
Brute forces through the possible sets, outputs the bit mask.
((-&amp;.#.+./@,)[(e.~+/~)/.*:@#\)^:_@#&amp;1

Try it online! (Also outputs list as numbers for easier comparison.)
How it works
((-&amp;.#.+./@,)[(e.~+/~)/.*:@#\)^:_@#&amp;1
                                  #&amp;1 convert to list of N 1's
(                            )^:_     do until list does not change
                        *:@#\         right: convert to 1,4,9…,N^2
             [                        left: the bit mask
                      /.              partition left based on right, for each set:
                  +/~                 make M*M addition table
               e.~                    any element of that in the same set?
       +./@,                          OR all answers: 1 on conflict, 0 if finished
  -&amp;.#.                               list: from base 2, subtract that^, to base 2