asiasearch 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- data/README.textile +59 -0
- data/asiasearch.gemspec +1 -1
- data/lib/asiasearch.rb +0 -2
- metadata +5 -5
- data/README.mkdn +0 -18
data/README.textile
ADDED
@@ -0,0 +1,59 @@
|
|
1
|
+
h1. Yahoo Asia Search a.k.a Yahoo!搜尋『斷章取義』
|
2
|
+
|
3
|
+
h2. Description
|
4
|
+
|
5
|
+
Yahoo Asia Search provides user an interface for automated semantic analysis and language treatment.
|
6
|
+
|
7
|
+
You must [register first](http://developer.yahoo.com/wsregapp/index.php) to get API key.
|
8
|
+
Then [activate it](http://asia.search.yahooapis.com/cas/v1/AuthBootUp.php?appid=APIKEY).
|
9
|
+
|
10
|
+
You can get more detail on [Officical Site] (http://tw.developer.yahoo.com/cas/api.php).
|
11
|
+
|
12
|
+
h2. Install
|
13
|
+
|
14
|
+
<pre><code>rails g asiasearch</code></pre>
|
15
|
+
|
16
|
+
It will automate generate indextank.yml to your config/ directory. Please fill up your information.*
|
17
|
+
|
18
|
+
*2. Include AsiaSearch::Base in your model
|
19
|
+
|
20
|
+
<pre>
|
21
|
+
<code>
|
22
|
+
class Topic < ActiveRecord::Base
|
23
|
+
include Railstank::Search
|
24
|
+
has_keyword :content
|
25
|
+
end
|
26
|
+
</code>
|
27
|
+
</pre>
|
28
|
+
|
29
|
+
3. How to get keyword
|
30
|
+
|
31
|
+
<pre>
|
32
|
+
<code>
|
33
|
+
Topic.last.ke(5)
|
34
|
+
</code>
|
35
|
+
</pre>
|
36
|
+
|
37
|
+
It will return array.
|
38
|
+
|
39
|
+
<pre>
|
40
|
+
<code>
|
41
|
+
=> [{"token"=>"暗棋", "score"=>181.203937}, {"token"=>"下棋", "score"=>167.834379}, {"token"=>"iphone", "score"=>139.64361}, {"token"=>"網路連線", "score"=>137.115998}, {"token"=>"遊戲", "score"=>123.237589}, {"token"=>"玩家", "score"=>110.649053}, {"token"=>"app", "score"=>80.2954323}, {"token"=>"對手", "score"=>70.3604531}, {"token"=>"雙人", "score"=>69.4245914}, {"token"=>"好友", "score"=>64.2127734}, {"token"=>"比賽", "score"=>64.1604035}, {"token"=>"網路", "score"=>62.0883974}, {"token"=>"對決", "score"=>50.1022393}, {"token"=>"連線", "score"=>50.0287451}, {"token"=>"到期", "score"=>50.0128105}, {"token"=>"模式", "score"=>49.8294466}, {"token"=>"利用", "score"=>49.1433447}, {"token"=>"提供", "score"=>48.9973186}, {"token"=>"game", "score"=>48.9104876}, {"token"=>"online", "score"=>45.9753276}]
|
42
|
+
</pre>
|
43
|
+
|
44
|
+
|
45
|
+
h2. Contributing to AsiaSearch
|
46
|
+
|
47
|
+
* Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet
|
48
|
+
* Check out the issue tracker to make sure someone already hasn't requested it and/or contributed it
|
49
|
+
* Fork the project
|
50
|
+
* Start a feature/bugfix branch
|
51
|
+
* Commit and push until you are happy with your contribution
|
52
|
+
* Make sure to add tests for it. This is important so I don't break it in a future version unintentionally.
|
53
|
+
* Please try not to mess with the Rakefile, version, or history. If you want to have your own version, or is otherwise necessary, that is fine, but please isolate to its own commit so I can cherry-pick around it.
|
54
|
+
|
55
|
+
h2. Copyright
|
56
|
+
|
57
|
+
Copyright (c) 2011 xdite(xuite.joke@gmail.com) See LICENSE.txt for
|
58
|
+
further details.
|
59
|
+
|
data/asiasearch.gemspec
CHANGED
data/lib/asiasearch.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: asiasearch
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 25
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 0
|
9
|
-
-
|
10
|
-
version: 0.0.
|
9
|
+
- 3
|
10
|
+
version: 0.0.3
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Yi-Ting Cheng
|
@@ -58,7 +58,7 @@ extra_rdoc_files: []
|
|
58
58
|
files:
|
59
59
|
- .gitignore
|
60
60
|
- Gemfile
|
61
|
-
- README.
|
61
|
+
- README.textile
|
62
62
|
- asiasearch.gemspec
|
63
63
|
- lib/asiasearch.rb
|
64
64
|
- lib/generators/asiasearch/USAGE
|
@@ -94,7 +94,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
94
94
|
requirements: []
|
95
95
|
|
96
96
|
rubyforge_project:
|
97
|
-
rubygems_version: 1.
|
97
|
+
rubygems_version: 1.4.2
|
98
98
|
signing_key:
|
99
99
|
specification_version: 3
|
100
100
|
summary: Yahoo Asia Search provides user an interface for automated semantic analysis and language treatment.
|
data/README.mkdn
DELETED
@@ -1,18 +0,0 @@
|
|
1
|
-
Yahoo Asia Search a.k.a Yahoo!搜尋『斷章取義』
|
2
|
-
========
|
3
|
-
|
4
|
-
Description
|
5
|
-
------------------
|
6
|
-
Yahoo Asia Search provides user an interface for automated semantic analysis and language treatment.
|
7
|
-
|
8
|
-
You must [register first](http://developer.yahoo.com/wsregapp/index.php) to get API key.
|
9
|
-
Then [activate it](http://asia.search.yahooapis.com/cas/v1/AuthBootUp.php?appid=APIKEY).
|
10
|
-
|
11
|
-
You can get more detail on [Officical Site] (http://tw.developer.yahoo.com/cas/api.php).
|
12
|
-
|
13
|
-
Author
|
14
|
-
------------------
|
15
|
-
|
16
|
-
Author: xdite (xuite.joke@gmail.com)
|
17
|
-
|
18
|
-
Blog: http://blog.xdite.net
|