File tree 2 files changed +11
-0
lines changed
2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -109,7 +109,10 @@ await foreach (var token in inferTokens)
109
109
Console .Write (token .Logit );
110
110
Console .Write (token .Probability );
111
111
Console .Write (token .Content );
112
+ Console .Write (token .IsChild );
112
113
}
114
+ // Note: If a character has more than one token the first will contain the entire content
115
+ // the others are marked as IsChild and will only contain the Id, Logit and Probability
113
116
114
117
115
118
// InferTextAsync, returns IAsyncEnumerable<string> for streaming output of tokens
Original file line number Diff line number Diff line change @@ -190,6 +190,7 @@ The `ModelSessionController` is a controller designed to handle various `ModelSe
190
190
"logit": 0,
191
191
"probability": 0,
192
192
"content": null,
193
+ "isChild": false,
193
194
"type": "Begin",
194
195
"elapsed": 0
195
196
},
@@ -198,6 +199,7 @@ The `ModelSessionController` is a controller designed to handle various `ModelSe
198
199
"logit": 27.43893,
199
200
"probability": 0.5839324,
200
201
"content": " An",
202
+ "isChild": false,
201
203
"type": "Content",
202
204
"elapsed": 1292
203
205
},
@@ -206,6 +208,7 @@ The `ModelSessionController` is a controller designed to handle various `ModelSe
206
208
"logit": 31.901243,
207
209
"probability": 0.9997987,
208
210
"content": " apple",
211
+ "isChild": false,
209
212
"type": "Content",
210
213
"elapsed": 1414
211
214
},
@@ -214,6 +217,7 @@ The `ModelSessionController` is a controller designed to handle various `ModelSe
214
217
"logit": 32.91171,
215
218
"probability": 0.99989986,
216
219
"content": " is",
220
+ "isChild": false,
217
221
"type": "Content",
218
222
"elapsed": 1672
219
223
},
@@ -259,6 +263,7 @@ The `ModelSessionController` is a controller designed to handle various `ModelSe
259
263
"logit": 0,
260
264
"probability": 0,
261
265
"content": null,
266
+ "isChild": false,
262
267
"type": "Begin",
263
268
"elapsed": 0
264
269
},
@@ -267,6 +272,7 @@ The `ModelSessionController` is a controller designed to handle various `ModelSe
267
272
"logit": 27.43893,
268
273
"probability": 0.5839324,
269
274
"content": " An",
275
+ "isChild": false,
270
276
"type": "Content",
271
277
"elapsed": 1292
272
278
},
@@ -275,6 +281,7 @@ The `ModelSessionController` is a controller designed to handle various `ModelSe
275
281
"logit": 31.901243,
276
282
"probability": 0.9997987,
277
283
"content": " apple",
284
+ "isChild": false,
278
285
"type": "Content",
279
286
"elapsed": 1414
280
287
},
@@ -283,6 +290,7 @@ The `ModelSessionController` is a controller designed to handle various `ModelSe
283
290
"logit": 32.91171,
284
291
"probability": 0.99989986,
285
292
"content": " is",
293
+ "isChild": false,
286
294
"type": "Content",
287
295
"elapsed": 1672
288
296
},
You can’t perform that action at this time.
0 commit comments