OS X: Odds are you could probably improve your posture a bit while you work, and Nekoze is a fun little app that will help you do it. Nekoze takes the form of a cat that keeps an eye on your posture while you sit at your desk. If you slouch too much, the cat will flash a warning on screen, telling you to sit up straight.
Nekoze uses your Mac's camera to keep an eye on you, so you'll have to be ok with that when you install. Once you have it set up, you calibrate your "baseline" posture using the camera, and from there Nekoze sits in your menubar, quietly. The cat icon will change from time to time — don't think that the changing faces means you have to change posture — but if you start to slouch or lean forward, you'll get an audio (which you can disable) and visual reminder to sit up straight while you work.
You can disable the app at any time (which you might want to do if you're reading, eating, or doing something that requires you bend forward), and if you find the app is a little too aggressive, you can dial it back in the settings a bit to find your sweet spot. The app is free, requires OS X 10.7 or higher, and available now in the Mac App Store.