Postgres partition avoiding redundant column
Yes, the partitioning column must be part of the table.
I assume that you are using list partitioning. Now with list partitioning it is possible to have several values for the partitioning column in the same partition (FOR VALUES IN (1, 2, 27)), so one couldn't omit the partitioning column from the table.
Also, one of the key features of partitioning is that you can quickly attach and detach partitions. Now if the partitioning key were not stored, both attaching and detaching partitions would require a table rewrite.