"We have guided him to the way" (76:3) means: We have shown him the path of guidance and the path of misguidance, "either grateful" (76:3) meaning a believer, "or ungrateful" (76:3).
Muhammad said: "Grateful" and "ungrateful" are in the accusative case (nasb) as a state (hal). The meaning is: either grateful or ungrateful, as if He said: We guided him while he is in one of these states.
Tafsir of Surah al-Insan from verse (5-18)
﴿إِنَّا هديناه السَّبِيل﴾ أَيْ: بصَّرناه سَبِيلَ الْهُدَى وَسَبِيلَ الضَّلَالَة ﴿إِمَّا شاكرا﴾ مُؤمنا ﴿وَإِمَّا كفورا﴾.
قَالَ محمدٌ: (إِمَّا شَاكِرًا وَإِمَّا كفورًا) هُمَا نَصْبٌ عَلَى الْحَالِ، الْمَعْنَى: شَاكِرًا أَوْ كَفُورًا، كَأَنَّهُ قَالَ: هديناه فِي هَذِه الْحَال.
تَفْسِير سُورَة الْإِنْسَان من آيَة (٥ - ١٨)