Tracking: trace answers to the knowledge-base articles supplied to them

Ouverte
#88 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Personne n'a encore pris cette issue.

Évaluation

Difficulté
5/5
Temps estimé
Plus d'une semaine
Accessibilité débutants
12/100
Type d'issue
Fonctionnalité
Clarté
Plutôt claire
Activité
Active
Stack technique
sql, typescript
Domaine
analytics, backend

Piste de recherche

This is a tracking issue for a multi-issue series, so start from a child issue, not this one; #429 is the first to pick up. Read countArticleUsage and the kb_article_usage table to see how supplied-context counts are written today, and content/docs/product/knowledge-base.mdx, which every child issue must update. Done means the child issue's acceptance points and regression tests pass, with the existing count labeled "Supplied as context".

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Description

backend enhancement frontend help wanted

Copied from DeadantCo/answerLoops#78 · originally opened by sethr07 on 2026-11-20

Copied from https://github.com/answerLoops/answerLoops/issues/422 — originally opened by @NathanTarbert on 2026-10-21

Tracking issue. The work is split into the issues below, in the order they should land.

Problem

Teams need to trace a generated answer to the knowledge-base articles supplied to it, and tell context exposure apart from evidence that an article contributed to the answer.

countArticleUsage receives article ids from the supplied context without looking at the answer, and adds one to a per-article, per-day count in kb_article_usage. If A, B and C are supplied but the reply reflects only A, all three get a count. The metric describes context exposure, not contribution, quality or delivery. It also is not displayed anywhere in the dashboard today (a pull request, #441, is in progress to show it for #429), and there is no answer-to-article history.

How the series fits together

  • Answer sources (#429 to #432) are facts only: what was supplied to each answer, in what rank, and at which revision. No judgment about the answer.
  • The separate source-support series is tracked in #437 and builds on these records.
  • Article freshness is tracked separately in #453.
  • Article history is tracked in #423.

Plan

  • Show the existing count in the dashboard, labeled "Supplied as context": #429
  • Answer-references storage, with written retention and access decisions: #430
  • Record references from the widget, Discord, Agent API and ticket paths: #431
  • Inspect an answer's sources and an article's recent answers: #432

The storage issue reuses the content-hash revision helper added in the article event log issue under #423, so land that first.

Principles every issue follows

  • Historical counts keep their meaning: "supplied as context".
  • Searches and simulations stay separate from production usage.
  • Retries and repeated completion callbacks never double-count an answer, and duplicate passages count once per article per answer.
  • Editing, re-syncing or deleting an article never silently rewrites what an existing trace represents.
  • No question text, answer text or visitor identity is stored with references.
  • Unassessed means unassessed, never "unused". Contribution claims always show their method and evidence, and ambiguous results stay inconclusive.
  • Each issue updates content/docs/product/knowledge-base.mdx and adds regression tests.

Related: #423 covers who added and verified an article. Freshness policy, such as product-version stamps and downweighting outdated articles, is a separate design: an old article may be correct, and a frequently supplied one may be outdated.

Start here: new to the project? Read CONTRIBUTING.md first. It covers the ground rules, running answerLoops locally, and how to open a pull request.

Langage dominant
TypeScript
Étoiles
0
Forks
0
Métriques de merge des PR
Aucune PR mergée en 30 j

Préparer son environnement

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de DeadantCo/answerLoopsdev

Toutes les issues de DeadantCo/answerLoopsdev

Issues similaires

Plus d'issues TypeScript

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.