By default, Spring Data Couchbase implements single-bucket configuration. In this default implementation, all POJO (Plain Old Java Object) models/documents will be stored in a single bucket. This is possible, because Couchbase is a NoSQL database which can store schemaless data. To differentiate between type of documents, Spring Data adds _class field that contains the fully-qualified… Read More
Tag: java
Sign Ripple transaction locally using ripple-lib-java
Since rippled 1.1.0 disables public signing by default, we either need to host our own API server or sign Ripple transaction locally. Fortunately, ripple-lib-java gives clue on how to do this in one of its example. Long story short, we can use this simple method to do the signing: import java.math.BigDecimal; import com.ripple.core.types.known.tx.txns.Payment; import com.ripple.core.types.known.tx.signed.SignedTransaction;… Read More
Linear Regression and cross validation in Java using Weka
I stumbled upon a question in the internet about how to make price prediction based on price history in Android. Assuming the history size is quite small (few hundreds) and the attribute is not many (less than 20), I quickly thought that Weka Java API would be one of the easiest way to achieve this…. Read More
Check balance and send Ripple (XRP) using Java
Update: As mentioned in here, since rippled 1.1.0 remote sign API is not allowed by default anymore. If you try to call it on wss://s.altnet.rippletest.net:51233 you will get “Signing is not supported by this server” error. Check this post on how to sign transaction locally using Java Ripple (XRP) provides some options to interact with their… Read More
Training NER model using Stanford Core NLP CRF Classifier
Named-Entity Recognition (NER) is one of the most popular NLP tasks. It’s popular because it produces annotation result that can be used directly (eg. extracting people name from text) or indirectly (eg. extracting feature for classification task). One of the easiest way to do it is by downloading and using latest Stanford Core NLP suite… Read More