Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
输出结果增加置信度输出
修改前输出格式: result_i = {"key": key[i], "text": text}
修改后输出格式:result_i = {"key": key[i], "text": text,"token_probs": token_probs }
以下是一个输出样例
[ { "key": "en", "text": "<|en|><|NEUTRAL|><|Speech|><|withitn|>The tribal chieftain called for the boy and presented him with 50 pieces of gold.", "token_probs": [ [ "<|en|>", 0.9999994039539004 ], [ "<|NEUTRAL|>", 0.6650255170850227 ], [ "<|Speech|>", 0.9988953170967498 ], [ "<|withitn|>", 1 ], [ "The", 0.9999670993193821 ], [ "tri", 0.9951907347523162 ], [ "bal", 0.9998259847282137 ], [ "chief", 0.9997330424830995 ], [ "tain", 0.9998868831779733 ], [ "called", 0.9992851364546496 ], [ "for", 0.9992235970978443 ], [ "the", 0.9991294577839298 ], [ "boy", 0.9301944527327015 ], [ "and", 0.9978013800052254 ], [ "presented", 0.995074099711129 ], [ "him", 0.99313369103405 ], [ "with", 0.9990471153011622 ], [ "", 0.9982630434699987 ], [ "5", 0.9995348234280294 ], [ "0", 0.9989625261045192 ], [ "pieces", 0.9995082651587693 ], [ "of", 0.9992288342347033 ], [ "gold", 0.9997841585713534 ], [ ".", 0.9979425173465579 ] ] } ]