F# Exchange 2016
by Mark Gray
F Sharp TV instructor
This years F# Exchange 2016 for me started a few months before the event when I began distributing flyers at my user group in Cambridge. As the date got closer the more excited I became and I was not disappointed.
This years F# Exchange was very busy and the enthusiasm for F# is certainly growing as there are more faces and names that I had never known previously. It was especially encouraging to see a number of young people under the age of 21 that had already gained some useful knowledge and skills which were displayed on the hack day after the exchange. All in all, up take of F# does appear to be on the increase from my experiences at the latest F# Exchange. The excellent keynote presentation, delivered by Phil Trelford, did confirm my suspicions that F# is on the rise. Phil began by recapping over the history of F# and into the languages prior to the point of 1995. He concluded that 1995 was a good year as his mid-life-crisis-sports-car is from 1995 but there were also a plethora of languages around at that time which probably aren’t as cool as his vehicle of choice. Anyway, I digress.
So we started of with Phil’s keynote and the major takeaway from his talk was that in the space (F# can also be seen from space) of 10 years we had a website with 4 blogs posts per and that Caml Special Lite (now called OCaml) is probably not a very good name if you want to promote your programming language 🙂 Also did you know Ruby was the code name for the first VB in 1991, quite apt as they are pretty much the same language. Another interesting fact is that F# is now able to run on over 2.2 BILLION devices including Raspberry PI. Nice eh 🙂
After the keynote from Phil, I went to the talk by the ever energetic Felienne Hermans (https://twitter.com/felienne) who was speaking about her bidding system she created for a card game called Bridge. She described how to break her system apart and distill it into a domain specific language (DSL) to make the expression of the bidding system more human friendly. F# is very good at enabling this to happen due to some one the language constructs such as being able to define your own infix operators. he shares 5 tips for creating a DSL which I will list below. It has definitely given me some ideas to start implementing my own DSL’s. What was good for me personally is that I am currently recording my lessons for FSharp.TV and one of the things I have not seen much while browsing the internet is ideas for modelling the actions within a a game of cards, there are plenty of examples for identifying hand scoring and domain modelling but not very many examples of actually dealing cards, it is harder than it sounds in practice as I discovered.
Felienne also demonstrated some genetic algorithms for incrementally improving using fitness functions with Levenshtein, check it out it is extremely interesting. I really enjoy Felienne’s presentation and had a chat with her afterwards and will definitely be in contact to see if we can collaborate on projects that can complement what we are each doing already. You can watch her talk here.
5 DSL Tips
1) Start small but real – You can incrementally make your DSL have more features
2) Simple language, over perfect model – When given the choice of using a simpler language or a perfect model, opt for the simpler language
3) Pattern => Language opportunity – Identify patterns as it is a chance to make the DSL more powerful.
4) Read aloud once in a while – Or even better ask a friend to read it aloud and see if it makes sense.
5) Know about language features – There is a LOT more to read, see Felienne’s blog to keep up-to-date.
As the F# Exchange conference now has 2 tracks and Isaac Abraham was talking about Cloud tech at the same time as Felienne and as usual his talks are well worth seeing, unfortunately I was having trouble that day in my attempts to clone myself so I will be watching his talk much later on the Skills Matter SkillsCast.
The next talk I went to was the lightning talks delivered by Krzysztof Cieślak, Vicenç Garcia-Altes and Michael Newton. First up was Krzysztof talking about the latest developments with Forge and the great work he has been undertaking for quite some time now including some of his work with Ionide, a project well worth checking out, I have checked out Forge myself and can confirm it is very handy for creating new F# projects via the command line.
Vicenç Garcia-Altes was next up showing us how to extract data from our code repositories using some of the tools available such as the Octokit for accessing data from Github and processing it with F#. With all these tools and data to hand he was able to provide statistics over the number of changes within the git repository and visualise the data with pretty graphs. Ultimately, it can enable us to identify problem areas within our code to refactor and improve and eventually make our code bases much healthier. I was looking forward to seeing Vicenç’s talk as at FSharp.TV we are currently focusing on F# in the Hispanic communities around the world and want to raise positive awareness of the great work coming from these communities and the people that come from them too.
Finally, for the lightning talks was Michael Newton sharing with us a talk about solving real world problem using techniques from high up within the ivory tower. First off he starts with active patterns, what they can do and what they are useful for. He then describes quotations within F#, which are used extensively for Swensen’s assertion library Unquote:. Michael also speedily goes through the concepts of computational expressions, and then the HOPAC library for concurrent programming similar to Concurrent ML, you can find out more about the creator Vesa Karvonen. Finally, Michael briefly goes over some of the type providers that F# has, well worth a look if you have a spare 30 minutes of experimentation time:
The next talk I managed to check out was Mark Seemann’s talk on functional architecture. Mark has a wealth of knowledge and in this talk he describes some of the advantages of using the algebraic type system that F# has as well as a succinct description of the onion architecture otherwise known as ports and adapters. If you want to understand more about functional architecture then be sure to watch his talk here.
Steffen Forkmanns talk was the talk I next attended and can say I am as usual so impressed with the usefulness of Paket. It just works! It saves so much hassle that I would otherwise have to go through with Nuget and I can use it in all my .Net projects. So why Paket? Well, it can take dependencies from Nuget, so it doesn’t replace nugget, it wraps it and provides some safety that Nuget doesn’t have out of the box. But the killer feature (well there are many) for me is the ability to pull in dependencies from Github directly, and now Git repositories in general. The great thing is that you can pull in chunks of code that have been published within the Gists of your own github accounts, or other developers. Now if that doesn’t blow your socks off then nothing will. Check out his talk here.
As I was still encountering difficulties cloning myself here is a link to Tomas Petricek’s talk, you won’t be disappointed as all of Tomas’s talks are very educating, informative and fun, watch the video like I will later here.
Unfortunately, I missed the last talks, because I was getting a 1-to-1 session with Kurt Schelfthout the creator of FsCheck, and absolutely amazing library for making your code much better via property based tests. So I missed the other talks but that is OK, like you I can watch them later on SkillsCast. See the remaining talks by: Evelina Gabasova , Colin Bull, Scott Wlaschin, Anton Tcholakov and Ross and Andrea.
The last official part of the day, other than beer, was the Park Bench hosted by Don Syme. All the experts of the day were invited to speak on what they thought the future would hold in their particular fields of expertise, this was a light hearted and fun session where everyone had a chance to ask questions of each of the panel members, it is well worth a listen if you want to get the inside opinion of where F# is likely to be headed.
All-in-all, it was a great F# Exchange followed by a day of hacking, where I was working through some of the problems on Project Rosalind, find out more here.:
Thanks for reading, Mark @ FSharp.TV
Share this article!
The F# Gazette
Relax and enjoy a curated selection of the best F# content straight to your inbox.
- F# news round-up
- Interviews with industry professionals
- Guest articles from F# experts
- Latest F# jobs
- F# tools, tips, tutorials and more.