Cyberjusticelab / JusticeAI

JusticeAI (ProceZeus) is a web chat bot that aims to facilitate access to judicial proceedings involving Quebec tenant/landlord law
https://cyberjusticelab.github.io/JusticeAI/docs/rendered/
MIT License
21 stars 16 forks source link

Ask when the tenant paid you last #369

Closed arekmano closed 6 years ago

arekmano commented 6 years ago

Description As a user, I would like the system to ask me when the last time my landlord paid me & take that into consideration for predictions

Scope of Work

Demo requirement

  1. The user is in the nonpayment claim category
  2. The system asks how many months the rent is overdue for
  3. The user answers
  4. The system can correctly classify how many months the user inputted
  5. The system can take the number of months into account when giving a prediction

Acceptance Criteria 1- Mean squared error lower than previous value 2- R2 value +/- 5% of previous value or greater 3- variance +/- 5% of previous value or greater

Vynny commented 6 years ago

This would involve the addition of a date fact type. Duckling can extract dates as a ISO 8601 formatted datetime string. However, date ranges would be significantly harder to extract as they would require a lot more training data to be able to distinguish the start and end entity.

arekmano commented 6 years ago

can we present users with a calendar widget for them to select a date?

brucecaii commented 6 years ago

@arekmano doable, we have the infrastrature for that. Simply returning 'type': 'date' with the response, and the UI can handle it (either user input the date as string or select from the calendar, or keeping both`

Vynny commented 6 years ago

Do we have any facts that expect dates atm? Also are we looking for ranges or single dates?

arekmano commented 6 years ago

this would most likely be single dates. i.e. March 12, 2000 - June 15, 2000, since this is the information that would be extracted from the precedents

brucecaii commented 6 years ago

Why don't we just calculate the range on FE

Vynny commented 6 years ago

Has any progress been made on this? Do we have the ability to use date facts with the ML service?

Vynny commented 6 years ago

Apparently this was implemented on the ML side as part of #399.

According to @Samuel-Campbell, the "tenant_not_paid_lease_timespan" fact requires a timespan in months representing how long the tenant hasn't paid rent for.

naregeff commented 6 years ago

it asks the right questions. 👍