Trickery is a Dark-type attack that uses the opponent's Attack stat against them. It has a base 95 BP, 100 Accuracy, Physical allignment, and 15 PP.
Let's say that Zoroark is fighting against a Rampardos. Rampardos have ridiculously high Attack. Before Rampardos came into play, Zoroark was beat up pretty badly from that Machamp that switched in before, and one attack will probably KO it.
You look at your move list: Return won't do much. Dig is bad, in case it's packing Earthquake. Pursuit just isn't strong enough...Oh?Trickery! Use this powerful Dark-type attack to turn Rampardos' Base 165 Attack stat AGAINST IT. And BAM, you get the KO.
Long story; short, for this attack, the damage calculation is made from your opponent's Attack, not yours. Attack boosts for your opponent also apply, but keep note that your own Swords Dance / Claw Sharpen won't power up Trickery at all.