Shreyas094 commited on
Commit
167dce9
·
verified ·
1 Parent(s): 7715cda

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -132,7 +132,7 @@ After writing the document, please provide a list of sources with their URLs use
132
  client = InferenceClient(model, token=huggingface_token)
133
 
134
  # Calculate input tokens (this is an approximation, you might need a more accurate method)
135
- input_tokens = len(prompt.split()) // 3
136
 
137
  # Get the token limit for the current model
138
  model_token_limit = MODEL_TOKEN_LIMITS.get(model, 8192) # Default to 8192 if model not found
 
132
  client = InferenceClient(model, token=huggingface_token)
133
 
134
  # Calculate input tokens (this is an approximation, you might need a more accurate method)
135
+ input_tokens = len(prompt.split()) // 4
136
 
137
  # Get the token limit for the current model
138
  model_token_limit = MODEL_TOKEN_LIMITS.get(model, 8192) # Default to 8192 if model not found