Skip to content
Guides3 min read

تمييز الكلمات المفتاحية التلقائي

تكوين تمييز الكلمات المفتاحية المدعوم بالذكاء الاصطناعي لجذب انتباه المُوسِّم إلى المصطلحات والعبارات المهمة.

Potato Team·

تمييز الكلمات المفتاحية التلقائي

يجذب تمييز الكلمات المفتاحية المدعوم بالذكاء الاصطناعي انتباه المُوسِّم إلى المصطلحات أو الكيانات أو الأنماط المهمة في النص. يغطي هذا الدليل كيفية تكوين دعم الذكاء الاصطناعي المدمج في Potato لتمييز الكلمات المفتاحية ذات الصلة تلقائياً.

لماذا نستخدم تمييز الكلمات المفتاحية؟

  • تركيز الانتباه: توجيه المُوسِّمين إلى المحتوى ذي الصلة
  • تحسين السرعة: تحديد أسرع للمعلومات الرئيسية
  • تقليل الأخطاء: احتمال أقل لتفويت المصطلحات المهمة
  • الاستفادة من الذكاء الاصطناعي: دع نماذج اللغة الكبيرة تحدد الكلمات المفتاحية الخاصة بالسياق

التمييز الأساسي المدعوم بالذكاء الاصطناعي

يستخدم Potato نظام دعم الذكاء الاصطناعي لتحديد وتمييز الكلمات المفتاحية المهمة. إليك تكويناً أساسياً:

yaml
annotation_task_name: "Keyword Highlighted Annotation"
 
data_files:
  - path: "data/reviews.json"
    format: json
 
item_properties:
  id_key: id
  text_key: text
 
annotation_schemes:
  - annotation_type: radio
    name: sentiment
    description: "What is the overall sentiment?"
    labels:
      - Positive
      - Negative
      - Neutral
 
ai_support:
  enabled: true
  endpoint_type: openai
 
  ai_config:
    model: gpt-4
    api_key: ${OPENAI_API_KEY}
    temperature: 0.3
    max_tokens: 500
 
  features:
    keyword_highlighting:
      enabled: true
      # Highlights are rendered as box overlays on the text

استخدام مزودي ذكاء اصطناعي مختلفين

OpenAI

yaml
ai_support:
  enabled: true
  endpoint_type: openai
 
  ai_config:
    model: gpt-4o
    api_key: ${OPENAI_API_KEY}
    temperature: 0.3
    max_tokens: 500
 
  features:
    keyword_highlighting:
      enabled: true
 

Anthropic Claude

yaml
ai_support:
  enabled: true
  endpoint_type: anthropic
 
  ai_config:
    model: claude-3-sonnet-20240229
    api_key: ${ANTHROPIC_API_KEY}
    temperature: 0.3
    max_tokens: 500
 
  features:
    keyword_highlighting:
      enabled: true
      # Highlights are rendered as box overlays on the text

Ollama المحلي (بدون تكاليف API)

yaml
ai_support:
  enabled: true
  endpoint_type: ollama
 
  ai_config:
    model: llama2
    base_url: http://localhost:11434
 
  features:
    keyword_highlighting:
      enabled: true
      # Highlights are rendered as box overlays on the text

دمج الميزات

يوفر دعم الذكاء الاصطناعي ميزات متعددة تعمل جيداً معاً:

yaml
ai_support:
  enabled: true
  endpoint_type: openai
 
  ai_config:
    model: gpt-4
    api_key: ${OPENAI_API_KEY}
    temperature: 0.3
    max_tokens: 500
 
  features:
    # Highlight important keywords
    keyword_highlighting:
      enabled: true
      # Highlights are rendered as box overlays on the text
 
    # Show contextual hints
    hints:
      enabled: true
 
    # Suggest labels for consideration
    label_suggestions:
      enabled: true
      show_confidence: true

مثال تكوين كامل

إليك تكويناً كاملاً للتوسيم الواعي بالكيانات مع تمييز بالذكاء الاصطناعي:

yaml
annotation_task_name: "Entity-Aware Annotation"
 
data_files:
  - path: "data/documents.json"
    format: json
 
item_properties:
  id_key: id
  text_key: text
 
annotation_schemes:
  - annotation_type: span
    name: entities
    labels:
      - name: PERSON
        color: "#FECACA"
      - name: ORG
        color: "#BBF7D0"
      - name: LOCATION
        color: "#BFDBFE"
 
ai_support:
  enabled: true
  endpoint_type: openai
 
  ai_config:
    model: gpt-4
    api_key: ${OPENAI_API_KEY}
    temperature: 0.3
    max_tokens: 500
 
  features:
    keyword_highlighting:
      enabled: true
      # Highlights are rendered as box overlays on the text
    hints:
      enabled: true
    label_suggestions:
      enabled: true
      show_confidence: true
 
  cache_config:
    disk_cache:
      enabled: true
      path: "ai_cache/cache.json"
    prefetch:
      warm_up_page_count: 50
      on_next: 3
      on_prev: 2
 
output_annotation_dir: "output/"
output_annotation_format: json
allow_all_users: true

التخزين المؤقت للأداء

فعّل التخزين المؤقت لتقليل استدعاءات API وتحسين وقت الاستجابة:

yaml
ai_support:
  enabled: true
  endpoint_type: openai
 
  ai_config:
    model: gpt-4
    api_key: ${OPENAI_API_KEY}
 
  features:
    keyword_highlighting:
      enabled: true
 
  cache_config:
    disk_cache:
      enabled: true
      path: "ai_cache/cache.json"
 
    # Pre-generate highlights on startup and prefetch upcoming
    prefetch:
      warm_up_page_count: 100
      on_next: 5
      on_prev: 2

نصائح

  1. طابق الألوان مع مهمتك: استخدم ألوان تمييز تكمل مخطط التوسيم الخاص بك
  2. فعّل التخزين المؤقت: تجنب استدعاءات API المتكررة لنفس المحتوى
  3. فكر في النماذج المحلية: استخدم Ollama للتوسيم بكميات كبيرة بدون تكاليف API
  4. ادمج الميزات: تمييز الكلمات المفتاحية يعمل جيداً مع التلميحات واقتراحات التسميات

الوثائق الكاملة في /docs/features/ai-support.