diff --git a/docs/cookbook/chain_of_thought.md b/docs/cookbook/chain_of_thought.md
index 17c362696..bd76f40b7 100644
--- a/docs/cookbook/chain_of_thought.md
+++ b/docs/cookbook/chain_of_thought.md
@@ -94,7 +94,7 @@ def generate_hermes_prompt(user_prompt):
return (
"<|im_start|>system\n"
"You are a world class AI model who answers questions in JSON "
- f"Here's the json schema you must adhere to:\n\n{schema}\n<|im_end|>\n"
+ f"Here's the json schema you must adhere to:\n\n{json_schema}\n<|im_end|>\n"
"<|im_start|>user\n"
+ user_prompt
+ "<|im_end|>"