Skip to content

quick()

Zero-configuration text normalization.

quick() is the simplest way to use BASA and is recommended for most users.

Internally, it is a thin wrapper around normalize() with all default settings enabled.


Import

from basa import quick

Basic Usage

quick(
    "gw gk ngerti bngtttt sihhhh!!!"
)

Output:

'saya tidak mengerti banget sih!'

Function Signature

quick(text)

Supported Inputs

Single String

quick(
    "udh makan blm?"
)

Output:

'sudah makan belum?'

Batch Processing

quick([
    "gw gk ngerti",
    "otw kampus"
])

Output:

[
    'saya tidak mengerti',
    'dalam perjalanan kampus'
]

Default Behavior

quick() always uses:

normalize(
    text,
    apply_slang=True,
    apply_typo=False,
    lowercase=True,
    normalize_punctuation=True,
    normalize_whitespace=True,
)

When Should I Use quick()?

Use quick() when:

  • Cleaning social media text
  • Building quick NLP prototypes
  • Working with Indonesian informal language
  • You do not need custom normalization settings

For advanced use cases, use normalize() directly.


Design Philosophy

The goal of quick() is simple:

Most users should only need one line of code.

from basa import quick

quick(text)