How to use BERTopic - Machine Learning Assisted Topic Modeling in Python

แชร์
ฝัง
  • เผยแพร่เมื่อ 21 พ.ย. 2024

ความคิดเห็น • 52

  • @muhammadarhamriaz629
    @muhammadarhamriaz629 2 ปีที่แล้ว +2

    I am brand new to DAW and soft soft - these tutorials are excellent an very helpful to get soone like up and running. Appreciate

  • @rvian4
    @rvian4 ปีที่แล้ว +1

    wow the features this bert approach provides really improves explanation of topic models

  • @dubey_ji
    @dubey_ji ปีที่แล้ว +3

    i found your channel today
    and man I must say thank you
    very good content

  • @sarasharick5209
    @sarasharick5209 2 ปีที่แล้ว +1

    Great video. I experimented with Top2Vec after that video, so looking forward to experimenting with BERTopic too.

  • @xevenau
    @xevenau 11 หลายเดือนก่อน +1

    Do you happen to have a tutorial that explains how to turn articles into a dataset for topic modeling. Thanks!

  • @wasgeht2409
    @wasgeht2409 2 ปีที่แล้ว +4

    two questions :) 1) Could i write a sentence and they give me after the training the probability for the topic based on the training ? 2) Could i use for example customer requests for training ? in this case you are using a unstructured data. I hope u understand my questions :D

  • @bentobenack2
    @bentobenack2 2 ปีที่แล้ว +1

    This is incredible, I subscribed to your channel today while looking for topic modeling content, I found very good content. However, I would also like to find something from BERTopic, and a few minutes later after subscribed, I receive a notification from TH-cam of your channel, and I said, it can't be true!
    Thank a lot!

    • @python-programming
      @python-programming  2 ปีที่แล้ว +1

      Haha! That is so perfect! Hope this video helps!!

    • @bentobenack2
      @bentobenack2 2 ปีที่แล้ว

      @@python-programming Definitely helped!

  • @suhasp2385
    @suhasp2385 2 ปีที่แล้ว

    Just simply put the code, it works! thanks!

  • @hankzhong
    @hankzhong 2 ปีที่แล้ว +4

    Great intro, but the default has too many topics to be useful for human understanding, is there a way to reduce the number of topics naturally? Also can we measure perplexity and coherence of these topics like LDA? Thanks

  • @TheArnold2002
    @TheArnold2002 ปีที่แล้ว +1

    Best video on topic modeling I've seen so far. Can I get all documents related to a topic, instead of just the top 3?

    • @python-programming
      @python-programming  ปีที่แล้ว +1

      Thanks! Indeed you can. BerTopic has changed a bit since I made this video, so I will have to check the docs but I am certain you can.

  • @raziehfadaei4801
    @raziehfadaei4801 8 หลายเดือนก่อน

    Thank you for your good video.
    Does BERTopic need any preprocesing like lemmatization or tokenization like LDA?

  • @danieleriahe-him4693
    @danieleriahe-him4693 ปีที่แล้ว +2

    Thanks so much for the high quality content you published so far, your playlist are a gold mine for beginners and enthusiast into the AI field.
    Have you ever considered making a video to explain principles of creating an efficient dataset for text summarization, or other specific tasks?
    Many thanks in advance for your consideration!

  • @mmishrafaculty
    @mmishrafaculty ปีที่แล้ว +2

    Awesome. That was so informative. And explained so clearly. Thank you so much.

    • @python-programming
      @python-programming  ปีที่แล้ว +1

      Thanks so much! I am planning a new video on BERTopic soon to cover its new features.

  • @andreasheiner3426
    @andreasheiner3426 2 ปีที่แล้ว +1

    Thanks, great tutorial.
    A question, what's your experience with quality of the model and sentence? Short sentences don't really work (to little semantics), long won't work either (too "much" semantics). Thoughts?

    • @python-programming
      @python-programming  2 ปีที่แล้ว

      Thanks! And great question. If you are looking for an off the shelf solution try top2vec, but I think you may run into similar issues. What language are your docs? Also, how varied are they in size? A more custom solution may be necessary.

    • @andreasheiner3426
      @andreasheiner3426 2 ปีที่แล้ว

      @@python-programming I've standard English web sites, from product reviews to travel reports. Generally a page contains some 10 paragraphs. Content on a page is highly correlated (you'd expect), so the page content is defined by a few paragraphs. The topic of a paragraph is mostly in a single sentence; the rest is "glue". This turns out to be a reasonable assumption (eye balling).
      BERTopic supports these observations, especially if you remove paragraphs with the topic probability for the most dominant topic less than some cutoff (say 0.6; the reason that, worst case another topic is present for at most 0.4). From experience you're left with 3% unallocated documents; each allocated document has at most 3 topics.
      This is all nice, assuming BERTopic gives good results for both long and short paragraphs with the same hyper parameters. If my assumption is incorrect I've a problem :(
      So, thoughts?

  • @kennethgomes4727
    @kennethgomes4727 ปีที่แล้ว +1

    Please can you explain why didnt you use UMAP, HDBSCAN and C-TF-IDF for this?

    • @python-programming
      @python-programming  ปีที่แล้ว

      Thanks for the question! You absolutely can. I have a whole other tutorial that walks through each of those steps. I think BERTopic, LeetTopic (my library), and Top2Vec provide a simpler solution for those who may not be familiar with a custom UMAP, HDBScan workflow. I try to make tutorials for users at all levels and I think these other libraries address the needs of those newer to Python/ML.

  • @DoreenGyamfi-i7k
    @DoreenGyamfi-i7k ปีที่แล้ว +1

    this was so informative, thank you.

  • @yashjain2841
    @yashjain2841 2 หลายเดือนก่อน

    How to run it on dataset with more than 12k rows?It is showing some "correct_alternative_cosine" error. Please help

  • @hosseinahmadi1855
    @hosseinahmadi1855 10 หลายเดือนก่อน

    Greeeeeeeeat!. Thanks. Another useful video

  • @KR-good
    @KR-good 9 หลายเดือนก่อน

    Great presentation.

  • @somewhereovertherainbow9550
    @somewhereovertherainbow9550 4 หลายเดือนก่อน

    Thanks!!! very much helpful!

  • @sohinisarkar1935
    @sohinisarkar1935 หลายเดือนก่อน

    Is it possible define number of topics here ?

  • @johnny_silverhand
    @johnny_silverhand 2 ปีที่แล้ว

    Fantastic explanation

  • @grgr1467
    @grgr1467 หลายเดือนก่อน

    hi ! where can i find the source file you used?

  • @mrtn5882
    @mrtn5882 2 ปีที่แล้ว +2

    Nice tutorial, thank you! If I follow the video correctly, about 25% of your documents are marked as outliers. Is that normal? Can you maybe talk about this a bit in a further video?

    • @python-programming
      @python-programming  2 ปีที่แล้ว +4

      Yea that is a bit normal woth BERTopic. I plan to do another video that compares dofferent topic modeling approaches and that will be a key feature

    • @mrtn5882
      @mrtn5882 2 ปีที่แล้ว

      @@python-programming Great, I’m looking forward to that video! 😊

  • @luiztauffer8513
    @luiztauffer8513 2 ปีที่แล้ว +1

    Thanks for the amazing content! Do you know if BERTopic could be used to train a model to identify similarity to custom, pre-defined topic?

    • @python-programming
      @python-programming  2 ปีที่แล้ว +1

      Thanks! I would not use BERTopic, rather soaCy for text classification. You could use BERTopic to gather data for easy labeling.

    • @luiztauffer8513
      @luiztauffer8513 2 ปีที่แล้ว

      @@python-programming thanks a lot, I actually went on to search for it and found another one of your videos explaining EXACTLY what I wanted! For reference it's this one: "The EASIEST! way to do Text Classification with spaCy and Classy Classification"
      thanks again!

    • @python-programming
      @python-programming  2 ปีที่แล้ว

      @@luiztauffer8513 haha! Perfect! No problem!

  • @emekaobiefuna4509
    @emekaobiefuna4509 ปีที่แล้ว

    Great info!

  • @BillVoisine
    @BillVoisine 4 หลายเดือนก่อน

    Thank you!!

  • @johnny_silverhand
    @johnny_silverhand 2 ปีที่แล้ว

    Best topic model to use for modelling 3000 documents each having 3 pages of text ?

    • @adambenari3944
      @adambenari3944 2 ปีที่แล้ว +1

      BERTopic or Top2Vec will both work, but you'll need to reduce your corpus to shorter text. You can use an introduction or conclusion as your text, or perform some summarization before you start modelling

  • @wasgeht2409
    @wasgeht2409 2 ปีที่แล้ว +1

    Wow

  • @tantzer6113
    @tantzer6113 2 ปีที่แล้ว +1

    Does this work for Arabic documents?

    • @python-programming
      @python-programming  2 ปีที่แล้ว +1

      As long as there is a BERT model for Arabic, yes. I know there is an NEH funded project for this but I am not sure if it is available yet. There is a lot of research in Arabic NLP so I would be surprised if another does not already exost. I do not have Arabic, though, so I cannot validate the results.

    • @tantzer6113
      @tantzer6113 2 ปีที่แล้ว

      @@python-programming Thank you for answering.

  • @LearnProfessional1
    @LearnProfessional1 2 ปีที่แล้ว

    is tNice tutorials ASMR?

  • @flosrv3194
    @flosrv3194 6 หลายเดือนก่อน

    no way to install this shit, get error popping from everywhere and when i resolve them, thre others appear, unusable crap

  • @niflag
    @niflag 10 วันที่ผ่านมา

    So quiet

  • @olucasharp
    @olucasharp ปีที่แล้ว +1

    Comment to say thanks and support this absolutely awesome channel 🪩
    Huge thanks and this is sooo clearly explained, good luck ⚡

    • @python-programming
      @python-programming  ปีที่แล้ว

      Thank you so much for your support and this wonderful comment!