Discourse AI의 관찰 가능성

LLM의 모니터링 및 평가는 매우 중요합니다:

저는 5년 전, GitHub Copilot의 전신인 CodeSearchNet을 개발한 팀을 이끌 때 언어 모델 작업을 시작했습니다. 그 이후로 LLM 제품 개발을 위한 수많은 성공적이고 실패한 접근 방식을 지켜보았습니다. 실패한 제품에는 거의 항상 공통된 근본 원인이 있습니다. 바로 견고한 평가 시스템을 구축하지 못했다는 점입니다.

Discourse AI가 비즈니스에 중요한 LLM 작업을 처리하려면 LangSmith와 같은 모니터링 도구 지원을 우선시해야 한다고 생각합니다.

LangSmith를 사용하는 것은 yarn add langchain langsmith를 실행하고 몇 가지 환경 변수를 추가하는 것만큼 간단합니다.

Discourse 팀은 LLM 추적을 구성하는 방법에 대해 생각해 보셨나요? 또한, discourse-ai가 이를 공식적으로 지원하기 전에 이를 구현하는 방법에 대한 의견이 있으신가요?

2개의 좋아요

하하하, 그게 좋죠.

우리는 LLM에 대한 모든 요청과 응답을 테이블에 기록하고, 관리자가 Data Explorers를 통해 언제든지 이를 조회할 수 있도록 하고 있습니다. 이미 사용해 보셨나요?

{
  "max_tokens": 2000,
  "model": "meta-llama/Meta-Llama-3.1-70B-Instruct",
  "temperature": 0,
  "stop": [
    "\n</output>"
  ],
  "messages": [
    {
      "role": "system",
      "content": "You are a markdown proofreader. You correct egregious typos and phrasing issues but keep the user's original voice.\nYou do not touch code blocks. I will provide you with text to proofread. If nothing needs fixing, then you will echo the text back.\nYou will find the text between <input></input> XML tags.\nYou will ALWAYS return the corrected text between <output></output> XML tags.\n\n"
    },
    {
      "role": "user",
      "content": "<input>We log every single request and response to LLMs in a table, and allow admins to query those at any time via Data Explorer. Have you tried already?</input>"
    }
  ]
}
{
  "id": "chat-45cd241b6e0f4a58840fcc9f49dfa56a",
  "object": "chat.completion",
  "created": 1722528517,
  "model": "meta-llama/Meta-Llama-3.1-70B-Instruct",
  "choices": [
    {
      "index": 0,
      "message": {
        "role": "assistant",
        "content": "<output>We log every single request and response to LLMs in a table, and allow admins to query those at any time via Data Explorer. Have you tried this already?</output>",
        "tool_calls": []
      },
      "logprobs": null,
      "finish_reason": "stop",
      "stop_reason": null
    }
  ],
  "usage": {
    "prompt_tokens": 135,
    "total_tokens": 174,
    "completion_tokens": 39
  }
}

기능에 대한 평가(evals) 생성은 확실히 3.4 버전의 로드맵에 있으며, 특히 관련 주제(Related Topics) 및 요약(Summarization) 기능의 조정에 초점을 맞추고 있습니다.

1개의 좋아요

그게 전부라고 말한 적은 없어요. (:wink:) 하지만 LLM 호출은 Ruby에서 이루어진다고 생각하니 상관없는 것 같아요.

아직 시도하지는 않았지만, 정말 멋진 기능이에요. 감사합니다! 이론적으로는 이 데이터를 내보내서 LangSmith에서 평가와 실험을 위한 트레이스를 프로그래매틱하게 생성할 수 있을 것 같아요.

1개의 좋아요