Ornithine is a non-proteinogenic amino acid that plays a crucial role in the urea cycle, which is the metabolic pathway responsible for the detoxification of ammonia in the liver. It serves as an intermediate in the conversion of ammonia into urea, allowing for the safe excretion of nitrogenous waste from the body. This process is essential for maintaining nitrogen balance and preventing the toxic buildup of ammonia in organisms.