davanstrien HF staff commited on
Commit
373a965
1 Parent(s): 5407e1f

add most recent

Browse files
Files changed (1) hide show
  1. load_card_data.py +3 -1
load_card_data.py CHANGED
@@ -168,7 +168,9 @@ def refresh_card_data(min_len: int = 250, min_likes: Optional[int] = None):
168
  collection = get_collection(chroma_client, embedding_function, COLLECTION_NAME)
169
  most_recent = get_last_modified_in_collection(collection)
170
 
171
- if data := load_cards(min_len=min_len, min_likes=min_likes, last_modified=None):
 
 
172
  _create_and_upsert_embeddings(data, collection)
173
  else:
174
  logger.info("No new data to refresh")
 
168
  collection = get_collection(chroma_client, embedding_function, COLLECTION_NAME)
169
  most_recent = get_last_modified_in_collection(collection)
170
 
171
+ if data := load_cards(
172
+ min_len=min_len, min_likes=min_likes, last_modified=most_recent
173
+ ):
174
  _create_and_upsert_embeddings(data, collection)
175
  else:
176
  logger.info("No new data to refresh")