-
Notifications
You must be signed in to change notification settings - Fork 2
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
Adapt parallel reader endpoint #25
Comments
DDN: do we serve up the alignment together? A better approach would be to decouple the serving up of both languages separately and also the alignment itself separately. |
Notes from our discussion:
First pass at a spec:
{
"metadata": {
"self_url": "/<text-identifier-1>/alignment/<text-identifier-2>/<range>/",
"refs_url": "/<text-identifier-1>:<range>/",
"refs": {
"start": "1.1",
"end": "1.7",
},
},
"chunks": [
{
"metadata": {
"id": 123456,
"self_url": "/<text-identifier-1>/alignment/<text-identifier-2>/by-id/<id>/",
},
"items": [
{
"metadata": {
"self_url": "/<text-identifier-1>:<range>/",
},
"text_html": "",
"refs": {
"start": "1.1",
"end": "1.7",
},
},
{
"metadata": {},
"text_html": "",
"refs": {}
}
]
}
]
} |
EndpointsI've made the first pass with the following endpoints: Alignment by reference
Retrieves the alignment based on the provided reference. Returns 404 if the reference is not valid Alignment by offset
Paginates through alignment milestones. Supports Alignment by offset from reference
Redirects to "Alignment by offset" at the first offset where the milestone contains the passage (e.g. https://readhomer-dev-api.herokuapp.com/urn:cts:greekLit:tlg0012.tlg001.perseus-grc2/alignment/eng/paginate/?offset=985&limit=10) I though this could be a useful shortcut to start pagination without having to work out what the offset is for a particular reference. Alignment milestone detail
A detail view for an alignment milestone by its particular milestone id. Same as the milestones returned in Gotchas hit along the way
TODOs
|
Add-ons
Future
|
replace HOMER PARALLEL READER with one using GRC's translations and which is driven by the HOMER REFERENCE INPUT.
The text was updated successfully, but these errors were encountered: