Skip to content

Latest commit

 

History

History
37 lines (34 loc) · 1.47 KB

File metadata and controls

37 lines (34 loc) · 1.47 KB

RAG

Definition

  • retrieval(检索) augmented generation: combine retrieval and generation, Leveraging external knowledge bases to enhance LLM performance

Principle

  • knowledge source -> vector-DB query -> retrieval -> vector-DB retrieval -> generation

Optimization

  • enhance the quality of DB
    • embedding optimization: multi-task
    • indexing: meta data
  • query
  • context: rerank.eg
  • retrieval
    • iterative retrieval
    • recursive retrieval: chain of thought
    • adaptive retriveval: Flare, self-RAG
  • LLM fine-tuning

RAG vs. Fine-tuning

  • RAG

    Screenshot 2024-04-07 at 11 17 48
  • Fine-tuning

    Screenshot 2024-04-07 at 11 18 16

Metrics

acc, recall, f1 score, bleu, rouge tool: RAGAS, ARES, TruLens

Huixiangdou

  • 智能客服:技术支持、领域知识对话
    • 群组中存在闲聊
    • parse users' intent
  • protocol: BSD-3-Clasue
  • workflow Screenshot 2024-04-12 at 09 13 21 Screenshot 2024-04-12 at 09 13 48