Skip to content

التعليق التوضيحي للصوت

التعليق على ملفات الصوت مع عرض الموجة الصوتية وأدوات التحكم في التشغيل.

يوفر Potato 2.0 إمكانيات قوية للتعليق التوضيحي على الصوت مع عرض الموجة الصوتية المدعوم بـ Peaks.js، وتسمية المقاطع، واختصارات لوحة المفاتيح الشاملة.

حالات الاستخدام

  • نسخ الكلام ومراجعته
  • تمييز المتحدثين (Speaker diarization)
  • تحليل الموسيقى
  • اكتشاف الأحداث الصوتية
  • التعرف على المشاعر في الكلام
  • ضمان جودة مراكز الاتصال

تفعيل دعم الصوت

أضف قسم audio_annotation إلى ملف الإعدادات الخاص بك:

yaml
annotation_schemes:
  - annotation_type: audio_annotation
    name: audio_segments
    description: "Segment and label the audio"
    labels:
      - Speech
      - Music
      - Silence
      - Noise

أوضاع التشغيل

يدعم Potato ثلاثة أوضاع للتعليق التوضيحي على الصوت:

وضع التسمية

تقسيم الصوت إلى مقاطع وتعيين تسميات فئوية لكل مقطع:

yaml
annotation_schemes:
  - annotation_type: audio_annotation
    name: speaker_diarization
    mode: label
    description: "Identify speakers in the audio"
    labels:
      - Speaker A
      - Speaker B
      - Overlap

وضع الأسئلة

إضافة أسئلة تعليق توضيحي لكل مقطع:

yaml
annotation_schemes:
  - annotation_type: audio_annotation
    name: speech_quality
    mode: questions
    description: "Evaluate speech segments"

الوضع المشترك

الجمع بين التسمية وأسئلة كل مقطع:

yaml
annotation_schemes:
  - annotation_type: audio_annotation
    name: full_analysis
    mode: both
    description: "Label and analyze audio segments"
    labels:
      - Speech
      - Music
      - Noise

خيارات الإعدادات

الإعداد الأساسي

yaml
annotation_schemes:
  - annotation_type: audio_annotation
    name: segments
    description: "Create audio segments"
    labels:
      - Label A
      - Label B
 
    # Optional constraints
    min_segments: 1
    max_segments: 50

اختصارات لوحة المفاتيح

يمكن تعيين التسميات باستخدام مفاتيح الأرقام 1-9:

yaml
annotation_schemes:
  - annotation_type: audio_annotation
    name: speakers
    labels:
      - Speaker A  # Press 1
      - Speaker B  # Press 2
      - Overlap    # Press 3

ألوان التسميات

تخصيص ألوان المقاطع:

yaml
annotation_schemes:
  - annotation_type: audio_annotation
    name: segments
    labels:
      - Speech
      - Music
      - Silence

أداء الموجة الصوتية

للحصول على أفضل أداء مع ملفات الصوت الطويلة، قم بتثبيت أداة BBC audiowaveform:

bash
# macOS
brew install audiowaveform
 
# Ubuntu/Debian
sudo apt-get install audiowaveform
 
# Or build from source
# https://github.com/bbc/audiowaveform

هذا يتيح توليد الموجة الصوتية من جانب الخادم. بدونه، يتم استخدام التوليد من جانب العميل (مناسب للملفات التي تقل مدتها عن 30 دقيقة).

تخزين الموجة الصوتية مؤقتاً

إعداد التخزين المؤقت لأداء أفضل:

yaml
audio_config:
  cache_dir: "audio_cache/"
  precompute_depth: 100  # Pre-generate waveforms for first N items
  client_fallback_max_duration: 1800  # 30 minutes in seconds

تنسيق البيانات

مرجع صوتي بسيط

json
[
  {"id": "1", "audio_path": "audio/recording_001.wav"},
  {"id": "2", "audio_path": "audio/recording_002.wav"}
]
yaml
data_files:
  - "data/audio_data.json"
 
item_properties:
  id_key: id
  audio_key: audio_path

مع النصوص المكتوبة

json
[
  {
    "id": "1",
    "audio_path": "audio/call_001.wav",
    "transcript": "Hello, how can I help you today?"
  }
]

تنسيق المخرجات

يتم حفظ التعليقات التوضيحية مع الطوابع الزمنية للمقاطع:

json
{
  "id": "audio_1",
  "annotations": {
    "segments": [
      {
        "start": 0.0,
        "end": 2.5,
        "label": "Speaker A",
        "questions": {
          "clarity": 4,
          "emotion": "Neutral"
        }
      },
      {
        "start": 2.5,
        "end": 5.2,
        "label": "Speaker B"
      }
    ]
  }
}

اختصارات لوحة المفاتيح

يوفر Potato اختصارات لوحة مفاتيح شاملة للتعليق التوضيحي الفعّال:

الاختصارالإجراء
Spaceتشغيل/إيقاف مؤقت
[تعيين بداية المقطع عند الموضع الحالي
]تعيين نهاية المقطع عند الموضع الحالي
1-9تعيين تسمية للمقطع الحالي
Deleteحذف المقطع الحالي
Left Arrowالرجوع 5 ثوانٍ
Right Arrowالتقدم 5 ثوانٍ
Up Arrowتكبير
Down Arrowتصغير
Homeالانتقال إلى البداية
Endالانتقال إلى النهاية
+زيادة سرعة التشغيل
-تقليل سرعة التشغيل

أمثلة على الإعدادات

تمييز المتحدثين

yaml
task_name: "Speaker Diarization"
task_dir: "."
port: 8000
 
data_files:
  - "data/recordings.json"
 
item_properties:
  id_key: id
  audio_key: audio_path
 
annotation_schemes:
  - annotation_type: audio_annotation
    name: speakers
    mode: label
    description: "Identify who is speaking"
    labels:
      - Speaker 1
      - Speaker 2
      - Speaker 3
      - Overlap
      - Silence
    min_segments: 1
 
audio_config:
  cache_dir: "audio_cache/"
  precompute_depth: 50
 
output_annotation_dir: "output/"
output_annotation_format: "json"
allow_all_users: true

مراجعة النسخ الكتابي

yaml
task_name: "Transcription Quality Review"
task_dir: "."
port: 8000
 
data_files:
  - "data/transcripts.json"
 
item_properties:
  id_key: id
  text_key: transcript
  audio_key: audio_path
 
annotation_schemes:
  - annotation_type: audio_annotation
    name: errors
    mode: questions
    description: "Mark transcription errors"
 
  - annotation_type: radio
    name: overall_accuracy
    description: "Overall transcript accuracy"
    labels:
      - Accurate
      - Minor errors
      - Major errors
      - Unusable
 
output_annotation_dir: "output/"
output_annotation_format: "json"

ضمان جودة مراكز الاتصال

yaml
task_name: "Call Center Quality Assurance"
task_dir: "."
port: 8000
 
data_files:
  - "data/calls.json"
 
item_properties:
  id_key: call_id
  audio_key: recording_path
 
annotation_schemes:
  # Segment-level annotation
  - annotation_type: audio_annotation
    name: conversation
    mode: both
    description: "Segment the conversation"
    labels:
      - Agent
      - Customer
      - Hold
      - Silence
 
  # Call-level assessment
  - annotation_type: likert
    name: professionalism
    description: "Agent professionalism"
    size: 5
    min_label: "Poor"
    max_label: "Excellent"
 
  - annotation_type: likert
    name: resolution
    description: "Issue resolution"
    size: 5
    min_label: "Unresolved"
    max_label: "Fully resolved"
 
  - annotation_type: multiselect
    name: issues
    description: "Select any issues observed"
    labels:
      - Long hold time
      - Agent interrupted
      - Incorrect information
      - Missing greeting
      - Unprofessional language
 
  - annotation_type: text
    name: notes
    description: "Additional observations"
    rows: 4
 
output_annotation_dir: "output/"
output_annotation_format: "json"

صيغ الصوت المدعومة

  • WAV (يُنصح به لأفضل جودة)
  • MP3
  • OGG
  • FLAC
  • M4A
  • WebM

نصائح الأداء

  1. تثبيت audiowaveform - ضروري لملفات الصوت الطويلة
  2. تفعيل التخزين المؤقت - استخدم cache_dir لتخزين الموجات الصوتية المولّدة مسبقاً
  3. استخدام WAV للجودة - الصيغ المضغوطة قد تُحدث تشوهات
  4. معالجة الصوت مسبقاً - تطبيع المستويات وقص الصمت غير الضروري
  5. مراعاة أحجام الملفات - الملفات الكبيرة تبطئ التحميل
  6. استخدام الحساب المسبق - توليد الموجات الصوتية مسبقاً للعناصر الأولى

استكشاف الأخطاء وإصلاحها

الموجة الصوتية لا تُحمَّل

  • تحقق من صحة مسار ملف الصوت
  • تأكد من أن صيغة الملف مدعومة
  • قم بتثبيت audiowaveform للملفات الطويلة
  • تحقق من وحدة تحكم المتصفح بحثاً عن الأخطاء

أداء بطيء

  • قم بتثبيت أداة audiowaveform
  • فعّل التخزين المؤقت للموجة الصوتية
  • قلّل أحجام ملفات الصوت
  • استخدم إعداد precompute_depth

المقاطع لا تُحفظ

  • تأكد من أن مجلد المخرجات قابل للكتابة
  • تحقق من إعدادات تنسيق التعليق التوضيحي
  • تأكد من أن المقطع يحتوي على وقت بداية ونهاية