Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

How I Built a Slack Bot That Answers Codebase Questions With Claude

Description and use

A Slack bot powered by Claude and simple code‑search tools answers structural code questions in seconds, saving engineers time and building trust through path validation.

Problem

Engineers spent excessive time manually searching code for answers to structural questions like "Where does X live?" or "How does Y work?", costing about 20 minutes per question and reducing productivity.

Outcome

The bot answers most questions in 20–45 seconds, with a median latency of 20 seconds. API costs are negligible compared to the time saved, and the system improves trust by validating file paths before replying.

Workflow

  • 1. User mentions bot in Slack with a question.
  • 2. Bot receives mention and forwards to Claude agent loop.
  • 3. Claude decides to use "search_code" tool to find regex matches in repo.
  • 4. Bot runs ripgrep via subprocess, returns limited matches.
  • 5. Claude reads matched files using "read_file" tool, follows imports and references.
  • 6. After a few tool calls, Claude produces a final answer with file paths and line numbers.
  • 7. Bot validates all referenced paths against actual repo tree to prevent hallucinations.
  • 8. Bot posts answer in Slack thread.

Evidence

Early on, the bot answered a question with a confident reference to utils/validation.py — a file that did not exist.

Source

Median answer latency is around 20 seconds end-to-end, the slowest multi-hop investigations land near 45.

Source

A month of real usage cost less than a single takeout lunch in API fees.

Source

  • Record date: 2026-09-21T08:00:38.503Z