Skip to content

Text

Text analysis: word count, encoding detection, email/URL/number extraction.

6 modules

ModuleDescription
문자 수텍스트의 문자 수 세기
인코딩 감지텍스트 인코딩 감지
이메일 추출텍스트에서 모든 이메일 주소 추출
숫자 추출텍스트에서 모든 숫자 추출
URL 추출텍스트에서 모든 URL 추출
단어 수텍스트의 단어 수 세기

Modules

문자 수

text.char_count

텍스트의 문자 수 세기

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-분석할 텍스트

Output:

FieldTypeDescription
totalnumber분석할 텍스트
without_spacesnumber총 문자 수
lettersnumber총 문자 수
digitsnumber공백 제외한 문자 수
spacesnumber문자 수
linesnumber숫자 수

인코딩 감지

text.detect_encoding

텍스트 인코딩 감지

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-인코딩을 감지할 텍스트 또는 바이트

Output:

FieldTypeDescription
encodingstring인코딩을 감지할 텍스트 또는 바이트
confidencenumber감지된 인코딩
is_asciiboolean감지된 인코딩
has_bomboolean신뢰도 점수 (0-1)

이메일 추출

text.extract_emails

텍스트에서 모든 이메일 주소 추출

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-이메일을 추출할 텍스트
uniquebooleanNoTrue이메일을 추출할 텍스트
lowercasebooleanNoTrue고유한 이메일만 반환

Output:

FieldTypeDescription
emailsarray이메일을 소문자로 변환
countnumber추출된 이메일 목록
domainsarray추출된 이메일 목록

숫자 추출

text.extract_numbers

텍스트에서 모든 숫자 추출

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-숫자를 추출할 텍스트
include_decimalsbooleanNoTrue숫자를 추출할 텍스트
include_negativebooleanNoTrue소수 포함

Output:

FieldTypeDescription
numbersarray음수 포함
countnumber추출된 숫자 목록
sumnumber추출된 숫자 목록
minnumber발견된 숫자 수
maxnumber모든 숫자의 합

URL 추출

text.extract_urls

텍스트에서 모든 URL 추출

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-URL을 추출할 텍스트
uniquebooleanNoTrueURL을 추출할 텍스트

Output:

FieldTypeDescription
urlsarray고유한 URL만 반환
countnumber추출된 URL 목록

단어 수

text.word_count

텍스트의 단어 수 세기

Parameters:

NameTypeRequiredDefaultDescription
texttextYes-분석할 텍스트

Output:

FieldTypeDescription
word_countnumber분석할 텍스트
unique_wordsnumber총 단어 수
sentence_countnumber총 단어 수
paragraph_countnumber고유 단어 수
avg_word_lengthnumber문장 수 추정

Released under the Apache 2.0 License.