I have seen ideas posted about a form of ship "experience" before.
My idea is rather simple.
Lower the average number of attributes lost when a ship loses a level.
Example: 2-4 attributes lost when losing a level (average -3), versus 3-5 gained when leveling up (average +4).
Over time, ships that lose a lot of levels due to combat will gradually increase in average attributes if they are leveled back up.
This also encourages players to put "good" ships on the bottom of fleets to gain the benefit (at cost of losing!) over time.
-1