Obtained from weekly bosses, local specialties or enemy drops. Exact source varies by character — see the list below.
To calculate all your characters at once, use the Genshin Calculator.