upgrade to rwkv 0.8.25
This commit is contained in:
11
backend-python/rwkv_pip/utils.py
vendored
11
backend-python/rwkv_pip/utils.py
vendored
@@ -171,10 +171,17 @@ class PIPELINE:
|
||||
all_tokens += [token]
|
||||
for xxx in occurrence:
|
||||
occurrence[xxx] *= args.alpha_decay
|
||||
|
||||
ttt = self.decode([token])
|
||||
www = 1
|
||||
if ttt in " \t0123456789":
|
||||
www = 0
|
||||
# elif ttt in '\r\n,.;?!"\':+-*/=#@$%^&_`~|<>\\()[]{},。;“”:?!()【】':
|
||||
# www = 0.5
|
||||
if token not in occurrence:
|
||||
occurrence[token] = 1
|
||||
occurrence[token] = www
|
||||
else:
|
||||
occurrence[token] += 1
|
||||
occurrence[token] += www
|
||||
# print(occurrence) # debug
|
||||
|
||||
# output
|
||||
|
||||
Reference in New Issue
Block a user