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

Reporting Duties #7

Closed
benedictws opened this issue Jun 23, 2020 · 3 comments
Closed

Reporting Duties #7

benedictws opened this issue Jun 23, 2020 · 3 comments

Comments

@benedictws
Copy link
Collaborator

benedictws commented Jun 23, 2020

Reporting duties share the same structure as Notification duties, except the action is to report rather than notify. So:

:D4                 a                   odrl:Duty ;
                    nl:creditor         <https://permid.org/1-4295899615> ; # CME
                    odrl:action         [   a                   md:Report ; 
                                            md:actionScope      md:Usage ;
                                        ] .

We can usually add some useful detail on what needs reporting. Often it's a list, or count, of devices or applications. We can add that by constraining the Report action by the unit of count:

:D4                 odrl:action         [   a                   md:Report ; 
                                            md:actionScope      md:Usage ;
                                            odrl:unitOfCount    md:Application ;
                                        ] .
@benedictws
Copy link
Collaborator Author

benedictws commented Jun 23, 2020

The big difference between the notification duty we modeled earlier and standard reporting duties is their periodicity: while notification only need happen once, reporting must be repeated monthly.

We can express that by adding a time interval after which the duty "resets" and needs to be fulfilled again:

:D4                 odrl:timeInterval   [   a                   time:ProperInterval ;
                                            time:hasXSDDuration "P1M"^^xsd:duration 
                                        ] .

You only need to report once within this time interval, so we can set the "count" attribute in the action to one. Our duty now looks so:

:D4                 a                   odrl:Duty ;
                    nl:creditor         <https://permid.org/1-4295899615> ; # CME
                    odrl:timeInterval   [   a                   time:ProperInterval ;
                                            time:hasXSDDuration "P1M"^^xsd:duration 
                                        ] ;
                    odrl:action         [   a                   md:Report ; 
                                            md:actionScope      md:Usage ;
                                            odrl:unitOfCount    md:Application ;
                                            odrl:count          "1"^^xsd:int
                                        ] .

@benedictws
Copy link
Collaborator Author

Often, reporting (like payments) can be done one month in arrears. We can model this by adding a deadline delta that provides a grace period for the duty to be fulfilled before it is set to the violated state. The final duty looks so:

:D4                 a                   odrl:Duty ;
                    nl:creditor         <https://permid.org/1-4295899615> ; # CME
                    nl:hasDeadlineDelta [   a                   time:ProperInterval ;
                                            time:hasXSDDuration "P1M"^^xsd:duration
                                        ] ;
                    odrl:timeInterval   [   a                   time:ProperInterval ;
                                            time:hasXSDDuration "P1M"^^xsd:duration 
                                        ] ;
                    odrl:action         [   a                   md:Report ; 
                                            md:actionScope      md:Usage ;
                                            odrl:unitOfCount    md:Application ;
                                            odrl:count          "1"^^xsd:int
                                        ] .

@benedictws
Copy link
Collaborator Author

For those interested in reading further about the possible states of rules, this paper is very useful: https://people.lu.usi.ch/fornaran/AIComm2019/AIComm32(2019)_Fornara.pdf

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

No branches or pull requests

1 participant