跳到正文
DEV Community· Nathan Tarbert·· 2 小時前AI 評分48

answerLoops:打造能記住團隊支援答案的開源工具

Your team has answered this before. I’m building a tool that remembers.

AI 導讀

answerLoops 是一款開源社羣支援工具,將 GitHub、Discord、Telegram 等平台的問題集中到儀錶板,並以知識庫協助準備回覆。團隊可手動新增答案、匯入文件,或將已解決工單轉成知識庫文章;Mastra 智能體會生成回覆草稿,另一個智能體負責審核,團隊可檢視、編輯或略過。

正文

I built a tool to help with community support. Then I kept building.

I spend a good part of my day working with the community at CopilotKit, answering questions in Discord, GitHub, and Slack, helping people get unstuck, and pointing them to the right resources.

I started building answerLoops to help me with that work. As it took shape, I added more integrations that fold in additional communities so other teams could use it too.

It’s open source, and I’m building it in public.
Check out answerLoops GitHub ⭐️

A big part of the work has been deciding how knowledge gets into the system. Some answers are in the docs. Others come out of a support conversation or are things someone on the team just knows.

For an agent to use those answers, the team needs a straightforward way to save them, review them, and keep them current. That’s what I’ve been building into the knowledge base.

Answering the question is only part of the work

A question comes in. You find the relevant documentation or resource, figure out how it applies to that person’s setup, and write a reply.

During that conversation, you might discover something the docs don’t cover. A missing setup step, a confusing default, or a workaround that deserves its own article.

You resolve the question, but that useful detail stays buried in the conversation. When someone else asks, the team has to find it again.

I want answerLoops to help with both parts: preparing a useful answer now and saving what the team learns for future questions.

What answerLoops does

Product Flows

answerLoops brings support questions from connected channels (GitHub, Discord, Telegram, etc.) into a dashboard and uses your knowledge base to help prepare answers.

For knowledge-based replies in the ticket pipeline, a Mastra agent generates a draft and a separate agent assesses it. The second agent is only a reviewer and is there to make sure the draft is concise and accurate. The team can then review, edit, or dismiss the draft in the dashboard.

There’s also an embeddable website chat widget built with CopilotKit and connected to a Mastra support agent. Visitors can ask questions directly, with published knowledge-base articles supplied as reference material.

The widget now supports richer responses, including step-by-step guides, quick replies, callouts, link cards, and contact options.

But the quality of those answers depends on the information available to the agent. That’s why much of the recent work has been on the knowledge base.

Add the answer that isn’t in your docs

Add Knowledge

Sometimes you don’t need to import a documentation site. You just need to write down something the agent should know.

An owner or admin can open Knowledge Base → Manage and use Write an answer by hand:

  1. Enter a question or title.
  2. Write the answer or context.
  3. Click Add to knowledge base.

For example, a customer might ask whether changing a configuration requires a restart. Someone on your team knows the answer, but it isn’t documented anywhere.

They can add that explanation directly.

The article is published and indexed when it’s saved, making it available for subsequent questions. There’s no draft step in this form, so the answer should be suitable for customers to read.

Articles added this way appear under Added by hand in the Knowledge coverage tab.

It’s a small feature, but it gives the person with the answer a direct way to improve what the agent knows.

Bring in the knowledge you already have

Knowledge sources

You can also populate the knowledge base from existing content:

  • Documentation URLs: import a page or crawl a documentation site.
  • Files: upload PDF, DOCX, Markdown, text, or CSV files.
  • GitHub: sync Markdown and MDX files, with optional syncs when changes are pushed to the default branch.
  • Notion: connect pages and databases your team wants to use.

Notion content imports unpublished. Your team can inspect it before making it available for customer-facing answers, and that publishing choice is preserved across syncs.

The manual-entry form sits alongside these sources. If an answer already exists in your docs, import it. If it only exists in someone’s head, write it down.

Turn a resolved ticket into reusable knowledge

A resolved ticket can contain an explanation worth keeping.

The Promote to KB action lets an owner or admin turn that ticket’s question and answer into a knowledge-base article.

Before promoting it, check that the answer applies beyond the original conversation. Remove account-specific details and make the explanation useful to someone encountering the same problem later.

This matters for the website widget in particular. Its retrieved reference material comes from published KB articles, rather than raw resolved tickets.

Promoting an answer gives it a place in the shared knowledge base where the widget can find it.

Let customer questions help you decide what to write

You won’t know every gap in your documentation ahead of time.

The Review tab captures questions that weren’t covered by the available knowledge. On hosted plans, this queue is available on Pro and above.

A usable draft can come along as a starting point. If there isn’t one, the item is marked No usable answer, and someone can write it.

Owners and admins can:

  1. Edit the question and answer.
  2. Click Approve and add to knowledge base.
  3. Or reject the item.

Nothing in the queue becomes searchable customer-facing knowledge until it’s approved.

When the same question comes in again, its counter increases instead of creating another copy. The most-asked questions appear first.

That gives the team a practical place to start. If several people are asking about the same setup step, writing one good answer is probably worth the time.

Go from a knowledge gap to a new article

Review and gaps

The Knowledge Gaps page provides another view of where support needs attention.

It surfaces tickets with low-confidence answers, tickets that need a person, and resolved questions without a covering KB article.

Repeated questions are grouped with an Asked N times badge, so you can see recurring topics without reading every ticket separately.

The + KB action opens the manual-entry form with the ticket’s question and any existing answer filled in. Review the text, add the article, and it’s linked back to the ticket to close that gap.

You don’t have to leave the question behind and start a blank document somewhere else.

Check what the agent can actually find

Coverage

Importing a document doesn’t tell you whether it will help with a particular question.

The Knowledge coverage tab shows articles grouped by source, including whether they’re live, unpublished, or not searchable.

There’s also a Try a customer question field. It runs the same lookup the website widget uses and shows which articles match—or that nothing covers the question.

After adding an answer, you can try a few ways a customer might ask about it and inspect the results.

This checks retrieval, not whether every generated reply will be correct. You still need to review the answers themselves. But it gives you a way to investigate whether the intended information is being found.

The KB is the source of product knowledge your team maintains for the agent. If no article matches, the assistant can fall back to general knowledge, which may not fit your product. Finding those gaps and adding the right material is part of maintaining it.

See which articles are being used

Article usage

The latest release also adds article usage tracking.

answerLoops counts when an article is supplied as context for an answer that is actually produced, including website replies and ticket drafts.

The distinction matters: this means the article was given to the agent, not necessarily that the final reply quoted it.

Searches and simulations don’t increase the count.

Together with the coverage view and repeated-question counts, this helps you understand what information is being retrieved and where more work might be useful.

Where CopilotKit and Mastra fit

I work in DevRel at CopilotKit, so part of building answerLoops is putting the tools I work with into a product and sharing what I learn.

Mastra runs the agents behind the support drafts and website conversation, including the chat agent’s thread memory.

CopilotKit provides the foundation for the custom widget interface. The application connects that interface to the agent and supplies the relevant knowledge-base context.

The product also has its own workflows around those pieces: importing sources, reviewing unanswered questions, publishing articles, and handling staff actions on tickets.

Those workflows are where the team gets to improve the information the agent uses. Someone can spot a missing answer, write it, publish it, and check whether a future question retrieves it.

That’s become a much bigger part of answerLoops as I’ve kept building.

Try it and tell me what’s missing

I started this to help with my own community work. I’m sharing it so other developers and support teams can try it in theirs.

The code and setup instructions are on GitHub, and the knowledge-base documentation walks through these workflows.

If it looks useful, give the repo a ⭐️ star which helps others find it. If you try it, I’d like to hear all of your feedback.

If you're new to open source, just reach out, I'd love to help. I've

Where does your team keep the useful answers that haven’t made it into the docs yet?

來源:DEV Community · dev.to