0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

TildeOpen-30Bで検証する「文化的比喩理解」— 多言語モデルの限界点

Posted at

はじめに

「猫と犬が降っている」「七転び八起き」「Les carottes sont cuites」──
言葉の裏には、文化の香りがある。
今回使ったのは、TildeAI が開発した多言語基盤モデルTildeOpen-30B。英語・ドイツ語・フランス語・東欧言語など、ヨーロッパ言語を中心に訓練された大型LLMだ。
このモデルが「文化を超えた表現理解」をどこまでできるのか、実際にことわざや慣用句で実験してみた。


実験設定

  • モデル:TildeAI/TildeOpen-30b

  • 実行環境:Google Colab(transformers + torch

  • 対象表現:
    猿も木から落ちる(日本語)
    It’s raining cats and dogs(英語)
    Les carottes sont cuites(フランス語)
    Ich verstehe nur Bahnhof(ドイツ語)
    七転び八起き(日本語)

実際の出力結果

🐒 猿も木から落ちる

🗣️ Prompt: Translate the Japanese proverb '猿も木から落ちる' into English, but explain its meaning in natural English.
💬 Output: Translate the Japanese proverb '猿も木から落ちる' into English, but explain its meaning in natural English.
Answer: Even a monkey falls from a tree.

→ ✅ 直訳は完璧。
ただし「Even experts make mistakes.」のような説明はなし。
命令文をそのまま繰り返す“Instruction未学習挙動”が見られた。

☔ It’s raining cats and dogs

💬 Output: 猫と犬が降っている。

→ ❌ 直訳そのまま。
文化的に自然な「土砂降りだ」や「バケツをひっくり返したような雨」には変換されず。
比喩の意味を理解していない典型例。

🥕 Les carottes sont cuites

💬 Output: The carrots are cooked.
A. The carrots are cooked.
B. The carrots are cooked.
C. The carrots are cooked.
D. The carrots are cooked.
Answer: B. The carrots are cooked.

→ ⚠️ 選択肢形式で出力。
「もう手遅れ」「勝負がついた」といったニュアンス説明が抜け落ちている。
内部で“試験問題データ”を学習していた痕跡が見える。

🚉 Ich verstehe nur Bahnhof

💬 Output: 「私は駅のみを理解します」。「私は何も理解しません」。

→ ✅ 字面+意訳の両立!
ここだけは非常に優秀で、「直訳と本来の意味」を明示している。
“字面の誤解”と“文化的意味”を両方提示できる稀有な出力。

💪 七転び八起き

💬 Output: Failure is the mother of success.

→ 🌟 文化的に完璧な意訳。
「何度倒れても立ち上がる=失敗が成功を育てる」という構造を見抜いている。今回の中で最も人間的な翻訳。

分析まとめ

観点 傾向 コメント
命令理解 弱い “Translate…”をそのまま繰り返す癖あり
文法・構文 強い 欧州言語の構造は正確
比喩・文化理解 不安定 直訳多め、説明欠落
多言語対応力 高い 仏語・独語ともスムーズに処理
想定外出力 多い 定型文混入・選択肢形式など

面白ポイント

  • “Ich verstehe nur Bahnhof” のように直訳+意訳を両方出すのは珍しい。

  • “七転び八起き” の意訳成功は、意味構造を抽象的に理解している証拠。

  • “It’s raining cats and dogs” の直訳失敗は逆に面白い。「文化壁」がよく見える。


実験手順(Colabコード)

!pip install -q transformers accelerate torch

from transformers import AutoTokenizer, AutoModelForCausalLM
import torch

model_name = "TildeAI/TildeOpen-30b"
tokenizer = AutoTokenizer.from_pretrained(model_name, use_fast=False)
model = AutoModelForCausalLM.from_pretrained(model_name,
    torch_dtype=torch.bfloat16, device_map="auto")

prompts = [
    "Translate the Japanese proverb '猿も木から落ちる' into English, but explain its meaning in natural English.",
    "Translate the English idiom 'It’s raining cats and dogs' into Japanese with cultural adaptation.",
    "Translate the French saying 'Les carottes sont cuites' into English, explaining its nuance.",
    "Translate the German idiom 'Ich verstehe nur Bahnhof' into Japanese and explain what it means in context.",
    "Translate the Japanese saying '七転び八起き' into English in a culturally equivalent way."
]

for text in prompts:
    inputs = tokenizer(text, return_tensors="pt").to(model.device)
    outputs = model.generate(**inputs, max_new_tokens=180, do_sample=False)
    print("🗣️ Prompt:", text)
    print("💬 Output:", tokenizer.decode(outputs[0], skip_special_tokens=True))
    print("="*80)

応用&続編アイデア

タスク 内容
🔁 再翻訳テスト 日本語→英語→日本語→英語を往復し、意味のブレを可視化
🌏 文化距離マップ 各国のことわざを埋め込み化して UMAP で配置
🎥 物語風変換 「ことわざ」を短いストーリーに展開して文化的背景を描写

まとめ

TildeOpen-30B はまだ「命令理解」は弱いが、多言語構文・文法処理は圧倒的。とくに “七転び八起き=Failure is the mother of success” の出力は見事だった。

つまりこのモデルは、
「文法的には完璧な翻訳家」だが、文化の深読みはまだ苦手な文学者の卵
Instruction チューニング版が登場すれば、“文化を越える通訳AI” として一気に開花しそうだ。

🐣


フリーランスエンジニアです。
お仕事のご相談こちらまで
rockyshikoku@gmail.com

Core MLを使ったアプリを作っています。
機械学習関連の情報を発信しています。

Twitter
Medium

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?