Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Lære Challenge: Tokenization with Regex | Text Preprocessing Fundamentals
Introduction to NLP

bookChallenge: Tokenization with Regex

Opgave

Swipe to start coding

You are given a message in message variable. You have to tokenize it into words using regex. To do this:

  1. Import necessary class.
  2. Convert message to lowercase and save in message_lower.
  3. Create a Regexp Tokenizer with correct pattern and save it in word_tokenizer.
  4. Tokenize message_lower into words using word_tokenizer.

A word is a sequence of alphanumeric characters and underscores. '#NLPConference_20!', for example, contains one word: NLPConference_20.

Løsning

Var alt klart?

Hvordan kan vi forbedre det?

Tak for dine kommentarer!

Sektion 1. Kapitel 6
single

single

Spørg AI

expand

Spørg AI

ChatGPT

Spørg om hvad som helst eller prøv et af de foreslåede spørgsmål for at starte vores chat

close

Awesome!

Completion rate improved to 3.45

bookChallenge: Tokenization with Regex

Stryg for at vise menuen

Opgave

Swipe to start coding

You are given a message in message variable. You have to tokenize it into words using regex. To do this:

  1. Import necessary class.
  2. Convert message to lowercase and save in message_lower.
  3. Create a Regexp Tokenizer with correct pattern and save it in word_tokenizer.
  4. Tokenize message_lower into words using word_tokenizer.

A word is a sequence of alphanumeric characters and underscores. '#NLPConference_20!', for example, contains one word: NLPConference_20.

Løsning

Switch to desktopSkift til skrivebord for at øve i den virkelige verdenFortsæt der, hvor du er, med en af nedenstående muligheder
Var alt klart?

Hvordan kan vi forbedre det?

Tak for dine kommentarer!

close

Awesome!

Completion rate improved to 3.45
Sektion 1. Kapitel 6
single

single

some-alt