AI 플러그인으로 인해 최신 Discourse 버전에서 모든 게시글이 읽을 수 없음

커뮤니티 여러분,

최신 버전의 Discourse에서 AI 플러그인과 관련된 치명적인 버그를 보고하기 위해 이 글을 씁니다. 이 문제로 인해 커뮤니티의 모든 게시물이 읽을 수 없게 되었으며, 원인을 파악하는 데 많은 시간을 보냈습니다. 문제의 상세한 내용은 다음과 같습니다:


문제 설명

최신 Discourse 버전으로 업데이트한 후, 커뮤니티의 모든 게시물이 읽을 수 없게 되었습니다. 어떤 주제(Topic)를 열려고 해도 사용자는 다음과 같은 오류 메시지를 받게 됩니다:

“죄송합니다. 해당 주제를 불러올 수 없습니다. 연결 문제로 인해 발생할 수 있습니다. 다시 시도해 주세요. 문제가 지속되면 알려 주세요.”

문제가 발생하는 URL의 예시는 다음과 같습니다:
https://bbs.starorigin.com.cn/t/topic/111


처음에는 서버나 연결 문제일 것으로 의심했지만, 확인 결과 모든 것이 정상적으로 작동하고 있었습니다.

문제의 원인을 찾기 위해整整한 저녁 동안 모든 플러그인을 체계적으로 테스트했습니다. 제가 수행한 작업은 다음과 같습니다:

  • 모든 플러그인 제거: 커뮤니티가 즉시 정상적인 기능으로 돌아왔습니다.
  • AI 플러그인을 제외한 모든 플러그인 재설치: 커뮤니티는 문제없이 계속 작동했습니다.
  • AI 플러그인만 재설치: 문제가 다시 발생했으며, 모든 게시물이 다시 읽을 수 없게 되었습니다.

충돌 테스트:
AI 플러그인과 다른 플러그인 간의 충돌 가능성을 배제하기 위해 다음과 같이 진행했습니다:

  • 다른 모든 플러그인을 제거하고 AI 플러그인만 설치한 상태로 유지했습니다.
  • 문제는 지속되었습니다: 모든 게시물이 여전히 읽을 수 없었습니다.

제 테스트 결과에 따르면, AI 플러그인이 이 버그의 직접적인 원인입니다. 게시물이 올바르게 로드되는 것을 방지하며, 이 동작은 일관되게 재현됩니다. 이 문제는 다른 플러그인이 설치되어 있거나 없거나 관계없이 발생합니다.


이 버그는 커뮤니티의 기능에 심각한 영향을 미치고 있으며, 현재 AI 플러그인을 사용할 수 없는 상태입니다.

혹시 저와 동일한 문제를 겪고 계신 분이 있는지 모르겠습니다. 이 버그를 수정할 수 있을까요? 감사합니다!

4개의 좋아요

Do you see any errors in https://bbs.starorigin.com.cn/logs that might helps?

Hey @shannon1024 - Are you using embeddings by any chance? If so, I suspect we could have failed to migrate the embedding config to the new way. Which embeddings provider are you using? Try disabling ai_embeddings_enabled until we figure it out.

3개의 좋아요

Or… that isn’t configured at all. It happened to me, because I didn’t know there is new setting. Logs gave a hint, though.

Just a proposal — when you guys are introdusing new setting that must be configured, please tell about it.

와, 정말 맞으셨어요! 문제를 완벽하게 짚어주셨네요!!
AI 임베딩 시맨틱 관련 주제 활성화 설정을 켰더니
모든 게시물이 작동하지 않고 열리지 않았습니다.

방금 그 설정을 꺼보니 모든 것이 정상으로 돌아왔어요! 도움을 주셔서 정말 감사합니다!

4개의 좋아요

Great. Which provider are you using for generating embeddings?

I’m really sorry this happened. It was never the intent to leave things unconfigured or in a broken state. We do have a migration that automatically copies the configuration, so something must have gone wrong there. If you could please let me know that, I’ll look into it.

5개의 좋아요

저는 임베딩 생성을 위해 OpenAI 모델을 사용하고 있습니다. 제 경험을 바탕으로 시스템 개선에 도움이 될 수 있는 개인적인 피드백과 제안을 공유하고자 합니다:

  1. AI 설정의 마이그레이션 문제:
    백업을 복원하거나 Discourse 커뮤니티를 마이그레이션할 때, AI 모델의 구성 및 설정(예: API 키, 플러그인 설정)이 올바르게 마이그레이션되지 않습니다. 이로 인해 여러 문제가 발생했으며, 오늘 제가 겪은 문제도 그 중 하나입니다. 예를 들어, 커뮤니티를 마이그레이션하고 백업을 복원한 후에도 AI 모델 설정, API 키, 플러그인 구성이 제대로 이전되지 않아 기능 장애가 발생했습니다.

  2. 혼란을 주는 AI 플러그인 설정 인터페이스:
    현재 AI 플러그인의 설정 인터페이스는 매우 복잡합니다. 예를 들어, 임베딩 모델이 구성되지 않았음에도 불구하고 특정 관련 설정(예: AI embeddings semantic related topics enabled)은 활성화될 수 있습니다. 이는 직관에 반하며 예상치 못한 문제를 초래할 수 있습니다. 또한, 플러그인에는 수십 개의 설정이 한 페이지에 모두 표시되어 탐색하고 설정 간의 관계를 이해하기 어렵습니다.

    • 설정 인터페이스를 Google Search Models, Semantic Embeddings Models, Image Generation Models 등의 기능 섹션으로 정리할 수 있습니다.
    • 특정 AI 모델(예: 임베딩)이 구성되지 않은 경우, 혼란과 오류를 방지하기 위해 관련 설정을 자동으로 비활성화하거나 숨기는 것이 좋습니다.
2개의 좋아요

The issue with the OpenAI’s embeddings config was resolved here:

https://github.com/discourse/discourse-ai/pull/1092

There’s a migration there that will copy the data and set the selected model setting for you unless you have already configured it manually.

Additionally, I merged this change which will help mitigate the impact of the feature being in a broken state due to config:

https://github.com/discourse/discourse-ai/pull/1101


I hear what you said about the configuration being overwhelming. We’ve been working on improving the UX by moving how LLMs are configured, and now we have done the same with embeddings, which led to the removal of +25 site settings. These changes often require us to rewrite a big part of the plugin internals though, so they take time and effort but you can expect things to keep improving over time.

Regarding the restoration issues you mentioned, it’s unclear to me if this is a recurrent issue with the backup not capturing the tables where AI models config live. If so, let me know and I’ll investigate.

For this particular case, the problem was a bug in the database migration I wrote, which grabs data from multiple site settings and inserts a row in the embeddings config table. The bug turned it into a no-op for Open AI models and it’s unrelated to backup/restores.

3개의 좋아요

업데이트와 임베딩 문제의 빠른 수정에 감사드립니다! discourse-ai 플러그인을 개선하고 사용성을 높이기 위해 여러분과 팀이 기울이는 노력에 감사드립니다. 앞으로도 좋은 일 계속해 주세요!

1개의 좋아요

This topic was automatically closed after 20 hours. New replies are no longer allowed.