face-morphing について
face-morphing は each::sense を使って顔を合成するスキルです。静止画やモーフアニメーションを作成でき、創作や家族間の類似性の可視化に利用できます。
主な機能
- 01複数の顔の合成
- 02家族に似た顔の生成
- 03滑らかなモーフアニメーション
- 04顔の性別特徴の変換
- 05複数写真から平均顔を生成
活用シーン
- 01カップルや著名人の写真の合成
- 02親の写真から子どもの顔を予測
- 03顔の変化を示す動画の作成
インストール
コマンドをコピーしてターミナルで実行します。
$
npx skills add https:/ / github.com/ eachlabs/ skills --skill face-morphingインストール後、Claude Code で/face-morphingを入力して読み込まれたか確認します。
同梱ファイルreferences/SSE-EVENTS.md
詳細
顔のモーフィング
each::sense を使って顔を変換し、ブレンドします。このスキルでは、顔のモーフィング、2つ以上の顔のブレンド、家族の類似性の予測、性別の入れ替え、滑らかなモーフィングアニメーションの生成ができます。
機能
- 顔のブレンド:2つの顔をシームレスに1つに融合します
- 有名人とのモーフィング:自分の顔と有名人の顔をブレンドします
- 家族の顔予測:親の写真から子どもの顔を予測します
- カップルの顔の融合:2人の顔をブレンドした顔を作成します
- 家族の類似性:遺伝的な類似性を分析して可視化します
- モーフィングアニメーション:顔同士の滑らかな動画トランジションを作成します
- 性別の入れ替え:顔の特徴を別の性別に変換します
- 民族的特徴のブレンド:複数の民族的特徴をブレンドした顔を作成します
- 歴史上の人物の現代化:歴史上の人物の顔を現代風に更新します
- 平均顔:複数の入力から平均的な顔を生成します
クイックスタート
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Morph these two faces together into a seamless blend, 50% each"}],
"model": "eachsense/beta",
"stream": true,
"image_urls": [
"https://example.com/face1.jpg",
"https://example.com/face2.jpg"
],
"mode": "max"
}'
ユースケースの例
1. 2つの顔をモーフィングする
2つの顔を1つの統一された結果にブレンドする、基本的な顔のモーフィングです。
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Morph these two faces together. Create a seamless blend that takes facial structure from the first image and some features like eyes and nose from the second image. Make it look natural and realistic."}],
"model": "eachsense/beta",
"stream": true,
"image_urls": [
"https://example.com/person-a.jpg",
"https://example.com/person-b.jpg"
],
"mode": "max"
}'
2. 有名人との顔のブレンド
ユーザーの写真と有名人の顔をブレンドして、楽しい変換を行います。
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Blend my face with this celebrity photo. Create a 50/50 morph that combines my facial structure with their features. Keep the result looking like a real person, not artificial."}],
"model": "eachsense/beta",
"stream": true,
"image_urls": [
"https://example.com/my-photo.jpg",
"https://example.com/celebrity.jpg"
],
"mode": "max"
}'
3. 親と子どもの顔の予測
2人の親の写真をもとに、子どもの顔を予測します。
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Based on these two parent photos, generate what their child might look like. Create a baby/toddler face that naturally combines features from both parents - take eye shape from the first parent, nose structure from the second, and blend skin tones appropriately. Make it look like a realistic child portrait."}],
"model": "eachsense/beta",
"stream": true,
"image_urls": [
"https://example.com/parent1.jpg",
"https://example.com/parent2.jpg"
],
"mode": "max"
}'
4. カップルの顔の融合
カップルの写真から融合した顔を作成します。
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Merge these two faces from a couple into one face. The result should look like a single person who has balanced features from both individuals. Keep natural proportions and make it look like a genuine portrait photo."}],
"model": "eachsense/beta",
"stream": true,
"image_urls": [
"https://example.com/partner1.jpg",
"https://example.com/partner2.jpg"
],
"mode": "max"
}'
5. 家族の類似性ジェネレーター
家族のメンバー間の遺伝的な類似性を可視化します。
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Analyze these family member photos and create a face that represents the family resemblance - the common features shared across all family members. Highlight the genetic similarities in bone structure, eye shape, and facial proportions."}],
"model": "eachsense/beta",
"stream": true,
"image_urls": [
"https://example.com/family-member1.jpg",
"https://example.com/family-member2.jpg",
"https://example.com/family-member3.jpg"
],
"mode": "max"
}'
6. 徐々に変化するモーフィングアニメーション
ある顔から別の顔へとモーフィングする、滑らかな動画トランジションを作成します。
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Create a gradual morph animation video that smoothly transitions from the first face to the second face over 3 seconds. The transformation should be fluid and show intermediate blended states between both faces. Output as a video."}],
"model": "eachsense/beta",
"stream": true,
"image_urls": [
"https://example.com/start-face.jpg",
"https://example.com/end-face.jpg"
],
"mode": "max"
}'
7. 性別の入れ替え
顔の特徴を変換し、別の性別に見えるようにします。
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Transform this face to show how the person might look as a different gender. Adjust facial features like jawline, brow ridge, cheekbones, and add appropriate hair and makeup while maintaining recognizable features from the original person."}],
"model": "eachsense/beta",
"stream": true,
"image_urls": [
"https://example.com/original-face.jpg"
],
"mode": "max"
}'
8. 民族的特徴のブレンド
複数の民族的特徴をブレンドした顔を作成します。
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Blend these faces from different ethnic backgrounds into a single harmonious face. Create a natural-looking result that represents a mix of features from each source face - taking skin tone, eye shape, nose structure, and facial proportions from different inputs."}],
"model": "eachsense/beta",
"stream": true,
"image_urls": [
"https://example.com/face-ethnicity1.jpg",
"https://example.com/face-ethnicity2.jpg",
"https://example.com/face-ethnicity3.jpg"
],
"mode": "max"
}'
9. 歴史上の人物の現代化
歴史上の人物の肖像画を、現代風の写真スタイルに変換します。
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Take this historical portrait and modernize it. Transform the face to show how this historical figure would look in a modern photograph - update the lighting to contemporary photography style, adjust skin texture to look photorealistic, and give them a modern hairstyle while preserving their distinctive facial features."}],
"model": "eachsense/beta",
"stream": true,
"image_urls": [
"https://example.com/historical-portrait.jpg"
],
"mode": "max"
}'
10. 複数の写真から平均顔を作成する
複数の入力画像の特徴を組み合わせた平均顔を生成します。
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Create an average face from all these input photos. Blend the facial features mathematically to produce a single face that represents the statistical average of all inputs - averaged bone structure, feature placement, skin tone, and proportions."}],
"model": "eachsense/beta",
"stream": true,
"image_urls": [
"https://example.com/face1.jpg",
"https://example.com/face2.jpg",
"https://example.com/face3.jpg",
"https://example.com/face4.jpg",
"https://example.com/face5.jpg"
],
"mode": "max"
}'
複数ターンでのクリエイティブな反復
session_id を使って、顔のモーフィングを調整しながら反復します。
# Initial morph
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Morph these two faces together with a 50/50 blend"}],
"model": "eachsense/beta",
"stream": true,
"image_urls": [
"https://example.com/face-a.jpg",
"https://example.com/face-b.jpg"
],
"session_id": "morph-project-001"
}'
# Adjust the blend ratio
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Adjust the blend to be 70% first face and 30% second face"}],
"model": "eachsense/beta",
"stream": true,
"session_id": "morph-project-001"
}'
# Request specific feature adjustments
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-H "Accept: text/event-stream" \
-d '{
"messages": [{"role": "user", "content": "Keep the eyes from the first face but use the jawline from the second face"}],
"model": "eachsense/beta",
"stream": true,
"session_id": "morph-project-001"
}'
モードの選択
生成する前に、ユーザーに確認してください。
「高速で低コストのものと、高品質なもののどちらがよいですか?」
| モード | 最適な用途 | 速度 | 品質 |
|---|---|---|---|
max | 最終的なモーフィング結果、詳細なブレンド、アニメーション | 遅め | 最高 |
eco | クイックプレビュー、さまざまな組み合わせのテスト | 速め | 良好 |
ベストプラクティス
入力画像の品質
- 解像度:高解像度の顔写真(少なくとも512x512)を使用します
- 照明:入力画像間で照明を統一すると、より良いブレンドになります
- 顔の位置:正面を向き、角度が似ている写真が最適です
- 背景:背景をすっきりさせると、顔の特徴を分離しやすくなります
モーフィングの品質向上のヒント
- 似たポーズ:頭の位置が似ている顔のほうが、きれいにモーフィングできます
- はっきりした特徴:顔が隠れている写真(サングラスや、手で顔を覆っている写真)は避けます
- 年齢の一貫性:家族の顔を予測する場合は、写真撮影時の親の年齢を考慮します
- 複数回の実行:さまざまなプロンプトを試して、最適なブレンドスタイルを見つけます
アニメーションに関する考慮事項
- フレーム数:フレーム数を増やすと、より滑らかなトランジションになります
- 長さ:モーフィングアニメーションには2〜5秒が最適です
- ループ対応:ソーシャルメディアで使う場合は、シームレスなループを指定します
顔のモーフィングのプロンプトのヒント
顔をモーフィングする際は、プロンプトに次の詳細を含めます。
- ブレンド比率:ブレンドの割合を指定します(50/50、70/30など)
- 注目する特徴:どちらの顔からどの特徴を取り入れるか指定します
- 出力形式:画像または動画アニメーションを指定します
- スタイル:リアル、アーティスティック、誇張などを指定します
- 目標年齢:子どもの顔を予測する場合は、希望する年齢を指定します
プロンプトの構成例
"[Action] these faces with [blend ratio].
Take [features] from the first face and [features] from the second.
Output as [image/video]. Make it look [style descriptor]."
エラー処理
| エラー | 原因 | 解決方法 |
|---|---|---|
Failed to create prediction: HTTP 422 | 残高不足 | eachlabs.ai でチャージしてください |
No face detected | 入力画像に鮮明な顔がありません | より鮮明な顔写真を使用してください |
Face alignment failed | 顔の角度が大きく異なっています | 頭の位置が似た写真を使用してください |
| タイムアウト | 複雑な生成処理 | クライアントのタイムアウトを最低10分に設定してください |
関連スキル
each-sense- コア API ドキュメントface-swap- 画像間で顔を入れ替えますimage-generation- テキストによる説明から顔を生成しますvideo-generation- 顔のアニメーション動画を作成します
コメント
Markdown 対応