Comments (10)
I have written a class to configure the connection to the WikibaseApi and send queries. Another class should contain methods for the use cases. So I started to implement a mehtod which read out the datatype from the property-id. The API response something like "time" for P569 or "wikibase-item" for P553. Should that be converted in one of the constants from the DatatypeIdValue interface?
from wikidata-toolkit.
Very good. Yes, the strings from the JSON should be represented by the corresponding datatype contents in our code.
Btw, I have also written some basic Web access components for the dump file downloading. These might be handy later on, especially for testing, since there are mock implementations of the interface. So you don't need to focus on the code that fetches string data from the web.
from wikidata-toolkit.
... Maybe interesting for you ;-)
from wikidata-toolkit.
This is very interesting indeed. Should we make use of (parts of) jwbf in out code? Or the other way around (e.g., we already have the Wikidata data model and we will implement the Wikidata JSON serialization)? Our goal is to publish such features as independent Maven modules, so one could pull in parts without pulling in everything. However, I don't know jwbf and its architecture enough to say what could work here.
from wikidata-toolkit.
I'll offer the same points from the referenced issue - if you interested in.
JWBF is only a minimal service layer. You'll get, in your case, shortcuts for login, token handling, encoding and a few simple utils like a APIRequestBuilder (and the offered changes for API integration tests / not wikidata specific)
from wikidata-toolkit.
Via mailing list since this might interest others too:
I did a quick review of the JWBF as it was proposed to be used with
wikidata as well.
Code quality and style is pretty high, everything looks clean and
straight forward. The documentation is very sparse, but it seems to be
worked on.
Depending on how much the MediaWiki API and the Wikidata API differ
from each other it would take some coding effort to get the bots
running with the WDTK. As it looks in the github repository the
developers already tried to play around with this [0].
So I propose the following:
- Including Wikidata access into the JWBF would be fine
- let the JWBF-team handle the inclusion in their code, instead of
including the JWBF into the WDTK - establish communication between the projects and keep both sides
up-to date about recent developments
Reaching the first milestone of the WDTK would be a good time for a
first handshake between the projects.
Sincerly,
Fredo Erxleben
Zitat von Markus Krötzsch [email protected]:
This is very interesting indeed. Should we make use of (parts of)
jwbf in out code? Or the other way around (e.g., we already have the
Wikidata data model and we will implement the Wikidata JSON
serialization)? Our goal is to publish such features as independent
Maven modules, so one could pull in parts without pulling in
everything. However, I don't know jwbf and its architecture enough
to say what could work here.
Reply to this email directly or view it on GitHub:
#11 (comment)
from wikidata-toolkit.
I tried to get the full rundtrip:
- read a wikibase_item info from wikipedia
- get the claim from wikidata by the given wikibase_item
but how can I map the json response to a org.wikidata.wdtk.datamodel.interfaces.Claim?
from wikidata-toolkit.
Hi fer-rum, thanks for your comment ... now I get a JsonException at
eldur/jwbf@82acd0d
from wikidata-toolkit.
Pull request #123 introduces basic capabilities for fetching entity data via the API. It is not currently planned to add write access (JWBF would be much better suited to support the related aspects), but the code might be useful as an example on how to parse JSON data (which works well by now).
from wikidata-toolkit.
Closed by merging #123.
from wikidata-toolkit.
Related Issues (20)
- Support for file uploads HOT 4
- Java modules HOT 6
- IndexOutOfBoundsException when fetching a MediaInfoDocument for a page where structured data has never been edited
- Duplicated statements with the editor.editEntityDocument api HOT 4
- Generic method to create new EntityDocument in WikibaseDataEditor
- Release? HOT 3
- Update Javadocs HOT 1
- Built-in server HOT 6
- Support EDTF HOT 5
- Migrate to <dependencyManagement> to control versions of dependencies HOT 1
- Wrong password gives unclear message HOT 2
- Deserializing a property with `localMedia` datatype fails
- Remove datatype IRI from Wikibase data model implementation HOT 1
- Rename to Wikibase-Toolkit or something else? HOT 2
- OAuth2 support
- Incorrect behavior when converting multiple non-existent filenames to mids
- Support the new Wikibase REST API HOT 2
- Why does wdt use /other/wikidata/ instead of /wikidatawiki/entities/? HOT 3
- WbGetEntitiesAction cannot search media-info for titles containing "-" HOT 3
- Editing API: return revision id on successful edit HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wikidata-toolkit.