For the purpose of calculating the CPI, the BLS:
1. Includes food and energy,
2. Accounts for shrinking packaging sizes, and
3. Does not substitute chicken for beef.
Because you are only partially on the right track:
Core Inflation does not use volatile food and energy
The CPI does have a substitution function in their formula.
A market basket of goods is weighted based on purchasing habits. Those habits cause updates every few years.