Beeminder Forum

Duolingo languages with different base language are hidden when in mobile app we switch the base language.

I use Duolingo to learn Spanish and Italian but from French (as I am a native french speaker)
Of course Duolingo call those languages Espagnol and Italien and it seems that beeminder can’t find them for that reason and believe that I did not start those languages.

Can we do something about it ?

2 Likes

What is your Duolingo username?

Thanks for your reply
My duolingo username is “SattisvarT”

I’m using this website to check my languages -> https://duome.eu/SattisvarT
it seems that the result depends on which language base I am in in the mobile app.
If I am doing a french based lesson the duolingo api returns only languages that I learn from French.
Conversely if I am doing an english based lesson, only languages learned from english are shown.

So I think that for the moment, I have to switch languages before asking beeminder to look at my scores.

Sounds good!

There is still a problem, when beeminder checks my scores and does not find my languages because of the above-mentioned problem, It inserts a 0 in the data, and things gets weird. Back to normal if I delete the zero I presume but that is a bit annoying.

I wonder if that’s something we can handle on our end, actually. Hmm.

IMHO I would just prevent beeminder to insert any data if the language is not found (because mainly there is a check when adding a goal with duolingo that the language exists so it means that the language existed at creation time and the only way to be in the situation where the language is not found when retrieving data is because of that switch case) What do you think ?

I haven’t had my coffee yet, so this is just a thought: but I think it may be important to both keep trying to fetch data later, but also to remind you to switch languages on the site or in the app so that when it checks later that day, Beeminder will be able to get the data.

1 Like

Please have your coffee :slight_smile:
If I understand you well, you suggest that beeminder sends a reminder to switch languages when the retrieval fails ? Sounds good!
On my side as I always do all the languages every day in the same order I will end up with the same language on the app so beeminder will not be able to fetch part of the data. So for me I will split my routine in two, do all the languages based on english first then ask beeminder to fetch data on those languages and next the french based languages and again on completion go to beeminder to force fetching the data. The only one thing is that beeminder should not alter the data on failing the retrieval, which – if I’m not mistaken – happen by adding a 0 as a data point.

1 Like

Can you confirm what happens here:

  1. Do your first set of languages
  2. Make Beeminder update, confirm the data is good
  3. Switch Duolingo to the second set of languages
  4. Make Beeminder update the first set

I would expect Beeminder has 2 datapoints, one that is good, and a new one for the day that is a 0.

1 Like

Hello,

I tried what you suggested.
I have several different effects:

  • On my Arabic lessons beeminder does not see my new xp level on duolingo, whatever language I select
  • On my Italian lessons beeminder has a data line with a 0 that had been automatically added. The graph and the surprisingly high amount of days before derailment shows that beeminder sees a way bigger xp level than what I really have.
1 Like

Hello again,

I dug into duolingo API and I’ve come up with a solution. Please let me know if that would work for the automatic fetching on your side

  • When a goal is created we can retrieve the user_id from the username in duolingo using this API call https://www.duolingo.com/users/sattisvart It provides a big json but there is a field id somewhere. Once retrieved, this should be stored in the beeminder goal along with the username
  • Once you have the id you can call https://www.duolingo.com/2017-06-30/users/<id>?fields=courses where <id> is the previously fetched user_id.
    For instance for me the url would be https://www.duolingo.com/2017-06-30/users/335010648?fields=courses which gives the following json
{
 "courses":[
  {
   "learningLanguage":"ar",
   "crowns":19,
   "xp":1192,
   "id":"DUOLINGO_AR_EN",
   "fromLanguage":"en",
   "title":"Arabic"
  }, 
  {
   "learningLanguage":"de",
   "crowns":14,
   "xp":949,
   "id":"DUOLINGO_DE_FR",
   "fromLanguage":"fr",
   "title":"Allemand"
  },
  ...
 ]
}

There you have all the xp for all the language no matter the fromLanguage. That would prevent the fail on fetching data and you’d never have a 0 as a data line in beeminder goal.

2 Likes

Thanks for doing the research! I’ll let Adam chime in with whether that looks workable in practice.

It’d be a great step forward; I also used to switch base languages in Duolingo, but never as regularly as you do.

For me it was usually because I’d reached the end of their lesson stack in one direction and would invert the languages to do it the other way, or from a different base language altogether. Also, in the early days, they had more courses for learning English than they had for learning the target language, e.g. by claiming to be a Dutch speaker learning English I could actually progress as an English speaker learning Dutch.

2 Likes

Hello,

Just uping the post to see if there is any improvement on your side. While you sort things out I decided to switch my duolingo goals into simple do-more ones and have a home-made script that retrieve the info every day. Let me know if you need me for some tests.

Not yet, I’m behind in our current sprint. This has been entered in
our bug tracker, though! :slight_smile: I’m glad you have something working for
you at the moment.

2 Likes