All Projects → dmi3coder → behaiv-java

dmi3coder / behaiv-java

Licence: Apache-2.0 license
User Behavior Prediction for everyone

Programming Languages

java
68154 projects - #9 most used programming language
shell
77523 projects

Projects that are alternatives of or similar to behaiv-java

WellBehavedFX
Composable event handlers and skin scaffolding for JavaFX controls.
Stars: ✭ 52 (+333.33%)
Mutual labels:  behavior
timemachines
Predict time-series with one line of code.
Stars: ✭ 342 (+2750%)
Mutual labels:  prediction
Sales-Prediction
In depth analysis and forecasting of product sales based on the items, stores, transaction and other dependent variables like holidays and oil prices.
Stars: ✭ 56 (+366.67%)
Mutual labels:  prediction
stock-price-prediction
A practice project for machine learning and stop price prediction
Stars: ✭ 19 (+58.33%)
Mutual labels:  prediction
behavior-trait
Allows handling events via inline declared methods, which can be added by traits
Stars: ✭ 18 (+50%)
Mutual labels:  behavior
Recurrent-Neural-Network-for-BitCoin-price-prediction
Recurrent Neural Network (LSTM) by using TensorFlow and Keras in Python for BitCoin price prediction
Stars: ✭ 53 (+341.67%)
Mutual labels:  prediction
joineRML
R package for fitting joint models to time-to-event data and multivariate longitudinal data
Stars: ✭ 24 (+100%)
Mutual labels:  prediction
verif
Software for verifying weather forecasts
Stars: ✭ 70 (+483.33%)
Mutual labels:  prediction
sentometrics
An integrated framework in R for textual sentiment time series aggregation and prediction
Stars: ✭ 77 (+541.67%)
Mutual labels:  prediction
GA-BP
基于遗传算法的BP网络设计,应用背景为交通流量的预测
Stars: ✭ 102 (+750%)
Mutual labels:  prediction
prediction
Tidy, Type-Safe 'prediction()' Methods
Stars: ✭ 86 (+616.67%)
Mutual labels:  prediction
gridpp
Software to post-process gridded weather forecasts
Stars: ✭ 33 (+175%)
Mutual labels:  prediction
AmapLike
【高仿】高德地图 包含定位、搜索、路径规划等功能 map bottomsheet
Stars: ✭ 51 (+325%)
Mutual labels:  behavior
forecastVeg
A Machine Learning Approach to Forecasting Remotely Sensed Vegetation Health in Python
Stars: ✭ 44 (+266.67%)
Mutual labels:  prediction
PyDREAM
Python Implementation of Decay Replay Mining (DREAM)
Stars: ✭ 22 (+83.33%)
Mutual labels:  prediction
cnn age gender
Age and Gender prediction using Keras
Stars: ✭ 58 (+383.33%)
Mutual labels:  prediction
DeepMove
Codes for WWW'18 Paper-DeepMove: Predicting Human Mobility with Attentional Recurrent Network
Stars: ✭ 120 (+900%)
Mutual labels:  prediction
ltt-linux-challenge-issues
A list of issues Linus and Luke experienced during the LTT Linux Daily Driver Challenge
Stars: ✭ 244 (+1933.33%)
Mutual labels:  user-experience
Github-Stars-Predictor
It's a github repo star predictor that tries to predict the stars of any github repository having greater than 100 stars.
Stars: ✭ 34 (+183.33%)
Mutual labels:  prediction
kriptomist
Fundamental cryptocurrency analysis
Stars: ✭ 29 (+141.67%)
Mutual labels:  prediction

Behaiv: User Behavior Prediction for everyone

Behaiv logo

Build Status Coverage Status Java version (Not Java?)

Wow, you've found Behaiv!

Behaiv is a high-level AI tool that helps users to navigate faster through the app, predict what users want to open and take appropriate actions. It was developed with a focus on simplicity of usage. Instead of overwhelming developers with burden of implementation, they only need to write few lines of code.

(Largely inspired by app suggestion in IOS.) Chat example

Getting started: 30 seconds of Behaiv

Main object in Behaiv is, in fact, Behaiv. This is the class that you'll access all the time. To init this class, use a static method Behaiv.with(id) where id is unique value that will be used to restore your data on restart. Behaiv itself is a semi-builder, you don't need to call .build() on it. In upcoming version you'll be able to add more providers any time.

Behaiv behaiv = new Behaiv.Builder("myId")
                .setProvider(new DayTimeProvider())
                // add more providers
                .setStorage(new SimpleStorage(storageDirectoryFile))
                .build();

Done, in order to start capturing user's behavior you need to call next methods:

  • behaiv.startCapturing(predict) in order to start capturing parameters for prediction, it takes optional variable to trigger prediction, if it's false, it won't predict. behaiv.startCapturing() will trigger providers to get all the data needed for prediction.
  • behaiv.registerLabel(label) to attach label or result of parameters. Without it data won't be saved.
  • behaiv.stopCapturing(discard) to save and train network if threshold is reached.
behaiv.startCapturing(true);

//user takes actions
behaiv.registerLabel("Lili_12345 chat")
behaiv.stopCapturing(false)

In order to use prediction, you need to subscribe for them. If behaiv.startCapturing(false) was used, you won't receive prediction

//call this before behaiv.startCapturing(true);
behaiv.subscribe().subscribe(predictionLabel -> {
            // snow prediction on ui
        });

That's all, everything else is handled by Behaiv

For more in-depth tutorial about Behaiv you can checkout:

How to use in Android?

  1. Add dependency as in gradle section
  2. Instantiate Behaiv.Builder object in Application with new Behaiv.Builder(id)
  3. If needed, change Kernel type with .setKernel(Kernel) on a Builder
    1. DummyKernel doesn't do any computations, only suggest most similar result by comparing count of steps(deprecated)
    2. LogisticRegressionKernel uses Logistic Regression to predict actions.
    3. RemoteKernel(not implemented yet), sends data to a API, depending on type of an API receives suggested action or receives model
  4. Provide external factors with Builder.setProvider()such as GPS, Wifi/Bluetooth and headphons info.
    1. Use DayTimeProvider to use time of a day as a features
    2. Use GpsProvider for adding GPS feature into prediction from behaiv-android
    3. Use NetworkProvider for adding Wifi, Bluetooth and Network features into prediction(TODO)
    4. Use HeadsetProvider to include headphones feature into predcition(TODO)
    5. There's more options like Weather and Firebase provides, see more at (TODO)
    6. Use SyntheticProvider to include custom self-made features into prediction (e.g)(TODO, can be implemented easily)
  5. Build Behaiv object by calling Builder.build()
  6. Set threshold after which Behaiv can start suggesting with .setThreshold(int)
  7. Subscribe to predictions in main view e.g MainActivity with behaiv.subscribe().subscribe(predictionLabel -> {})
    1. When prediction received, do a switch/when and show option for user to open
  8. When view is ready for usage by user, call behaiv.startCapturing(true) e.g in onViewCreated() or onCreate()
  9. Find objects to target(e.g chats with user) and when user clicks on target, execute behaiv.registerLabel(String)
  10. At the same time call behaiv.stopCapturing(false) if you're sure that it's correct action.

Model uses "Continuous learning" so it will be trained as long as more features will arrive. To see model in action you need to wait amount of examples reach threshold.

Installation

We use jitpack for now. Beware that in near future we can migrate to different maven repository. Add it in your root build.gradle at the end of repositories:

Latest tag is

Gradle

Step 1. Add the JitPack repository to your build file

allprojects {
	repositories {
		...
		maven { url 'https://jitpack.io' }
	}
}

Step 2. Add the dependency

dependencies {
        implementation 'com.github.dmi3coder:behaiv-java:0.4.10-alpha'
}

Maven

Step 1. Add the JitPack repository to your build file

<repositories>
	<repository>
	    <id>jitpack.io</id>
	    <url>https://jitpack.io</url>
	</repository>
</repositories>

Step 2. Add the dependency

<dependency>
    <groupId>com.github.dmi3coder</groupId>
    <artifactId>behaiv-java</artifactId>
    <version>0.4.10-alpha</version>
</dependency>

Look at more information about build on Jitpack

Want to help?

Behaiv project is really open for help. If you want to help this project to shine, I firstly suggest you to contact me(Dmytro Chaban) by any convinient way e.g email. Second thing is to look at issues. Another way is to spread this project to your friends and contacts, it'll help bring more developers to this project. Reporting issues with project wont hurt also ;)

Looking for other languages?

Behaiv has different implementations(though many of them is in progress of development).

Project Language Version/Arriving date Developed by
behaiv-android(extension) Java dmi3coder
behaiv-swift Swift 2Q 2020 DonauTech & dmi3coder
behaiv-remote-kernel Python(Backend) Release DonauTech & dmi3coder
behaiv-js JavaScript 2Q 2020 DonauTech & dmi3coder
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].