Alexis' loghttp://blog.notmyidea.org2011-10-15T00:00:00+02:00How are you handling your shared expenses?2011-10-15T00:00:00+02:00Alexis Métaireautag:blog.notmyidea.org,2011-10-15:/how-are-you-handling-your-shared-expenses.html/<p><strong>TL;DR:</strong> We're kick-starting a new application to manage your shared
expenses. Have a look at <a class="reference external" href="http://ihatemoney.notmyidea.org">http://ihatemoney.notmyidea.org</a></p>
<p>As a student, I lived in a lot of different locations, and the majority of them
had something in common: I lived with others. It usually was a great experience
(and I think I will continue to live with others). Most of the time, we had to
spend some time each month to compute who had to pay what to the others.</p>
<p>I wanted to create a pet project using flask, so I wrote a little
(~150 lines) flask application to handle this. It worked out pretty well for my
housemates and me, and as we had to move into different locations,
one of them asked me if he could continue to use it for the year to come.</p>
<p>I said yes and gave it some more thoughts: We probably aren't the only ones
interested by such kind of software. I decided to extend a bit more the
software to have a concept of projects and persons (the list of persons was
hard-coded in the first time, boooh!).</p>
<p>I then discussed with a friend of mine, who was excited about it and wanted to learn
python. Great! That's a really nice way to get started. Some more friends were also
interested in it and contributed some features and provided feedback (thanks
<a class="reference external" href="http://www.sneakernet.fr/">Arnaud</a> and Quentin!)</p>
<p>Since that, the project now support multiple languages and provides a REST API
(android and iphone apps in the tubes!), into other things.
There is no need to register for an account or whatnot, just enter a project name,
a secret code and a contact email, invite friends and that's it (this was inspired by
doodle)!</p>
<img alt="images/ihatemoney.png" src="images/ihatemoney.png" />
<p>You can try the project at <a class="reference external" href="http://ihatemoney.notmyidea.org">http://ihatemoney.notmyidea.org</a> for now, and the
code lives at <a class="reference external" href="https://github.com/spiral-project/ihatemoney/">https://github.com/spiral-project/ihatemoney/</a>.</p>
<div class="section" id="features">
<h2>Features</h2>
<p>In the wild, currently, there already are some implementations of this shared
budget manager thing. The fact is that most of them are either hard to use, with
a too much fancy design or simply trying to do too much things at once.</p>
<p>No, I don't want my budget manager to make my shopping list, or to run a blog for
me, thanks. I want it to let me focus on something else. Keep out of my way.</p>
<div class="section" id="no-user-registration">
<h3>No user registration</h3>
<p>You don't need to register an account on the website to start using it. You
just have to create a project, set a secret code for it, and give both the url and
the code to the people you want to share it with (or the website can poke
them for you).</p>
</div>
<div class="section" id="keeping-things-simple">
<h3>Keeping things simple</h3>
<p>"Keep It Simple, Stupid" really matches our philosophy here: you want to add a
bill? Okay. Just do it. You just have to enter who paid, for who, how much,
and a description, like you would have done when you're back from the
farmer's market on raw paper.</p>
</div>
<div class="section" id="no-categories">
<h3>No categories</h3>
<p>Some people like to organise their stuff into different "categories":
leisure, work, eating, etc. That's not something I want (at least to begin
with).</p>
<p>I want things to be simple. Got that? Great. Just add your bills!</p>
</div>
<div class="section" id="balance">
<h3>Balance</h3>
<p>One of the most useful thing is to know what's your "balance" compared to
others. In other words, if you're negative, you owe money, if you're positive,
you have to receive money. This allows you to dispatch who has to pay for the
next thing, in order to re-equilibrate the balance.</p>
<p>Additionally, the system is able to compute for you who has to give how
much to who, in order to reduce the number of transactions needed to restore
the balance.</p>
</div>
<div class="section" id="api">
<h3>API</h3>
<p>All of what's possible to do with the standard web interface is also available
through a REST API. I developed a simple REST toolkit for flask for this (and
I should release it!).</p>
</div>
</div>
<div class="section" id="interested">
<h2>Interested?</h2>
<p>This project is open source. All of us like to share what we are doing and
would be happy to work with new people and implement new ideas. If you have
a nice idea about this, if you want to tweak it or to fill bugs. Don't hesitate
a second! The project lives at <a class="reference external" href="http://github.com/spiral-project/ihatemoney/">http://github.com/spiral-project/ihatemoney/</a></p>
</div>
Using dbpedia to get languages influences2011-08-16T00:00:00+02:00Alexis Métaireautag:blog.notmyidea.org,2011-08-16:/using-dbpedia-to-get-languages-influences.html/<p>While browsing the Python's wikipedia page, I found information about the languages
influenced by python, and the languages that influenced python itself.</p>
<p>Well, that's kind of interesting to know which languages influenced others,
it could even be more interesting to have an overview of the connexion between
them, keeping python as the main focus.</p>
<p>This information is available on the wikipedia page, but not in a really
exploitable format. Hopefully, this information is provided into the
information box present on the majority of wikipedia pages. And… guess what?
there is project with the goal to scrap and index all this information in
a more queriable way, using the semantic web technologies.</p>
<p>Well, you may have guessed it, the project in question in dbpedia, and exposes
information in the form of RDF triples, which are way more easy to work with
than simple HTML.</p>
<p>For instance, let's take the page about python:
<a class="reference external" href="http://dbpedia.org/page/Python_%28programming_language%29">http://dbpedia.org/page/Python_%28programming_language%29</a></p>
<p>The interesting properties here are "Influenced" and "InfluencedBy", which
allows us to get a list of languages. Unfortunately, they are not really using
all the power of the Semantic Web here, and the list is actually a string with
coma separated values in it.</p>
<p>Anyway, we can use a simple rule: All wikipedia pages of programming languages
are either named after the name of the language itself, or suffixed with "(
programming language)", which is the case for python.</p>
<p>So I've built <a class="reference external" href="https://github.com/ametaireau/experiments/blob/master/influences/get_influences.py">a tiny script to extract the information from dbpedia</a> and transform them into a shiny graph using graphviz.</p>
<p>After a nice:</p>
<pre class="literal-block">
$ python get_influences.py python dot | dot -Tpng > influences.png
</pre>
<p>The result is the following graph (<a class="reference external" href="http://files.lolnet.org/alexis/influences.png">see it directly here</a>)</p>
<img alt="http://files.lolnet.org/alexis/influences.png" src="http://files.lolnet.org/alexis/influences.png" style="width: 800px;" />
<p>While reading this diagram, keep in mind that it is a) not listing all the
languages and b) keeping a python perspective.</p>
<p>This means that you can trust the scheme by following the arrows from python to
something and from something to python, it is not trying to get the matching
between all the languages at the same time to keep stuff readable.</p>
<p>It would certainly be possible to have all the connections between all
languages (and the resulting script would be easier) to do so, but the resulting
graph would probably be way less readable.</p>
<p>You can find the script <a class="reference external" href="https://github.com/ametaireau/experiments">on my github account</a>. Feel free to adapt it for
whatever you want if you feel hackish.</p>