Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Service "Consumer Price Index's Change per Month" created #5

Open
8 tasks
SigritSiht opened this issue Mar 8, 2023 · 2 comments · May be fixed by #18
Open
8 tasks

Service "Consumer Price Index's Change per Month" created #5

SigritSiht opened this issue Mar 8, 2023 · 2 comments · May be fixed by #18

Comments

@SigritSiht
Copy link

SigritSiht commented Mar 8, 2023

AS a Chatbot trainer
I WANT TO write needed DSL files
SO THAT end users could consume the Service via Bürokratt

Acceptance Criteria

  • Get year and month from the user (later)
  • Consumer Price Index's Change per Month queried for Consumer price index, change compared to same month of previous year, % and Consumer price index, change compared to previous month, %.
  • If current month index is null, then take first available month's index's change
  • Service intent "sa_thi"
  • Service answer "Tarbijahinnaindeksi muutus võrreldes eelmise aasta sama kuuga on {var 1}%. Tarbijahinnaindeksi muutus võrreldes eelmise kuuga on {var 2}%"
  • If data for current month is non-existent (null), send an error message to user: "Antud kuu kohta andmeid veel avalikustatud ei ole. Viimased andmed avalikustati month year, mil tarbijahinnaindeksi muutus võrreldes eelmise aasta sama kuuga on {var 1}%. Tarbijahinnaindeksi muutus võrreldes sellele eelneva kuuga on {var 2}%" @KasparMinn updated utterance
  • Model containing this Service trained.

Output

https://andmed.stat.ee/api/v1/en/stat/IA021

{
  "query": [
    {
      "code": "Aasta",
      "selection": {
        "filter": "item",
        "values": [
          "2023"
        ]
      }
    }
  ],
  "response": {
    "format": "json-stat2"
  }
}

Response

 "class": "dataset",
    "label": "IA021: TARBIJAHINNAINDEKSI MUUTUS | Näitaja, Aasta ning Kuu",
    "source": "Statistikaamet",
    "updated": "2020-10-06T05:00:00Z",
    "id": [
        "Näitaja",
        "Aasta",
        "Kuu"
    ],
    "size": [
        2,
        1,
        12
    ],
    "dimension": {
        "Näitaja": {
            "extension": {
                "show": "value"
            },
            "label": "Näitaja",
            "category": {
                "index": {
                    "1": 0,
                    "2": 1
                },
                "label": {
                    "1": "Tarbijahinnaindeksi muutus võrreldes eelmise aasta sama kuuga, %",
                    "2": "Tarbijahinnaindeksi muutus võrreldes eelmise kuuga, %"
                }
            }
        },
        "Aasta": {
            "extension": {
                "show": "value"
            },
            "label": "Aasta",
            "category": {
                "index": {
                    "2023": 0
                },
                "label": {
                    "2023": "2023"
                }
            }
        },
        "Kuu": {
            "extension": {
                "show": "value"
            },
            "label": "Kuu",
            "category": {
                "index": {
                    "1": 0,
                    "2": 1,
                    "3": 2,
                    "4": 3,
                    "5": 4,
                    "6": 5,
                    "7": 6,
                    "8": 7,
                    "9": 8,
                    "10": 9,
                    "11": 10,
                    "12": 11
                },
                "label": {
                    "1": "Jaanuar",
                    "2": "Veebruar",
                    "3": "Märts",
                    "4": "Aprill",
                    "5": "Mai",
                    "6": "Juuni",
                    "7": "Juuli",
                    "8": "August",
                    "9": "September",
                    "10": "Oktoober",
                    "11": "November",
                    "12": "Detsember"
                }
            }
        }
    },
    "value": [
        18.6,
        17.6,
        null,
        null,
        null,
        null,
        null,
        null,
        null,
        null,
        null,
        null,
        0.8,
        0.6,
        null,
        null,
        null,
        null,
        null,
        null,
        null,
        null,
        null,
        null
    ],
    "status": {
        "2": "..",
        "3": "..",
        "4": "..",
        "5": "..",
        "6": "..",
        "7": "..",
        "8": "..",
        "9": "..",
        "10": "..",
        "11": "..",
        "14": "..",
        "15": "..",
        "16": "..",
        "17": "..",
        "18": "..",
        "19": "..",
        "20": "..",
        "21": "..",
        "22": "..",
        "23": ".."
    },
    "role": {
        "time": [
            "Aasta"
        ]
    },
    "version": "2.0",
    "extension": {
        "px": {
            "tableid": "IA021",
            "decimals": 1
        }
    }
}
@SigritSiht SigritSiht transferred this issue from buerokratt/Service-Module Jun 12, 2023
@SigritSiht SigritSiht moved this from In Progress to Blocked in Common Services Jun 13, 2023
@turnerrainer
Copy link
Contributor

This issue was blocked because of a Ruuter bug described in buerokratt/Ruuter#167 (fixed now, can proceed).

@KasparMinn KasparMinn linked a pull request Jun 22, 2023 that will close this issue
@SigritSiht SigritSiht linked a pull request Jun 22, 2023 that will close this issue
@SigritSiht SigritSiht moved this from Blocked to Acceptance Testing (AT) in Common Services Jun 22, 2023
@SigritSiht SigritSiht moved this from Acceptance Testing (AT) to Done in Common Services Jun 28, 2023
@RiinaLi
Copy link
Collaborator

RiinaLi commented Oct 4, 2024

End Client is able to get information about Consumer Price Index's Change per Month
#95

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

4 participants