In what turned out to be the best match of the week-long tournament, Walker staged a remarkable comeback after being down 3-7 at the end of the first session even as Ayouri turned complacent and then wilted under pressure. But eventually, the Iranian seemed destined to win the title as the Welshman fluffed the final pink in the 19th frame to gift the match to his younger opponent.
If Ayouri, with his amazing potting, dominated the first session, then it was Walker's turn on resumption as he fought his way back into contention and quite fittingly, the contest went to the wire.
The final frame of the match saw Ayouri jumping to a big lead, but a miss on a sitter black with five reds left, gave Walker a great opening. The Welshman compiled a break of 52 before breaking down on the last pink that he tried to roll into the top left pocket. The miss brought Ayouri back on table and the Iranian potted the last two colours to win the title.
Ultimately, Ayouri's faith in his attacking strokes made the difference as Walker who did not enjoy the run of the balls throughout the nine-hour contest, committed one mistake too many and paid the price.
"I was complacent after taking a 7-3 lead and when my opponent started fighting back, I became very nervous. In the last frame, I just couldn't believe that God smiled on me when he missed the pink," said an elated Ayouri after the match.
An obviously disappointed Walker said: "He is a fantastic talent and easily the best 17-year old player in the World. If he had continued to play like he did in the first session, he would have probably won 10-5 or 10-7.
"Having played a few best-of-19 matches and thrice at the Crucible (professional World championship), I knew that though I was trailing 3-7, I was in with a chance. I just stuck to my game and but for the pink that I missed in the last frame, I would have won."
In the process, Walker showed why he was ranked as high as 42 on the pro circuit that he played between 1994, the year Ayouri was born in a town called Abadan, about 70 km outside Tehran, and 2006. The Welshman fought every inch of the way, banking on his vast experience, but in the end, lady luck that was flirting with him all along, deserted him.
While Ayouri excelled with his potting and roamed the arena like a hungry predator, Walker was like the crafty hunter, plotting an ambush of his prey. The two made a fascinating study in contrast with their styles of play that were as different as chalk and cheese.
After the players shared the opening two frames with Walker making it 1-1 on a 116 break, it was Ayouri all the way as the Iranian, who is hoping to turn professional next season, took six of the next eight frames with a series of half-century breaks.
A 60-minute break for lunch seemed to have fortified Walker as he returned a different player. Gone was the indecision as he clawed his way back into the match after trailing 4-8. Ayouri had his chances of closing the match much earlier, but he committed far too many mistakes in his anxiety to finish the frames.
Walker kept his composure under pressure and stuck to his methodical, if a tad slow, game plan to effectively counter Ayouri's flamboyance that had the crowd gasping in disbelief.
Final (Best of 19 frames): Hoosein Vafaei Ayouri (Iran) bt Lee Walker (Wales) 10-9: 81-30, 05-121 (116); (49) 72-0; (56) 103-08; (40) 76-49; 05-59 (43); (57clearance) 62-59 (45); 74-15; 0-92 (87); 66-09; 53-75, (59) 73-24; 05-123 (78); 14-80 (45); 78-43; 39-79 (56); 52-57, 58-52 (52).