مراجعة سنوية لDiscourse

:discourse2: Summary Discourse Yearly Review creates a topic on January 1st that summarizes the previous year’s forum activity. (See our examples here on Meta - year-in-review)
:hammer_and_wrench: Repository Link https://github.com/discourse/discourse-yearly-review
:open_book: Install Guide How to install plugins in Discourse

Initial Setup

Head to your /admin/plugins page to click the discourse-yearly-review :gear: Settings button:

Yearly Review settings

  1. Enter categories to pull data from into the yearly review categories setting. If left blank, it will default to the top 5 public categories.

  2. Using the yearly review publish category setting, choose a destination category for the review to be posted.

    :bulb: It is highly recommended to set the yearly review publish category to the staff or other private category so that you can view the topic before making it public. You might also like to edit it first.

  3. Then, enable the plugin using the yearly review enabled setting.

Features

As you can see at 2022: The Year in Review, data is displayed in two sections - users and topics.

The users section includes:

  • Most Time Reading
  • Most Topics Created
  • Most Replies Created
  • Most Replied to
  • Most Likes Given
  • Most Likes Received
  • Most Visits
  • Users who have been granted a featured badge (the badge is set by the yearly review featured badge Site Setting

The topics section includes:

  • Most Read
  • Most Liked
  • Most Replied to
  • Most Popular
  • Most Bookmarked

Generating the Yearly Review

The plugin sets thresholds for deciding which topics to display. There need to be a minimum of 10 likes or replies, 5 bookmarks, a score of 10, or one hour’s read time before a topic will be displayed. The topic is published automatically through a background job. The job checks that the plugin is enabled and that it is within the first 31 days of the first month of the year. It then checks to see if a topic with the title yearly_review.topic_title has already been published by the system user. If all checks pass, the topic is published to the category set in the yearly review publish category setting. If this is not configured, the topic will be published to the Uncategorized category.

Extra Options

Yearly review categories

Categories used in this section are those set in the yearly review categories Site Setting. If this setting is not configured, the 5 best public categories from the forum will be chosen. “Best” is determined by the category topics_year count.

Sub-categories of any categories specified in the yearly review categories Site Setting will not be included in the yearly review report. If you want sub-categories to be included in the yearly review report, you will need to explicitly specify them in the yearly review categories Site Setting.

Yearly review exclude staff

The plugin has a yearly review exclude staff setting. It is enabled by default so that staff members are excluded from the users section and topics created by staff are excluded from the topics section.

Yearly review featured badge

A featured badge can be set via the yearly review featured badge setting. A maximum of 15 badge users are displayed. If more than 15 users have been granted this badge, a link to the badge’s page is displayed. If the yearly review featured badge is not configured, this section will not be displayed.

Running the Yearly Review manually

If you don’t want to wait for the background job, you can publish the topic from the rails console with:

Jobs::YearlyReview.new.execute(force: true)

If you want to generate a report for a specific year just add review_year: 'year', e.g.:

Jobs::YearlyReview.new.execute(force: true, review_year: '2021')

:discourse2: Hosted by us? If you would like to run the Yearly Review manually you can contact us at team@discourse.org and we’ll be happy to arrange that for you.

Settings

Name Description
yearly review enabled Enable the yearly review.
yearly review categories Public categories to pull topics from. The top 5 categories from this group will be selected. If left blank will default to the top 5 public categories.
yearly review exclude staff Exclude Staff from user stats.
yearly review include user stats Add user-identifying stats to the first post of the review topic.
yearly review include private categories Include user activity from private or read-restricted categories in the review.
yearly review publish category The category the review will be published in.
yearly review featured badge Enter the full badge name. Can be left blank.

:discourse2: Hosted by us? This plugin is available on all of our hosting tiers Yearly Review | Discourse - Civilized Discussion


Known Issues

  • The data is displayed in HTML tables. Tables are wrapped in div tags that have data-review-topic-users="true' and data-review-featured-topics="true" attributes. This allows the tables to be styled when they are displayed on Discourse. The styles are not copied when emails for the topics are created. Emails sent out for the topic don’t look great.

  • The first post in the generated topic is ≈ 40,000 characters due to using HTML. As a result, it cannot be edited unless you first increase the body character limit above this (see Body is limited to 32000 characters; you entered 43659)

  • emojis in titles are not rendered in the featured topic links

Last edited by @nathank 2025-01-06T21:23:15Z

Check documentPerform check on document:
88 إعجابًا

بعض التحسينات الرائعة التي يمكن إجراؤها على هذا المكون الإضافي، آمل أن أشارك هذا في المكان الصحيح؟ أخبرني إذا لم يكن كذلك.

  • القدرة على استبعاد الموظفين من قائمة المستخدمين، ولكن لا يزال تضمين الموضوعات التي ينشئونها
  • القدرة على استبعاد TL4 من قائمة المستخدمين (ومثل أعلاه، لا يزال تضمين الموضوعات التي ينشئونها)
  • القدرة على إنشاء منشورات مراجعة متعددة حتى نتمكن من الحصول على واحدة لـ TL4 (نستخدم هذا للموظفين) وأعضاء هيئة التدريس، ثم الحصول على منشور لأعضاء المجتمع فقط
5 إعجابات

مرحباً!
لقد قمت بتثبيت الإضافة هذا العام، ولكن على الرغم من تمكينها، لا أعرف متى يتم نشر المراجعة، أو ما إذا كان يجب عليّ فعل أي شيء آخر لنشرها.
هل يمكن لأي شخص إخباري؟
شكراً جزيلاً!!

إعجابَين (2)

تحياتي @Ayelen_Rives،

عند فحص لوحة التحكم الإدارية، ستُعرض لك المساعدة البصرية التالية:

المزيد من التدقيق داخل المكون الإضافي بعنوان ‘plugin:discourse-yearly-review’ يكشف عن مثال توضيحي آخر:

من الضروري أنه أثناء تكوين الإعدادات، تقوم بتعيين فئة نشر المراجعة السنوية إما للموظفين أو فئة مقيدة أخرى. هذا يضمن مراجعة أولية قبل السماح برؤية أوسع.

6 إعجابات

شكراً جزيلاً لك يا آرون!

بشكل غير متوقع، لا أرى تلك الرسائل في لوحة التحكم الإدارية، ولا في الإعدادات:

فئة النشر هي “الموظفون”، لذا سأكتشف في 1 يناير إذا تم إنشاؤها.

شكراً مرة أخرى وعطلة سعيدة!

إعجابَين (2)

سنة جديدة سعيدة! :partying_face:

لم يتم تشغيل المكون الإضافي هنا في منتدين. والآن يعرض الرسالة الخاصة بتاريخ 1 يناير 2025. غريب.

لقد قمت بتشغيله يدويًا في وحدة تحكم rails في أحد المنتديات وعاد باللغة الإنجليزية، وليس الألمانية، وهي لغة المنتدى.

هناك خطأ ما / كان هناك خطأ ما هنا.

إعجابَين (2)

لم يصل إلى هنا على ميتا بعد أيضًا. لقد اتبعت النصيحة وقمت بتعيينه للنشر على #staff أولاً، وهو ما أعتقد أنه الاختلاف الوحيد عن العام الماضي؟

كنت آمل أن يظهر بشكل سحري مع قليل من الصبر، لكن ربما أكون متفائلاً.

إعجابَين (2)

لم أقم بتغيير أي شيء في الإعدادات، حتى المنتدى للتحقق منه أولاً كعضو في فريق العمل ثم نقله،

في منتداي الثاني لا يوجد شيء بعد. والساعة الآن 11:24 صباحًا لدي.

يبدو أن هناك خطأ ما.

هل هناك حاجة لعلم لغة عند تشغيله يدويًا؟ لا أريد ترجمة كل شيء في المنتدى الثاني أيضًا. :wink:

إعجاب واحد (1)

قد أكون مغريًا لترك الأمر لفترة أطول لمعرفة ما إذا كان هناك تأخير في المهمة الخلفية، لكنني لست متأكدًا أيضًا من سبب إعطاء تشغيلها يدويًا نتيجة مختلفة عن تشغيل المهمة الخلفية بنفسها؟

قد نحتاج إلى شخص أكثر معرفة للمساهمة.

3 إعجابات

لم يعمل تلقائيًا ولكني قمت بتشغيله يدويًا ويبدو أنه عمل بشكل جيد، على الرغم من أنني لم أكن أريده بلغة مختلفة.

إعجاب واحد (1)

صباح اليوم تقريبًا، أخبرني sidekiq أن المراجعة السنوية ستتم جدولتها في غضون 50 دقيقة، وفي الوقت الحالي سيكون ذلك حوالي الساعة 11 صباحًا بالتوقيت المحلي. لم أنتظر، على الرغم من ذلك، وقمت بذلك يدويًا. لم تكن هناك مشاكل وكانت اللغة صحيحة أيضًا.

بعد ذلك، اضطررت إلى تخفيض رتبة المشرفين لدي وإعادة تشغيل sidekiq لأنهم كانوا مستائين حقًا - لقد استبعدت الموظفين… لم أستطع السماح للموظفين لأنني كمسؤول نشط حقًا كنت سأسيطر على القوائم تمامًا، لذلك اخترت أسرع طريق.

حسنًا، هذه قصة مختلفة، ولكن هل يمكن أن يكون لدينا المزيد من الحرية في تضمين أو استبعاد المجموعات؟

إعجابَين (2)

يا إلهي… في المنتدى الآخر، يوجد موضوع 2023… الساعة 2:31 مساءً بالتوقيت المحلي. وباللغة الألمانية. لذا، لا يزال غامضًا…

إعجاب واحد (1)

لقد قمت بتشغيل نظامنا من Sidekiq في النهاية. :rocket:

إعجابَين (2)

على مواقعي، تم إنشاء الموضوع دون الحاجة إلى تشغيله يدويًا في sidekiq.

هذه اقتراحات رائعة. شكرا لك! من المثير للاهتمام سماع المزيد من حالات استخدام هذا المكون الإضافي. سننظر في هذا بشكل أوثق قريبًا بناءً على تجربة هذا العام، لمعرفة ما يمكننا فعله لتحسينه قبل العام المقبل!

في هذه الأثناء، لهذه الجولة، يمكنك تعديل المنشور بمجرد نشره كما تراه مناسبًا.

أحد السلوكيات المثيرة للاهتمام التي لاحظتها هو أنه إذا قمت بحذف الموضوع الذي تم إنشاؤه، فسيتم إنشاء موضوع جديد في اليوم التالي، طالما أن المكون الإضافي ممكّن. لذلك يمكنك اللعب بالإعدادات وإنشاء إصدارات متعددة من موضوع المراجعة السنوية، ونسخ النص منها، ثم نشر مواضيع جديدة بنفسك كما تراه مناسبًا. إذا كان لديك وصول إلى /sidekiq، يمكنك العثور على المهمة هناك وتشغيلها على الفور.

إعجابَين (2)

ولهذا السبب فإن النصيحة بنشر المراجعة أولاً في فئة أكثر خصوصية، أي الموظفين، ثم نقلها إلى فئة عامة، هي في الواقع نصيحة ليست جيدة :wink: إلا إذا أراد مسؤول الاحتفاظ بنسختين.

ليس بالأمر الكبير، مع ذلك.

إعجاب واحد (1)

مرحباً! لحسن الحظ، قام المكون الإضافي بتشغيل نفسه في الأول من يناير دون أي مشكلة! :raised_hands:

أنا الآن لدي بعض الأسئلة حول كيفية عمله لأن بعض التقارير (مثل “أكثر المواضيع” و “أكبر عدد من الإعجابات المقدمة”) تظهر نتائج مختلفة عن صفحة المستخدمين لنفس الفترة.

على سبيل المثال، بالنسبة لـ “أكثر المواضيع”، تظهر صفحة المستخدمين أولاً المستخدم “S”:

ويظهر الاستعراض السنوي أولاً المستخدم “C” ولا يظهر المستخدم “S” أبداً في الجدول:

(عذراً، اضطررت إلى طمس الصور لأسباب تتعلق بسرية الشركة، لكن أعتقد أنها أوضح إذا أضفتها. أيضاً، الجدول معطل، يمكنك تجاهله :upside_down_face:)

هل يعرف أي شخص سبب حدوث ذلك؟ تظهر التقارير الأخرى نفس المعلومات بالضبط، ولكن “أكثر المواضيع” و “أكبر عدد من الإعجابات المقدمة” تظهر مستخدمين مختلفين.

شكراً جزيلاً لمساعدتكم! :100:

إعجاب واحد (1)

واو، لم أكن على علم بأن هذا ما يحدث. لقد اختبرت ذلك للتو وأنت على حق! هذه مشكلة. لا ينبغي إنشاء موضوع مراجعة سنوي ثانٍ إذا كان موجودًا بالفعل.

خطوات التكرار:

  1. بمجرد إنشاء موضوع المراجعة السنوي، انقله إلى فئة مختلفة
  2. قم بتشغيل إنشاء موضوع المراجعة السنوي عبر /sidekiq
  3. يتم إنشاء موضوع المراجعة السنوي الثاني.

إذا واجهت هذه المشكلة، أقترح تعطيل المكون الإضافي. سننظر في هذا المكون الإضافي قريبًا لإصلاح الأخطاء وتحسينه قبل العام المقبل.

إعجاب واحد (1)

:thinking: ما مدى استمراريته؟ إذا واصلت حذفه، فهل سنظل نرقص في يونيو؟ :joy:

وهل هذا يعني أنني لست بحاجة إلى التواصل مع الدعم لإنشاء المنشور بأثر رجعي لموقعي؟ هل سيظهر غدًا؟

إعجاب واحد (1)

حقًا. إنه يعمل عبر Sidekiq كل يوم.

إعجاب واحد (1)

آمل أن يتوقف في نهاية يناير.

إعجابَين (2)