Rams901 commited on
Commit
7da2dda
1 Parent(s): 2866904

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -52,7 +52,7 @@ def retrieve_thoughts(query, ):
52
  tier_2 = df[((df['score'] < 1) * (df["score"] > 0.7))]
53
 
54
  tier_1
55
- chunks_1 = tier_1.groupby(['title', 'url', ]).apply(lambda x: "\n...\n".join(x.sort_values('id')['page_content'].values[:min(3, len(x.sort_values('id')['page_content'].values))])).values
56
  tier_1_adjusted = tier_1.groupby(['title', 'url', ]).first().reset_index()[[ 'title', 'url']]
57
  tier_1_adjusted['ref'] = range(1, len(tier_1_adjusted) + 1 )
58
  tier_1_adjusted['content'] = chunks_1
 
52
  tier_2 = df[((df['score'] < 1) * (df["score"] > 0.7))]
53
 
54
  tier_1
55
+ chunks_1 = tier_1.groupby(['title', 'url', ]).apply(lambda x: "\n...\n".join(x.sort_values('id')['page_content'].values[:min(4, len(x.sort_values('id')['page_content'].values))])).values
56
  tier_1_adjusted = tier_1.groupby(['title', 'url', ]).first().reset_index()[[ 'title', 'url']]
57
  tier_1_adjusted['ref'] = range(1, len(tier_1_adjusted) + 1 )
58
  tier_1_adjusted['content'] = chunks_1