Update README.md
Browse files
README.md
CHANGED
@@ -443,8 +443,8 @@ topic_model = BERTopic(
|
|
443 |
language="english",
|
444 |
embedding_model=embedding_model,
|
445 |
umap_model=umap_model,
|
446 |
-
|
447 |
-
|
448 |
representation_model=representation_models,
|
449 |
verbose=True,
|
450 |
)
|
@@ -529,7 +529,6 @@ class SummarizationRepresentation(BaseRepresentation):
|
|
529 |
) -> Mapping[str, List[Tuple[str, float]]]:
|
530 |
updated_topics = {}
|
531 |
for topic_id, words in topics.items():
|
532 |
-
# Extract only the words from the tuples
|
533 |
words_only = [word[0] for word in words]
|
534 |
text = " ".join(words_only)
|
535 |
summary = summarize_with_model(text)
|
@@ -537,4 +536,4 @@ class SummarizationRepresentation(BaseRepresentation):
|
|
537 |
return updated_topics
|
538 |
|
539 |
summarization = SummarizationRepresentation(summarization_model, summarization_tokenizer)
|
540 |
-
```
|
|
|
443 |
language="english",
|
444 |
embedding_model=embedding_model,
|
445 |
umap_model=umap_model,
|
446 |
+
hdbscan_model=hdbscan_model,
|
447 |
+
vectorizer_model=vectorizer_model,
|
448 |
representation_model=representation_models,
|
449 |
verbose=True,
|
450 |
)
|
|
|
529 |
) -> Mapping[str, List[Tuple[str, float]]]:
|
530 |
updated_topics = {}
|
531 |
for topic_id, words in topics.items():
|
|
|
532 |
words_only = [word[0] for word in words]
|
533 |
text = " ".join(words_only)
|
534 |
summary = summarize_with_model(text)
|
|
|
536 |
return updated_topics
|
537 |
|
538 |
summarization = SummarizationRepresentation(summarization_model, summarization_tokenizer)
|
539 |
+
```
|