fixed the sentence duplication bug. todo: functors
This commit is contained in:
parent
4a9a9cca12
commit
d135cc7f2b
|
@ -302,6 +302,9 @@ def api_get_functor_frames():
|
|||
for ent in cur:
|
||||
frames += frames_from_db_entry(ent) # pre-process this step for prod TODO
|
||||
|
||||
for f in frames:
|
||||
print(f.to_json())
|
||||
|
||||
# raw_frames = vallex.functors_index[functor] # TODO
|
||||
ret_frames = RF(frames, valdb[SENSEMAP_COLL])
|
||||
return prepare_frames(ret_frames)
|
||||
|
|
|
@ -24,12 +24,14 @@ def sorted_by_len_tids(frames):
|
|||
|
||||
def reduce_0(frames, valdb_sensemap=None):
|
||||
# new request... frames should be sorded by
|
||||
# functors list (basically reduce_1, just each
|
||||
# sentence gets its own frame)
|
||||
r1_frames = reduce_1(frames)
|
||||
# functors list
|
||||
|
||||
# return frames # simplify code...
|
||||
# frames = reduce_1(frames)
|
||||
|
||||
sorting_strings = []
|
||||
separated_frames = []
|
||||
for frame in r1_frames:
|
||||
for frame in frames:
|
||||
for tid in frame.tids:
|
||||
tmp_frame = DC(frame)
|
||||
tmp_frame.tids = [tid]
|
||||
|
|
Loading…
Reference in New Issue
Block a user