korap / rkorapclient Goto Github PK
View Code? Open in Web Editor NEW:chart_with_upwards_trend: R client package to access KorAP's web service API.
License: Other
:chart_with_upwards_trend: R client package to access KorAP's web service API.
License: Other
At the moment, the warnings are formulated rather unspecifically:
682: Response time exceeded
and do not point out the consequences.
The frequency values in the case of timeouts are currently not to be understood as estimates, but as lower bounds - without this being explicit.
Estimating frequencies probably also requires changes in Krill.
In https://github.com/KorAP/RKorAPClient/blob/master/R/KorAPQuery.R#L278-L289 the totalResults
count will be requested for each and every page. While this may be cached in the backend there is no guarantee for it - meaning the number of potential matches may be calculated over and over again.
By adding the cutoff
parameter for all subsequent requests it is ensured that the query will stop once all requested items are found and ignoring total results. See https://github.com/KorAP/Kalamar-Plugin-Export/blob/master/src/main/java/de/ids_mannheim/korap/plkexport/Service.java#L319 .
For base frequency calculations, the unlemmatized token is used.
relates to #6
> demo("recursiveCA")
Error in `slice_head()`:
! `n` must be explicitly named.
ℹ Did you mean `slice_head(n = 50)`?
Run `rlang::last_error()` to see where the error occurred.
As long as server side results sorting is not possible, this should be helpful.
For example, the collocation analysis example in the Readme.md stopped working properly.
Caused by KorAP/Krill#78
The current procedure requires users to generate an access token themselves and in advance in their KorAP OAuth-settings, to copy the token and to store it in their keyring using RKorAPClient::persistAccessToken(kco, accessToken="<token>")
or to pass it with each new("KorAPConnection", accesToken = "<token>")
.
It would be nice if also client applications could initiate the authorization process, using httr::oauth_endpoint()
, httr::oauth_app()
, so that with httr::oauth2.0_token()
the client application can open a browser window where the user is asked to grant KorAP-access to it and which, in the case of success, sends the access token to the client package callback function, listening by default on http://localhost:1410
(as described, e.g. in this R-hub blog post).
I think this is the standard procedure now (exemplified in the httr package for Google, GitHub, Facebook, Vimeo, ...) and we do already have most if not all the functionality provided by Kustvakt, maybe lacking not much more than a page in Kalamar that asks the user to grant the access.
To get an idea, how this should look like, you can try the googldrive package that provides a built-in fallback OAuth app:
library("googledrive")
drive_find(n_max = 30)
After logging in this open the following access request:
We can discuss if we also want have such a built-in fallback app. See the discussion on the security risk here.
error message:
Error in is.na(left) || is.na(right) :
'length = 5' in coercion to 'logical(1)'
Called from: snippet2FreqTable(s, leftContextSize = leftContextSize, rightContextSize = rightContextSize,
collocateFilterRegex = collocateFilterRegex, oldTable = oldTable,
stopwords = stopwords)
this is because of the change:
CHANGES IN R 4.3.0 SIGNIFICANT USER-VISIBLE CHANGES
Calling ‘&&’ or ‘||’ with LHS or (if evaluated) RHS of length greater than one is now always an error, with a report of the form
'length = 4' in coercion to 'logical(1)'
See https://developer.r-project.org/blosxom.cgi/R-devel/NEWS/2023/03/24
It'supported by the API: https://github.com/KorAP/Kustvakt/wiki/Service:-Search-GET
Thanks @ Antonina!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.