That is an excellent question, and something that would be best addressed by your primary care physician
or other medical professional caring for you. There are several reasons that you might notice something like this. One potential cause is that you have been eating something that when defecated, may appear similar to yellow lentils in your stool. There is a potential for this, but because it has gone on for several years, there is a potential possibility that it is something more serious such as an infection, perhaps from a parasite. Here are some questions to consider that you should definitely mention to your physician when you are evaluated, as these will help him or her figure out what the cause of this is and what further testing is required. Have you been to another country, or eaten anything raw or not fully cooked? If that is the case, then it may be a parasite that resides in your gastrointestinal tract causing this to be seen. Have you noticed any itching or pain around your anus as this is another sign that a parasite is the cause of these findings in your stool. Either way, it is important that you are evaluated by a physician to figure out the cause of this.