Skip to content

Commit

Permalink
Log word instead of char count
Browse files Browse the repository at this point in the history
  • Loading branch information
cornzz committed Aug 9, 2024
1 parent 3795bba commit 02f6625
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ def compress_prompt(prompt: str, rate: float):
def run_demo(prompt: str, context: str, rate: float, target_model: str, ui_settings: list[str], request: gr.Request):
# TODO: allow selecting parallel / sequential processing (?)
print(
f"RUN DEMO - prompt: {len(prompt)}, context: {len(context)}, rate: {rate}, model: {target_model.split('/')[-1]}",
f"RUN DEMO - prompt: {len(prompt.split())}, context: {len(context.split())}, rate: {rate}, model: {target_model.split('/')[-1]}",
f"{'(compress only) ' if 'Compress only' in ui_settings else ''}- from {request.cookies['session']}",
)
if "Compress only" in ui_settings:
Expand Down

0 comments on commit 02f6625

Please sign in to comment.