--- a/net/minecraft/world/item/crafting/SmithingTransformRecipe.java
+++ b/net/minecraft/world/item/crafting/SmithingTransformRecipe.java
@@ -9,14 +9,29 @@
 import net.minecraft.world.Container;
 import net.minecraft.world.item.ItemStack;
 import net.minecraft.world.level.Level;
+// CraftBukkit start
+import org.bukkit.NamespacedKey;
+import org.bukkit.craftbukkit.v1_20_R2.inventory.CraftItemStack;
+import org.bukkit.craftbukkit.v1_20_R2.inventory.CraftRecipe;
+import org.bukkit.craftbukkit.v1_20_R2.inventory.CraftSmithingTransformRecipe;
+import org.bukkit.inventory.Recipe;
+// CraftBukkit end
 
 public class SmithingTransformRecipe implements SmithingRecipe {
+
     final Ingredient template;
     final Ingredient base;
     final Ingredient addition;
     final ItemStack result;
+    final boolean copyNBT; // Paper
 
     public SmithingTransformRecipe(Ingredient template, Ingredient base, Ingredient addition, ItemStack result) {
+        // Paper start
+        this(template, base, addition, result, true);
+    }
+    public SmithingTransformRecipe(Ingredient template, Ingredient base, Ingredient addition, ItemStack result, boolean copyNBT) {
+        this.copyNBT = copyNBT;
+        // Paper end
         this.template = template;
         this.base = base;
         this.addition = addition;
@@ -30,13 +45,16 @@
 
     @Override
     public ItemStack assemble(Container inventory, RegistryAccess registryManager) {
-        ItemStack itemStack = this.result.copy();
-        CompoundTag compoundTag = inventory.getItem(1).getTag();
-        if (compoundTag != null) {
-            itemStack.setTag(compoundTag.copy());
+        ItemStack itemstack = this.result.copy();
+        if (this.copyNBT) { // Paper - copy nbt conditionally
+        CompoundTag nbttagcompound = inventory.getItem(1).getTag();
+
+        if (nbttagcompound != null) {
+            itemstack.setTag(nbttagcompound.copy());
         }
+        } // Paper
 
-        return itemStack;
+        return itemstack;
     }
 
     @Override
@@ -69,34 +87,48 @@
         return Stream.of(this.template, this.base, this.addition).anyMatch(Ingredient::isEmpty);
     }
 
+    // CraftBukkit start
+    @Override
+    public Recipe toBukkitRecipe(NamespacedKey id) {
+        CraftItemStack result = CraftItemStack.asCraftMirror(this.result);
+
+        CraftSmithingTransformRecipe recipe = new CraftSmithingTransformRecipe(id, result, CraftRecipe.toBukkit(this.template), CraftRecipe.toBukkit(this.base), CraftRecipe.toBukkit(this.addition), this.copyNBT); // Paper
+
+        return recipe;
+    }
+    // CraftBukkit end
+
     public static class Serializer implements RecipeSerializer<SmithingTransformRecipe> {
+
         private static final Codec<SmithingTransformRecipe> CODEC = RecordCodecBuilder.create((instance) -> {
-            return instance.group(Ingredient.CODEC.fieldOf("template").forGetter((recipe) -> {
-                return recipe.template;
-            }), Ingredient.CODEC.fieldOf("base").forGetter((recipe) -> {
-                return recipe.base;
-            }), Ingredient.CODEC.fieldOf("addition").forGetter((recipe) -> {
-                return recipe.addition;
-            }), CraftingRecipeCodecs.ITEMSTACK_OBJECT_CODEC.fieldOf("result").forGetter((recipe) -> {
-                return recipe.result;
+            return instance.group(Ingredient.CODEC.fieldOf("template").forGetter((smithingtransformrecipe) -> {
+                return smithingtransformrecipe.template;
+            }), Ingredient.CODEC.fieldOf("base").forGetter((smithingtransformrecipe) -> {
+                return smithingtransformrecipe.base;
+            }), Ingredient.CODEC.fieldOf("addition").forGetter((smithingtransformrecipe) -> {
+                return smithingtransformrecipe.addition;
+            }), CraftingRecipeCodecs.ITEMSTACK_OBJECT_CODEC.fieldOf("result").forGetter((smithingtransformrecipe) -> {
+                return smithingtransformrecipe.result;
             })).apply(instance, SmithingTransformRecipe::new);
         });
 
+        public Serializer() {}
+
         @Override
         public Codec<SmithingTransformRecipe> codec() {
-            return CODEC;
+            return SmithingTransformRecipe.Serializer.CODEC;
         }
 
         @Override
-        public SmithingTransformRecipe fromNetwork(FriendlyByteBuf friendlyByteBuf) {
-            Ingredient ingredient = Ingredient.fromNetwork(friendlyByteBuf);
-            Ingredient ingredient2 = Ingredient.fromNetwork(friendlyByteBuf);
-            Ingredient ingredient3 = Ingredient.fromNetwork(friendlyByteBuf);
-            ItemStack itemStack = friendlyByteBuf.readItem();
-            return new SmithingTransformRecipe(ingredient, ingredient2, ingredient3, itemStack);
+        public SmithingTransformRecipe fromNetwork(FriendlyByteBuf buf) {
+            Ingredient recipeitemstack = Ingredient.fromNetwork(buf);
+            Ingredient recipeitemstack1 = Ingredient.fromNetwork(buf);
+            Ingredient recipeitemstack2 = Ingredient.fromNetwork(buf);
+            ItemStack itemstack = buf.readItem();
+
+            return new SmithingTransformRecipe(recipeitemstack, recipeitemstack1, recipeitemstack2, itemstack);
         }
 
-        @Override
         public void toNetwork(FriendlyByteBuf buf, SmithingTransformRecipe recipe) {
             recipe.template.toNetwork(buf);
             recipe.base.toNetwork(buf);
