Developers [Social Enterprise] Summit 2012 A1

61
DevelopersSocial EnterpriseSummit 2012 (A-1) CAC Corporation Systems Architect facebook: kohei.kumazawa A-1 ソーシャルデータストリームから垣間見る 今後のエンタープライズアーキテクチャ考 夏サミ2012ハッシュタグ ◆夏サミ全体 #natsumi A-1#natsumiA1

description

Developers [Social Enterprise] Summit 20122012/07/27

Transcript of Developers [Social Enterprise] Summit 2012 A1

Page 1: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

CAC Corporation Systems Architect

facebook: kohei.kumazawa

A-1

ソーシャルデータストリームから垣間見る 今後のエンタープライズアーキテクチャ考

夏サミ2012ハッシュタグ

◆夏サミ全体 #natsumi

【A-1】#natsumiA1

Page 2: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Profile http://www.facebook.com/kohei.kumazawa

職種: Systems Architect

名前: 熊澤公平

1987年 東北大学工学研究科機械工学専攻博士前期課程修了

数値解析

同年 株式会社リクルートに入社

2003年 株式会社シーエーシーに転職

(ネット業界におけるビジネスおよびシステムコンサル)

2003年 東京大学工学部システム創成学科 非常勤講師

~2009年 (Javaプログラミング基礎演習)

2008年 横浜国立大学院工学府 非常勤講師

~2010年 (システムマネージメント)

スパコン(並列処理)の アーキテクチャ

大規模WEBインフラの アーキテクチャ

ビジネスとシステムのアーキテクチャ

Page 3: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

1.デブは伝染する!

デベ

Page 4: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

知っていますか? デブは伝染するって

友人同士の会話

Page 5: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

最近ふとっちゃって….

いやいやそんなことないよ

Page 6: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

最近ふとっちゃって….

いやいやそんなことないよ

Page 7: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

同じくらい

なら….

デブ閾値の増加

普通

Page 8: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

同じくらい

なら….

デブ閾値の増加

普通

Page 9: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

最近ふとっちゃって….

いやいやそんなことないよ

Page 10: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Page 11: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Page 12: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Page 13: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Page 14: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Page 15: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Page 16: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Page 17: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Page 18: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

そして皆、デブになった…..。

Page 19: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

米国、マサチューセッツ州、1万2067人を32年間追跡調査

あなたの親友が肥満になった場合、あなたが肥満になる確率は57%増加

また、兄弟姉妹が肥満になった場合、あなたが肥満になる確率は40%増加

夫婦は、37%増加

片方向のみ友人と思っている場合は、無関係。

丸の大きさがBMI値に比例

黄色が30以上、緑が30未満

都市伝説ではありません

黄色ばっかりに…… http://christakis.med.harvard.edu/

Page 20: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Page 21: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

本日のお題はソーシャルエンタープライズ

企業におけるソーシャルコミュニケーションの活用?

メール、掲示板、グループウエア、昔からコミュニケーションツールはいろいろありますよね。

でも…..、あるだけになっていませんか?

活発ですか? 面白いですか?

Page 22: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

会話の流れを見る

活性化:会話を刺激する

仕組みって?

本日お話したいこと

Page 23: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

2.アクティブなソーシャルって?

Page 24: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Timeline

上から下へ流れていくもの・・・・・?

Page 25: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ソーシャルデータはダイナミックな流れである

London周辺でのtweetの時間推移

ソーシャルデータ → ソーシャルデータストリーム

同時多発で動的なもの

Page 26: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

典型的なソーシャルモニタリングツールといえば

http://www.radian6.com/

Time series analysis(時系列解析)

Page 27: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ソーシャルデータストリームの時系列パターン

4つのパターン

「ソーシャルストリーム・ビジネス Twitter、Facebook、iPhone時代の消費者を巻き込むビジネスの新ルール」より

http://www.amazon.co.jp/gp/product/4844328956/

閲覧数

時間

クォリティパターン

パルス

パターン

複数の

組み合わせ

ブレーク

パターン

F=80~100% F=20~80%

F=0~20%

Page 28: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

時系列パターンとアクティブ度

再生数

時間

パルスパターン

平均CTR: 0.01%

クオリティパターン

平均CTR: 0.6%

ブレークパターン

平均CTR: 2.3% 複数の組み合わせ

これが

重要

Page 29: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

3.アクティブなソーシャルの構造?

Page 30: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ソーシャルデータストリームにはグラフ構造がある

Page 31: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

構造を見てみよう: グラフ分析ツール

Tool

Pajek http://vlado.fmf.uni-lj.si/pub/networks/pajek/

Graphviz http://www.graphviz.org

NetDraw https://sites.google.com/site/netdrawsoftware/

Graphi http://oss.infoscience.co.jp/gephi/gephi.org/index.html

NodeXL http://nodexl.codeplex.com/

R

sna

network graph

igraph

inetowork

Page 32: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ソーシャルデータストリームの構造例

“ヒッグス”が含まれているtweetの伝播の様子 2012/7/4 17-18

NHK科学文化部

LHC アトラス実験

日本グループ

Page 33: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ソーシャルデータストリームの構造例

“ヒッグス”が含まれているtweetの伝播の様子 2012/7/4 17:28-17:43

Page 34: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

伝播パターン

花火パターン 数珠つなぎ

パターン

Page 35: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

伝播パターン

花火パターン 数珠つなぎ

パターン

時間差がある

議論が持続する

瞬間的に広がる

持続しない

Page 36: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

伝播パターン: ブレークパターン=数珠つなぎパターン

0

20

40

60

80

100

120

“ヒッグス”が含まれているtweetの伝播の様子 2012/7/7 0:00-16:00

F=10.7%

UTC

時間差がある

議論が持続し、

盛り上がりがある

Page 37: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

4.アクティブなソーシャルに仕向けられれば

Page 38: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ハッシュタグ:コミュニティ同志をつなげる

#devsum #rubyjp

デブサミに来ています! #devsum

デブサミ面白いです! #devsum

RT デブサミ面白いです!@aaa ありがとうございます! #devsum

#rubyjp

媒介者になる

(媒介中心性) (Betweenness centrality)

Page 39: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

例)浦安水情報

#urayasu_water #urayasu

浦安の水情報をオープンしました #urayasu_water

拡散希望 浦安水情報 #urayasu_water

RT ありがとうございま

す! 拡散希望 浦安水情報 #urayasu_water

#urayasu

小さなコミュニティ 大きなコミュニティ

Page 40: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

例)#urayasu → #urayasu_water

0

20000

40000

60000

80000

100000

120000

140000

160000

180000

0

100

200

300

400

500

600

03月

12日

-…

03月

12日

-…

03月

12日

-…

03月

12日

-…

03月

12日

-…

03月

12日

-…

03月

12日

-…

03月

12日

-…

03月

12日

-…

03月

12日

-…

03月

12日

-…

03月

12日

-…

03月

13日

-…

03月

13日

-…

03月

13日

-…

03月

13日

-…

03月

13日

-…

03月

13日

-…

03月

13日

-…

03月

13日

-…

03月

13日

-…

03月

13日

-…

03月

13日

-…

03月

13日

-…

03月

14日

-…

03月

14日

-…

03月

14日

-…

03月

14日

-…

03月

14日

-…

03月

14日

-…

03月

14日

-…

03月

14日

-…

03月

14日

-…

03月

14日

-…

03月

14日

-…

03月

14日

-…

03月

15日

-…

03月

15日

-…

03月

15日

-…

03月

15日

-…

03月

15日

-…

03月

15日

-…

03月

15日

-…

03月

15日

-…

03月

15日

-…

03月

15日

-…

03月

15日

-…

03月

15日

-…

#urayasu+#urayasu_water

#urayasu_water単独

Gross Audience フォロワー数

#urayasuからの流入

Page 41: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

例)#urayasu → #urayasu_water

初期(3/12-3/13 8:00):シンプルな構造 翌々日:複雑な構造

Page 42: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

例)ブレークパターンに

0

10

20

30

40

50

60

7003月

12日

-00時

03月

12日

-04時

03月

12日

-08時

03月

12日

-12時

03月

12日

-16時

03月

12日

-20時

03月

13日

-00時

03月

13日

-04時

03月

13日

-08時

03月

13日

-12時

03月

13日

-16時

03月

13日

-20時

03月

14日

-00時

03月

14日

-04時

03月

14日

-08時

03月

14日

-12時

03月

14日

-16時

03月

14日

-20時

03月

15日

-00時

03月

15日

-04時

03月

15日

-08時

03月

15日

-12時

03月

15日

-16時

03月

15日

-20時

03月

16日

-00時

03月

16日

-04時

03月

16日

-08時

03月

16日

-12時

03月

16日

-16時

03月

16日

-20時

03月

17日

-00時

03月

17日

-04時

03月

17日

-08時

03月

17日

-12時

03月

17日

-16時

03月

17日

-20時

03月

18日

-00時

03月

18日

-04時

03月

18日

-08時

03月

18日

-12時

03月

18日

-16時

03月

18日

-20時

03月

19日

-00時

03月

19日

-04時

03月

19日

-08時

03月

19日

-12時

Page 43: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

5.アーキテクチャ考: データからストリームへ

Page 44: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ソーシャルコミュニケーションの活性化

ソーシャルデータストリームは生きている

→ 常に見ておかなければならない

Page 45: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ストリームデータ管理・CEP

ソーシャルデータのすべてが必要なのだろうか?

分析が終わっている時には流れは変わっていますよね

変化した時にアラートがでれば十分なのでは?

Page 46: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

DSMS

ストリームデータ管理・CEP

DATA

DATA

DATA

DATA

DATA

DATA

DATA

DATA Query

DATA

DATA

DATA

DATA

DATA

DBMS

Event

Query

Page 47: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ソーシャルデータ → ソーシャルデータストリーム

Social data

database

tweet

data

Analytics Action

Action

CEP

tweet

stream

Monitor Action

Action

貯めて分析し、アクション

流れの変化を見つけ、アクション

Page 48: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

事例)Streambase

http://www.streambase.com

twitterのtweetを

入力ストリームとして定義

検知したいことを定義

モニターにアラートを表示

全体を設計し、組み上げていく

Integration approach

必要な一部分のみを作り、逐次組み上げていく

Synthetic approach

Page 49: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

大量データにも対応

Jubatus http://research.preferred.jp/2011/10/jubatus/

S4 http://incubator.apache.org/s4/

C-MR http://cs.brown.edu/~backman/cmr.html

MapReduce Online http://www.usenix.org/event/nsdi10/tech/full_papers/condie.pdf

DEDUCE http://www.edbt.org/Proceedings/2010-Lausanne/edbt/papers/p0657-Kumar.pdf

Big Data

Small Data

Real time

Big Processing

Stored

Legacy

MapReduce

DSMS,CEP

S4, C-MR, storm

MapReduce Online, jubat.us

DEDUCE

Esper

Streambase

Oracle, WS

Sybase/SAP

Distributed

Stream Management

BigDataも対応可能に!

Big Analytics

Page 50: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Big Analytics :

分散オンライン解析 → どんどん提案が!

単純な分散は頻繁な更新が発生してしまう

各サーバー内で計算されるモデルをどうやって緩やかに同期するか

例)グラフィカルモデルの分散処理

Residual Splash for Optimally Parallelizing Belief Propagation(2009) http://www.cs.cmu.edu/~ylow/paraml_aistats2009.pdf

On Dense Pattern Mining in Graph Streams(2010) http://www.cs.kent.edu/~jin/Papers/vldb10_gseq.pdf

GraphLab (2010) http://graphlab.org/

Page 51: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

GraphLab: 機械学習のための分散処理API

Linux Cluster Services (Amazon AWS)

MPI/TCP-IP Comms PThreads Boost Hadoop/HDFS

Sync. Engine Async. Engine Fault Tolerance Distributed Graph

Map/Reduce Ingress

GraphLab Version 2.1 API (C++)

Graph Analytics

Graphical Models

Computer Vision

Clustering Topic

Modeling Collaborative

Filtering

http://graphlab.org/

CMUのMLグループが中心、HDFSとインテグレート、オープンソース

Graph processing

Triangle Counting

Pagerank

K-Cores

Collaborative Filtering

ALS,Weighted ALS

SGD, Biased SGD

Graphical Models

Loopy Belief

Propagation

Max product LP

Computer Vision

Image stitching

Feature extraction

Clustering

K-Means++

Twitter data

40M Users

1.2B Edges

1536台

423分

64台、1024 Cores

1.5分

Page 52: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ちょっと待って

Page 53: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ちょっと待て、でも必要なのはアラート情報

ソーシャルデータを自社にもってくる必要はあるのでしょうかね?

もともと外にあるソーシャルデータストリームは、もってこずに、単に監視できればいいのでは?

Page 54: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ストリームデータはどこに?

CEP

tweet

stream

Monitor Action

Action

Monitor Action

Action

CEP

Alert

Monitoring

in the enterprise in the enterprise

CEPも外へ

CEPは中

Page 55: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

ストリームマイニングクラウド

Opera solutions

http://www.operasolutions.com/

ストリーム

検知装置

分析装置

ここにソーシャルデータストリームが入れば完璧だが…..。

Page 56: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

国内でもストリームマイニングフレームワーク

小規模

単体 大規模

分散処理

リアルタイム

バッチ

1993年

Special thanks to Preferred Infrastructure.

http://jubat.us/ http://preferred.jp

2006年

1998年

• Structured Perceptron [Collins, EMNLP 2002]

• Passive Aggressive / MIRA 2004~ • oll: online-learning library

[岡野原, 2008] ユバタス

プリファードインフラストラクチャー社

WEKA The University

of Waikato

2011年

Page 57: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

SalesForce/Radian6 + Twitter Firehose

※Firehoseは、全公開ツイートをリアルタイムに取得可能な機能

Page 58: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

まとめ:Enterprise social

CRM

Business application

Sub system

Data mart

Data mart

Data mart ESB

CEP

Business application

Sub system

Business application

Sub system

to public

データはためて分析(処理)する データプロセッシング

Page 59: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Stream data analysis platform

まとめ:Social enterprise 見方を変えよう

CEP

CRM

Business application

Sub system Data mart

Data mart

ESB Business application

Sub system

Business application

Sub system

Social enterprise cockpit

Legacy systems

CEP Cloud

パブリックなソーシャルデータ

ストリームからリアルタイムに情報を得る

Page 60: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

まとめ:

ストリームデータデベロッパーにL.up!

データプロセッシングデベロッパーから

Page 61: Developers [Social Enterprise] Summit 2012 A1

Developers[Social Enterprise] Summit 2012 (A-1)

Thank you.

https://www.facebook.com/kohei.kumazawa

http://www.nasa.gov/mission_pages/sdo/multimedia/potw/potw-106.html

Shall we hack stream!