{"action":"created","issue":{"url":"https://api.github.com/repos/machinalis/quepy/issues/23","labels_url":"https://api.github.com/repos/machinalis/quepy/issues/23/labels{/name}","comments_url":"https://api.github.com/repos/machinalis/quepy/issues/23/comments","events_url":"https://api.github.com/repos/machinalis/quepy/issues/23/events","html_url":"https://github.com/machinalis/quepy/issues/23","id":103805279,"number":23,"title":"Conflicting queries","user":{"login":"iScienceLuvr","id":5074724,"avatar_url":"https://avatars.githubusercontent.com/u/5074724?v=3","gravatar_id":"","url":"https://api.github.com/users/iScienceLuvr","html_url":"https://github.com/iScienceLuvr","followers_url":"https://api.github.com/users/iScienceLuvr/followers","following_url":"https://api.github.com/users/iScienceLuvr/following{/other_user}","gists_url":"https://api.github.com/users/iScienceLuvr/gists{/gist_id}","starred_url":"https://api.github.com/users/iScienceLuvr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iScienceLuvr/subscriptions","organizations_url":"https://api.github.com/users/iScienceLuvr/orgs","repos_url":"https://api.github.com/users/iScienceLuvr/repos","events_url":"https://api.github.com/users/iScienceLuvr/events{/privacy}","received_events_url":"https://api.github.com/users/iScienceLuvr/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-08-28T22:23:57Z","updated_at":"2015-09-21T21:08:58Z","closed_at":null,"body":"I have been adding functions to, for example, ask the release date of a song. However, there are TWO other functions for this, except for different domains, movies and TV shows. How can we deal with this? Can you add some function that can determine whether the movies query yields no results, so try the TV show query, then the song query? Or is there a way to show all query results?"},"comment":{"url":"https://api.github.com/repos/machinalis/quepy/issues/comments/142108834","html_url":"https://github.com/machinalis/quepy/issues/23#issuecomment-142108834","issue_url":"https://api.github.com/repos/machinalis/quepy/issues/23","id":142108834,"user":{"login":"rafacarrascosa","id":1807764,"avatar_url":"https://avatars.githubusercontent.com/u/1807764?v=3","gravatar_id":"","url":"https://api.github.com/users/rafacarrascosa","html_url":"https://github.com/rafacarrascosa","followers_url":"https://api.github.com/users/rafacarrascosa/followers","following_url":"https://api.github.com/users/rafacarrascosa/following{/other_user}","gists_url":"https://api.github.com/users/rafacarrascosa/gists{/gist_id}","starred_url":"https://api.github.com/users/rafacarrascosa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rafacarrascosa/subscriptions","organizations_url":"https://api.github.com/users/rafacarrascosa/orgs","repos_url":"https://api.github.com/users/rafacarrascosa/repos","events_url":"https://api.github.com/users/rafacarrascosa/events{/privacy}","received_events_url":"https://api.github.com/users/rafacarrascosa/received_events","type":"User","site_admin":false},"created_at":"2015-09-21T21:08:58Z","updated_at":"2015-09-21T21:08:58Z","body":"Kind of...\r\n\r\nFor `get_queries`: You have [the docstrings](https://github.com/machinalis/quepy/blob/develop/quepy/quepyapp.py#L110) and a use case for it's sister function `get_query` [on main.py](https://github.com/machinalis/quepy/blob/develop/examples/dbpedia/main.py#L185).\r\n\r\nFor `weight`: It's not documented, but is simple to use:\r\n\r\n\r\n    class FoundationQuestion(QuestionTemplate):\r\n        \"\"\"\r\n        Regex for questions about the creation of a band.\r\n        Ex: \"When was Pink Floyd founded?\"\r\n            \"When was Korn formed?\"\r\n        \"\"\"\r\n\r\n        weight = 1.5  # By default is 1, so this template is used before all others\r\n\r\n        regex = Pos(\"WRB\") + Lemma(\"be\") + Band() + \\\r\n            (Lemma(\"form\") | Lemma(\"found\")) + Question(Pos(\".\"))\r\n\r\n        def interpret(self, match):\r\n            active_years = ActiveYears(match.band)\r\n            return active_years, \"literal\"\r\n\r\nYou can add `weight` as shown above, if you don't it will be `1` by default."}}