| --- |
| license: gemma |
| tags: |
| - bccard |
| - bcgpt |
| datasets: |
| - BCCard/BCCard-Finance-Kor-QnA |
| - maywell/ko_wikidata_QA |
| - jojo0217/korean_rlhf_dataset |
| language: |
| - ko |
| - en |
| - ja |
| base_model: |
| - google/gemma-2-27b-it |
| --- |
| |
| **BCCard/gemma-2-27b-it-Korean** is a Korean language model based on Google's Gemma 2 (27B parameters) architecture. It was developed by fine-tuning on a variety of open-source Korean datasets, enabling it to excel in tasks such as Korean text generation, comprehension, and translation |
|
|
| # How to Use |
|
|
| ```python |
| import torch |
| from transformers import AutoTokenizer, AutoModelForCausalLM |
| |
| model_id = "BCCard/gemma-2-27b-it-Korean" |
| |
| tokenizer = AutoTokenizer.from_pretrained(model_id) |
| model = AutoModelForCausalLM.from_pretrained( |
| model_id, |
| torch_dtype=torch.bfloat16, |
| low_cpu_mem_usage=True, |
| device_map="auto", |
| ) |
| |
| model.eval() |
| instruction = "μμΈμ μ λͺ
ν κ΄κ΄ μ½μ€λ₯Ό λ§λ€μ΄μ€λ?" |
| |
| messages = [ |
| {"role": "user", "content": f"{instruction}"} |
| ] |
| |
| input_ids = tokenizer.apply_chat_template( |
| messages, |
| add_generation_prompt=True, |
| return_tensors="pt" |
| ).to(model.device) |
| |
| terminators = [ |
| tokenizer.eos_token_id, |
| tokenizer.convert_tokens_to_ids("<end_of_turn>") |
| ] |
| |
| outputs = model.generate( |
| input_ids, |
| max_new_tokens=2048, |
| eos_token_id=terminators, |
| do_sample=True, |
| temperature=0.6, |
| top_p=0.9, |
| ) |
| |
| print(tokenizer.decode(outputs[0][input_ids.shape[-1]:], skip_special_tokens=True)) |
| ``` |
|
|
| # Generated Text |
|
|
| ``` |
| ## μμΈ μ λͺ
κ΄κ΄ μ½μ€: 3κ°μ§ ν
λ§λ‘ μ¦κΈ°λ μμΈ μ¬ν! |
| |
| **1. μμ¬ μμΌλ‘ μκ° μ¬ν: κ²½λ³΅κΆ & λΆμ΄ νμ₯λ§μ μ½μ€ (ν루)** |
| |
| * **μ€μ :** κ²½λ³΅κΆ (μ‘°μ μλ κΆκΆ, κ΅λ³΄ μ 1νΈ) |
| * κ²½ν루, κ·Όμ μ , ν₯λ‘λ¬Έ λ±μ λ°©λ¬Ένλ©° μ‘°μ μλμ μλ¦λ€μμ λ껴보μΈμ. |
| * ν볡 λμ¬ ν κΆκΆ μ¬μ§ 촬μλ μΆμ²ν©λλ€. |
| * **μ μ¬:** λΆμ΄ νμ₯λ§μ κ·Όμ² μ ν΅ νμ λ§μ§μμ μ μ¬ μμ¬ |
| * λΆμ΄ νμ₯λ§μμ μλν λΆμκΈ° μμμ μ ν΅ μμμ μ¦κ²¨λ³΄μΈμ. |
| * **μ€ν:** λΆμ΄ νμ₯λ§μ (μ ν΅ νμ₯κ³Ό 골λͺ©κΈΈμ λ§€λ ₯) |
| * μμ νμ₯λ€ μ¬μ΄λ₯Ό κ±°λλ©° μ ν΅ κ³΅μν μΌνμ μ¦κ²¨λ³΄μΈμ. |
| * λΆμ΄ 8κΈΈ, λΆμ΄ 1κΈΈ, λΆμ΄ 3κΈΈ λ±μ νλ°©νλ©° μλ¦λ€μ΄ μ¬μ§μ λ¨κ²¨λ³΄μΈμ. |
| * **μ λ
:** μΈμ¬λ (μ ν΅ κ³΅μνκ³Ό κ°€λ¬λ¦¬) |
| * μ ν΅ κ³΅μνμ ꡬ경νκ³ , κ°€λ¬λ¦¬μμ μμ μνμ κ°μνμΈμ. |
| * μ λ
μμ¬λ μΈμ¬λμ λ€μν λ μ€ν λμμ μ¦κΈΈ μ μμ΅λλ€. |
| |
| **2. νμ€ν°λ€μ 거리 νλ°©: νλ & μ΄νμ μ½μ€ (ν루)** |
| |
| * **μ€μ :** νλ (μ μ λ¬Ένμ μ€μ¬μ§) |
| * νλ 거리μ λ
νΉν ν¨μ
κ³Ό μμ μνμ κ°μνμΈμ. |
| * νλ κ±·κ³ μΆμ 거리μμ μ¬μ§ 촬μμ μ¦κ²¨λ³΄μΈμ. |
| * νλ μ μ μμ κ°λ€μ μνμ κ°μν μ μλ κ°€λ¬λ¦¬λ λ°©λ¬Έν΄λ³΄μΈμ. |
| * **μ μ¬:** νλ λ§μ§μμ μ μ¬ μμ¬ (νΈλ λν μΉ΄νμ λ μ€ν λ) |
| * **μ€ν:** μ΄νμ (λ€μν λ¬Ένμ λ§μ§μ΄ λͺ¨μ¬μλ κ³³) |
| * μ΄νμ 거리μ λ€μν λ¬Ένλ₯Ό κ²½ννκ³ , μΈκ΅μΈλ€μκ² μΈκΈ° μλ λ μ€ν λκ³Ό μΉ΄νλ₯Ό λ°©λ¬ΈνμΈμ. |
| * μ΄νμμ λ
νΉν λΆμκΈ°λ₯Ό λλ μ μλ λ°μ νλ λ§μ΅λλ€. |
| * **μ λ
:** μ΄νμμ λ€μν λ μ€ν λμμ μ λ
μμ¬ (μΈκ³ κ°κ΅μ μμ) |
| |
| **3. μμ° μμμ ν΄μ: λΆνμ° & νκ° κ³΅μ μ½μ€ (ν루)** |
| |
| * **μ€μ :** λΆνμ° κ΅λ¦½κ³΅μ (μμΈμ μ², μλ¦λ€μ΄ μμ° κ²½κ΄) |
| * λΆνμ°μ λ€μν λ±μ° μ½μ€λ₯Ό μ ννμ¬ μμ°μ λ§λ½νμΈμ. |
| * λΆνμ° λ΄μ°λ¦¬μμ μμΈμ μλ¦λ€μ΄ μ κ²½μ κ°μνμΈμ. |
| * **μ μ¬:** λΆνμ° κ΅λ¦½κ³΅μ λ΄ μλΉμ΄λ μ°μ±
λ‘ κ·Όμ²μμ κ°λ¨ν μ μ¬ μμ¬ |
| * **μ€ν:** νκ° κ³΅μ (νκ°μ μλ¦λ€μμ λλ μ μλ 곡μ) |
| * μμ κ±°λ₯Ό νκ±°λ, μ°μ±
μ νλ©° νκ°μ μλ¦λ€μμ λ§λ½νμΈμ. |
| * νκ° κ³΅μμ λ€μν νΈμ μμ€μ μ΄μ©ν΄ ν΄μμ μ·¨νμΈμ. |
| * νκ° κ³΅μμμ νΌν¬λμ μ¦κΈ°λ©° μλ¦λ€μ΄ λ
Έμμ κ°μνμΈμ. |
| |
| **ν:** |
| |
| * μμΈμ λμ€κ΅ν΅μ λ§€μ° νΈλ¦¬ν©λλ€. μ§νμ² κ³Ό λ²μ€λ₯Ό μ΄μ©νμ¬ κ° κ΄κ΄μ§λ‘ μ΄λνμΈμ. |
| * κ° κ΄κ΄μ§μ μ
μ₯λ£μ μ΄μ μκ°μ 미리 νμΈνμΈμ. |
| * μ¬ν μ μ μμΈμ λ μ¨λ₯Ό νμΈνκ³ , μ μ ν μ·μ μ€λΉνμΈμ. |
| * νκ΅μ΄λ₯Ό μ λͺ»νλ€λ©΄, λ²μ μ±μ μ¬μ©νλ©΄ νΈλ¦¬ν©λλ€. |
| |
| μ¦κ±°μ΄ μμΈ μ¬ν λμΈμ! |
| ``` |
|
|
| ------- |
|
|
|
|
| # Q&A |
|
|
| ``` |
| Q. μ λ΄μ©μ μμ΄λ‘ λ²μν΄μ£ΌμΈμ. |
| A. ## Seoul's Must-See Attractions: 3 Themed Itineraries for Your Seoul Trip! |
| |
| **1. Journey Through History: Gyeongbokgung Palace & Bukchon Hanok Village (One Day)** |
| |
| * **Morning:** Gyeongbokgung Palace (Joseon Dynasty Palace, National Treasure No. 1) |
| * Visit Gyeonghoeru Pavilion, Geunjeongjeon Hall, and Heungnyemun Gate to experience the beauty of the Joseon Dynasty. |
| * We recommend renting a hanbok (traditional Korean attire) and taking photos in the palace. |
| * **Lunch:** Enjoy a traditional Korean meal at a restaurant near Bukchon Hanok Village. |
| * Savor traditional cuisine in the cozy atmosphere of Bukchon Hanok Village. |
| * **Afternoon:** Bukchon Hanok Village (Charm of Traditional Korean Houses and Alleys) |
| * Stroll through the picturesque hanoks and enjoy shopping for traditional crafts. |
| * Explore Bukchon 8th Street, Bukchon 1st Street, and Bukchon 3rd Street to capture beautiful photos. |
| * **Evening:** Insadong (Traditional Crafts and Galleries) |
| * Browse traditional crafts and admire artwork at galleries. |
| * Enjoy dinner at one of Insadong's diverse restaurants. |
| |
| **2. Hipster Hotspot Exploration: Hongdae & Itaewon (One Day)** |
| |
| * **Morning:** Hongdae (Center of Youth Culture) |
| * Admire Hongdae Street's unique fashion and art. |
| * Take photos at Hongdae's "Walking Street." |
| * Visit galleries showcasing the works of young Hongdae artists. |
| * **Lunch:** Enjoy lunch at a trendy cafe or restaurant in Hongdae. |
| * **Afternoon:** Itaewon (Melting Pot of Diverse Cultures and Cuisine) |
| * Experience Itaewon's vibrant cultural scene and visit popular restaurants and cafes frequented by foreigners. |
| * Explore Itaewon's unique bars and pubs. |
| * **Evening:** Indulge in dinner at one of Itaewon's diverse restaurants, offering cuisines from around the world. |
| |
| **3. Relaxation in Nature: Bukhansan National Park & Han River Park (One Day)** |
| |
| * **Morning:** Bukhansan National Park (Seoul's Forest, Stunning Natural Scenery) |
| * Choose from various hiking trails in Bukhansan and immerse yourself in nature. |
| * Admire the panoramic views of Seoul from the summit of Bukhansan. |
| * **Lunch:** Enjoy a simple lunch at a restaurant within Bukhansan National Park or near a hiking trail. |
| * **Afternoon:** Han River Park (Park Where You Can Enjoy the Beauty of the Han River) |
| * Cycle, stroll, and soak in the beauty of the Han River. |
| * Utilize the park's various amenities for relaxation. |
| * Enjoy a picnic at Han River Park and witness a breathtaking sunset. |
| |
| **Tips:** |
| |
| * Seoul's public transportation is very convenient. Use the subway and buses to travel between attractions. |
| * Check the admission fees and operating hours of each attraction in advance. |
| * Check Seoul's weather forecast before your trip and pack appropriate clothing. |
| * If you don't speak Korean fluently, a translation app can be helpful. |
| |
| Have a wonderful trip to Seoul! |
| |
| ``` |
|
|
| ## Correspondence to |
| - Taeyoung Lee (sh2orc@gmail.com) |
|
|
| ## License |
| The use of this model is governed by the [GOOGLE GEMMA TERM OF USE](https://ai.google.dev/gemma/terms) |
|
|
| ## Citation |
| If you use this model in your research, please cite it as follows: |
|
|
| ```bibtex |
| @misc{alpha-instruct, |
| author = {BCCard}, |
| title = {BCCard/gemma-2-27b-it-Korean}, |
| year = {2025}, |
| publisher = {Hugging Face}, |
| journal = {Hugging Face repository}, |
| url = {https://huggingface.co/BCCard/gemma-2-27b-it-Korean}, |
| } |