> ## Documentation Index
> Fetch the complete documentation index at: https://hangulpy.uiharu.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# 자모 조합

> 자모를 다시 완성형 음절로 조합

## join\_jamos

자모 리스트나 자모 문자열을 완성형 음절로 조합합니다.

```python theme={null}
join_jamos(jamos: list[str] | str) -> str
```

## assemble

`join_jamos` 의 별칭입니다.

```python theme={null}
assemble(jamos: list[str] | str) -> str
```

## combine\_vowels

두 모음을 복합 모음으로 결합합니다. 결합할 수 없으면 기본적으로 `None` 을 반환합니다.
`join_on_fail=True` 를 넘기면 결합할 수 없는 두 모음을 그대로 이어서 반환합니다.

```python theme={null}
combine_vowels(vowel1: str, vowel2: str, join_on_fail: bool = False) -> str | None
```

## combine\_character

초성, 중성, 종성을 완성형 한글 음절로 결합합니다.

```python theme={null}
combine_character(cho: str, jung: str, jong: str = "") -> str
```

## disassemble\_to\_groups

문자열을 글자별 자모 그룹으로 분해합니다. 겹받침과 복합 모음은 가능한 가장 작은 자모 단위로 확실히 풀어서 반환합니다.

```python theme={null}
disassemble_to_groups(text: str) -> list[list[str]]
```

## disassemble\_complete\_character

완성형 한글 한 글자를 초성, 중성, 종성 문자열로 분해합니다.

```python theme={null}
disassemble_complete_character(char: str) -> dict[str, str] | None
```

## remove\_last\_character

마지막 글자의 마지막 자모를 제거합니다.

```python theme={null}
remove_last_character(text: str) -> str
```

## 예시

```python theme={null}
from hangulpy import (
    assemble,
    combine_character,
    combine_vowels,
    disassemble_complete_character,
    disassemble_to_groups,
    join_jamos,
    remove_last_character,
)

print(join_jamos(["ㅎ", "ㅏ", "ㄴ", "ㄱ", "ㅡ", "ㄹ"]))  # 한글
print(assemble("ㅎㅏㄴㄱㅡㄹ"))  # 한글
print(join_jamos("ㄱㅏㄴㅏ"))  # 가나
print(combine_vowels("ㅗ", "ㅏ"))  # ㅘ
print(combine_character("ㄱ", "ㅏ", "ㅂ"))  # 갑
print(disassemble_to_groups("사과"))  # [["ㅅ", "ㅏ"], ["ㄱ", "ㅗ", "ㅏ"]]
print(disassemble_complete_character("값"))  # {"choseong": "ㄱ", "jungseong": "ㅏ", "jongseong": "ㅂㅅ"}
print(remove_last_character("전화"))  # 전호
```

## 추가 예시

```python theme={null}
from hangulpy import combine_vowels, disassemble_to_groups

print(combine_vowels("ㅏ", "ㅗ"))  # None
print(combine_vowels("ㅏ", "ㅗ", join_on_fail=True))  # ㅏㅗ
print(disassemble_to_groups("값괜찮아"))
# [["ㄱ", "ㅏ", "ㅂ", "ㅅ"], ["ㄱ", "ㅗ", "ㅐ", "ㄴ"], ["ㅊ", "ㅏ", "ㄴ", "ㅎ"], ["ㅇ", "ㅏ"]]
```

## 같이 보기

* [split\_syllables / disassemble](split-syllables)
* [hangul\_syllable](hangul-syllable)
