The main duties of a samurai included serving their lord, upholding the code of bushido , honing their martial skills, and maintaining loyalty and honor.