Latin carpere, to pluck, lies behind Old Italian carpire and carpita. Middle French carpite carried the word toward Middle English.
Middle English mediation is compressed between the French and modern English cards.
Sources
- Merriam-Webster: carpet
Latin carpere precedes Old Italian carpire and carpita, Middle French carpite and English carpet, with Middle English mediation.
- Online Etymology Dictionary · carpet
Meanings of the older forms on the word path.