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

Investigate annotations and decide on annotation format #543

Closed
ilgazer opened this issue Dec 5, 2023 · 1 comment · Fixed by #595
Closed

Investigate annotations and decide on annotation format #543

ilgazer opened this issue Dec 5, 2023 · 1 comment · Fixed by #595
Assignees

Comments

@ilgazer
Copy link
Contributor

ilgazer commented Dec 5, 2023

As per customer requests, we need to be able to annotate requests, needs, actions etc. As a part of this, we will need to decide what annotation fields we will use. The product of this issue will guide the work in #541 and #542

@ilgazer ilgazer self-assigned this Dec 5, 2023
@ilgazer
Copy link
Contributor Author

ilgazer commented Dec 22, 2023

I settled on the following annotation format. The nested selectors allow us to efficiently fetch only the annotations for the resources/needs/warnings we have.

    {
        "@context": "http://www.w3.org/ns/anno.jsonld",
        "id": "http://example.org/anno1",
        "type": "Annotation",
        "bodyValue": "This is no longer true, as we have recently discovered.",
        "target": {
            "source": "http://example.org/page1.html",
            "selector": {
                "type": "XPathSelector",
                "value": "//div[@id=\"Resource1\"]",
                "refinedBy": {
                    "type": "RangeSelector",
                    "startSelector": {"type": "XPathSelector", "value": "/p[1]"},
                    "endSelector": {"type": "XPathSelector", "value": "/p[1]"},
                    "refinedBy": {"type": "TextPositionSelector", "start": 1, "end": 29}
                }
            }
        }
    }

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

Successfully merging a pull request may close this issue.

1 participant