Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
search_tips
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
rank
search_tips
Commits
ee24a22c
Commit
ee24a22c
authored
Jan 28, 2019
by
段英荣
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
modify weight
parent
f0b9716a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
commons.py
trans2es/commons/commons.py
+4
-4
No files found.
trans2es/commons/commons.py
View file @
ee24a22c
...
...
@@ -21,16 +21,16 @@ def uuid4():
def
get_tips_suggest_list
(
instance_cn_name
):
try
:
ch_full_weight
=
6.0
py_full_weight
=
3.0
py_acronym_full_weight
=
3.0
ch_full_weight
=
6.0
*
10000
py_full_weight
=
3.0
*
10000
py_acronym_full_weight
=
3.0
*
10000
py_acronym_prefix_weight
=
2
ch_prefix_weight
=
1.5
py_prefix_weight
=
1.0
# 命中开始部分加权
begin_prefix_weight
=
1.2
begin_prefix_weight
=
1.2
*
10000
ch_full_word
=
instance_cn_name
py_full_word
=
''
.
join
(
lazy_pinyin
(
ch_full_word
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment