There is hardly one way that a text must be understood in Greek. There are usually numerous options given to one who translates ancient Greek. For example, A.T. Robertson (in his big grammar) argues that both substantives (κύριος and πνεῦμα) in 2 Cor 3:17 are definite and interchangeable. He bases his remarks on the fact that the subject and predicate in this passage both have the definite article. However, as Maximilian Zerwick says concerning the way he understands 2 Cor 3:17, that is only one interpretation of this construction.
Zerwick thinks that both articles in 2 Cor 3:17 are anaphorical, speaking of that which precedes rather than what follows. Therefore, he views ὁ δὲ κύριος as continuing the thought expressed in 2 Cor 3:16, whereas τὸ πνεῦμά references the spirit mentioned in the preceding context. But he notes that this is one way of many to interpret the Bible verse. See section 169 of Zerwick's Biblical Greek.