on master help sign in
version 0.1.4
37926b8Hunter Miller
desk/app/sphinx.hoon+9−1
@@ -211,6 +211,9 @@
211 ?+ path [~ ~]
211 ?+ path [~ ~]
212 [%x %published ~]
212 [%x %published ~]
213 ``directory+!>(published)
213 ``directory+!>(published)
214+ ::
215+ [%x %state ~]
216+ ``noun+!>(state)
214 ::
217 ::
215 [%x %lookup @ @ @ $@(~ [@ ~])]
218 [%x %lookup @ @ @ $@(~ [@ ~])]
216 =- ``search+!>(-)
219 =- ``search+!>(-)
@@ -231,11 +234,16 @@
231 ~(val by directory)
234 ~(val by directory)
232 |= =listing:s
235 |= =listing:s
233 |(=(filter %all) =(filter type.post.listing))
236 |(=(filter %all) =(filter type.post.listing))
237+ =/ entries (~(get-entries delver [lookup trigrams phonetics]) term)
238+ :: ~& %+ turn
239+ :: entries
240+ :: |= [=hash:s =rank:s]
241+ :: [(~(got by directory) hash) rank]
234 %+ skim
242 %+ skim
235 %- get-listings
243 %- get-listings
236 %- get-hashes
244 %- get-hashes
237 %- sort-entries
245 %- sort-entries
238− (~(get-entries delver [lookup trigrams phonetics]) term)
246+ entries
239 |= =listing:s
247 |= =listing:s
240 |(=(filter %all) =(filter type.post.listing))
248 |(=(filter %all) =(filter type.post.listing))
241 =/ listings (swag [start limit] all)
249 =/ listings (swag [start limit] all)
desk/lib/sphinx.hoon+1−4
@@ -82,10 +82,7 @@
82 %+ turn
82 %+ turn
83 (get-keys term)
83 (get-keys term)
84 |= item=@t
84 |= item=@t
85− %+ turn
86− (~(gut by lookup) item *(list entry))
85+ (~(gut by lookup) item *(list entry))
87− |= =entry
88− (derank entry 10)
89 ++ get-phonetics
86 ++ get-phonetics
90 |= term=key
87 |= term=key
91 ^- (list entry)
88 ^- (list entry)
desk/mar/state.hoonnew file+12
@@ -0,0 +1,12 @@
1+/- s=sphinx
2+|_ =state:s
3+++ grad %noun
4+++ grow
5+ |%
6+ ++ noun state
7+ --
8+++ grab
9+ |%
10+ ++ noun state:s
11+ --
12+--
desk/sur/sphinx.hoon+10
@@ -82,6 +82,16 @@
82 total=@ud
82 total=@ud
83 ==
83 ==
84::
84::
85++$ state
86+ $: %1
87+ =lookup
88+ =trigrams
89+ =phonetics
90+ =trail
91+ =directory
92+ published=directory
93+ ==
94+::
85++ directory-state-zero
95++ directory-state-zero
86 |%
96 |%
87 +$ post
97 +$ post