Combine shrimp shells, onion, lemon, chopped celery, celery leaves, garlic, peppercorns, thyme, and bay leaves in a saucepan. Cover with water. Bring to a boil and reduce heat to low. Simmer until reduced by 1/2, skimming off foam as necessary, 45 minutes to 1 hour. Strain and use or freeze for later use.