Simple demo apps
Below are a few sample apps in a variety of languages, generally inspired by tech tasks or just quick self-learning exercises for new languages. These were usually developed in hours so are far from perfect, but they may give you some idea of how I approach engineering applications. They also use quite a bit of AI for development, and I’ve tried to mention in the commit history how I’ve tried to guide the AI towards producing decent code, often by giving it hand written examples.
Haskell
Weather Server
This is a Haskell based API which allows a client to ask for the weather at a specific location, using a combination of a variety of location descriptors, including latitude, longitude, city name and airport code. It then hits any open weather API it knows about which it can based on the info the user has provided (e.g. if an airport code is not provided the Aviation downstream endpoint can not be used) and returns the mean/median temperature if one succeeds. This demonstrates:
- The use of
servant-serverto define and serve an API,servant-clientto use and test an API,servant-openapi3to generate OpenAPI JSON from a defined API automatically, andservant-swagger-uito produce a documentation and test webpage, again, using the defined API. - The library Autodocodec which ensures that serialisers, deserialisers and documentation is in sync by design (not just tests), as one common definition defines all three. I have actually contributed to this library.
- Both parallel and error tolerant IO. The API attempts to connect with all downstream servers with a timeout, and gracefully continues despite failures in some of the downstream APIs.
This is also a demonstration of my use of AI (I’m only using the Cursor $20 unlimited plan here). I have as much as possible attempted to make the git commit history a discussion about how I am using and guiding the AI, including manually writing examples for the AI to follow and directing the AI towards stronger types to help the compiler ensure that future AI generated code is correct.
Whilst the use of agentic AI is new, currently I believe it can be a significant productivity increase but it still requires plenty of guardrails and guidance for non-trivial projects. The Readme.md in the repository discusses that further.
Elixir
Weather Command Line App
This is a simplified version of the above weather server in Elixir, in that it’s just a command line app that pings one downstream API. It’s just a demo for myself to learn some Elixir. Again it’s developed largely using AI, but I have cleaned up and directed the AI to produce more strongly typed code, much like the Haskell version above.
This is the first time I’ve actually written Elixir so I most definitely have plenty to learn!