headzoo/prediction-io-bundle 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

headzoo/prediction-io-bundle

最新稳定版本:1.1.3

Composer 安装命令:

composer require headzoo/prediction-io-bundle

包简介

Endroid PredictionIO Bundle for Symfony

README 文档

README

By endroid

Build Status Latest Stable Version Total Downloads

This bundle provides easy integration with PredictionIO. PredictionIO is an open source machine learning server for software developers to create predictive features, such as personalization, recommendation and content discovery. Based on Apache Mahout scalable machine learning libraries.

The bundle registers the Endroid PredictionIO client as a service in your Symfony project. This client can then be used to register actions between users and items and to retrieve recommendations provided by any PredictionIO server. Applications range from showing recommended products in a web shop to discovering relevant experts in a social collaboration network.

knpbundles.com

Requirements

Installation

Add in your composer.json

{
    "require": {
        "endroid/prediction-io-bundle": "dev-master"
    }
}

Install the bundle

$ curl -s http://getcomposer.org/installer | php
$ php composer.phar update endroid/prediction-io-bundle

Composer will install the bundle to your project's vendor/endroid directory.

Enable the bundle via the kernel

<?php
// app/AppKernel.php

public function registerBundles()
{
    $bundles = array(
        // ...
        new Endroid\Bundle\PredictionIOBundle\EndroidPredictionIOBundle(),
    );
}

Configuration

config.yml

endroid_prediction_io:
    app_key: "Your app key"
    api_url: "http://localhost:8000" // optional

Usage

After installation and configuration, the service can be directly referenced from within your controllers.

<?php
public function recommendAction()
{
    $client = $this->get('endroid.prediction_io');

    // populate
    $client->createUser($userId);
    $client->createItem($itemId);
    $client->recordAction($userId, $itemId, 'view');

    // get recommendations and similar items
    $recommendations = $client->getRecommendations($userId, $engine, $count);
    $similarItems = $client->getSimilarItems($itemId, $engine, $count);
}

Vagrant box

PredictionIO provides a Vagrant box containing an out-of-the-box PredictionIO server.

License

This bundle is under the MIT license. For the full copyright and license information, please view the LICENSE file that was distributed with this source code.

统计信息

  • 总下载量: 2.66k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 4
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2014-11-07