Dosu LogoDosu Logo
Ask
Join our Discord
Organization avatar
HelmorPublic
Caspian's Workspace
DocumentsHelmor
AGENTS
AGENTS
Type
External
Status
Published
Created
Jul 14, 2026
Updated
Jul 14, 2026
Source
backend/AGENTS.md

CLAUDE.md#

This file provides guidance to coding agents when working with code in this repository.

Build & Development Commands#

# Install dependencies
poetry install

# Run unit tests
make test-unit
# Or directly:
poetry run pytest tests/

# Run a single test file
poetry run pytest tests/path_to_my_test_file.py

# Run tests with print output
poetry run pytest -s tests/

# Run tests in watch mode
poetry run ptw . -v tests/path/to/test.py

# Run integration tests (requires Docker)
make test-integration
# Or if services are running locally:
poetry run pytest tests/integration

# Linting (runs pre-commit on changed files)
make lint

# Manual formatting/linting
poetry run ruff check .
poetry run black .

# Type checking
poetry run mypy <module>

# Update snapshot tests
make test-update-snapshots

Docker Development#

# Build and start all services
make all-up

# Lightweight agent development (less resource-intensive)
make agent-up

# Interactive shell in dev container
make ipython # or: make bash

# Start specific services
make public-api-up
make search-up

Architecture Overview#

This is a Python backend monolith for Dosu, an AI assistant that monitors GitHub, Slack, Linear, and other platforms to help with knowledge management and thread intelligence.

Core Directories#

DirectoryPurpose
core/Shared infrastructure - database clients, AI/LLM integration, external service integrations (GitHub, Slack, Notion, etc.), utilities
agent/Agent system - workflows, tasks, tools, retrieval logic
workflows/DBOS durable workflows for agent orchestration
api/Internal API - GitHub/Slack event handling, publishing responses
public_api/Public REST API - chat, docs, answers, OAuth, webhooks
internal/Internal-only APIs - DBOS workflow endpoints, event handlers
cloudfunctions/Webhook handlers (GitHub, Linear, Billing, Slack)
data_syncing/Background data sync (GitHub, Confluence, Notion, Slack, etc.)
search/Search service (FastAPI) with semantic and full-text search

Application Entry Points#

  • Internal API: api/main.py - Main FastAPI app for event handling
  • Public API: public_api/main.py - Public-facing REST endpoints
  • Internal API: internal/main.py - DBOS workflows and internal endpoints
  • Search: search/main.py - Standalone search service

Key Patterns#

Event Flow: External webhook -> CloudFunction -> DBOS Queue -> Pub/Sub -> Agent Router -> Workflow -> Publish response

Workflow Composition: Workflows use pipe operator composition:

PreliminaryChecks() | Ack() | OrchestrateWorkflow()

Database: Supabase PostgreSQL with Row-Level Security (RLS). Use Engine.begin_as_user() for user-scoped queries.

Vector Search: LanceDB for semantic search over documents.

Module Dependencies: Enforced via tach.toml. Key allowed dependencies:

  • agent depends on core, workflows
  • workflows depends on core, api, search, data_syncing
  • public_api depends on core, agent, workflows, data_syncing

Test Organization#

  • tests/ - Unit tests (run by default with pytest)
  • tests/integration/ - Integration tests (excluded by default, run explicitly)
  • tests/e2e/ - End-to-end tests (excluded by default)

Integration and E2E tests require explicit paths: poetry run pytest tests/integration

Configuration#

Environment files loaded in order: .env -> .env.development -> .env.development.local

Key config in core/config.py and core/base_config.py.

Documents
01 - Get Started
01 - Introduction
02 - Install Helmor
03 - Add a Repository
04 - Create a Workspace
05 - Send Your First Agent Task
02 - Core Concepts
01 - Repository
02 - Workspace
03 - Session
04 - Agent
05 - Changes and Review
06 - GitHub Integration
03 - User Workflows
01 - Start a New Task
02 - Review Agent Changes
03 - Continue an Existing Session
04 - Commit and Ship Work
05 - Use Multiple Agents Safely
04 - Developer Setup
01 - Local Development Setup
02 - Architecture Overview
03 - Frontend Overview
04 - Backend Overview
05 - Sidecar Overview
06 - Testing Guide
07 - Debugging Guide
05 - Troubleshooting
01 - Agent Not Responding
02 - GitHub Authentication Issues
03 - Workspace Errors
04 - Sidecar and CLI Issues
05 - Logs and Diagnostics
7-data-driven-checks-to-ensure-your-documentation-roi-is-high
AGENTS
AGENTS
AGENTS
CHANGELOG
CLAUDE
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
README
SKILL
SKILL
SKILL
STRIPE_README
[tag]
_template
advanced-full-text-search
advanced-jsonb-indexing
ai-contributions-open-source
ai-is-better-at-maintaing-docs-than-humans
april-2025-newsletter-dosu-does-docs
august-2025-dosu-drop
automating-github-issue-triage
better-agent-testing-with-distributed-dependency-injection
blog_template
building-the-future-of-knowledge-management-june-dosu-drop
celery-preserializers-a-low-friction-path-to-pydantic-support
channel-creation-github-repository
channel-creation-slack-channel
ci-jobs
cncf-dosu-case-study
combating-open-source-maintainer-burnout-with-automation
concepts-channel
concepts-data-sources
concepts-interactions
configuration
confluence_edited_markdown
confluence_original_markdown
conn-idle-timeout
conn-limits
conn-pooling
conn-prepared-statements
data-batch-inserts
data-n-plus-one
data-pagination
data-upsert
december-2025-dosu-drop
default
devin
docling-open-source-growth-with-dosu
dosus-new-fact-based-reasoning-agent-is-generally-available
features-auto-labeling
features-generate-docs
features-issue-triage-qa
features-maintain-docs
february-2025-newsletter-introducing-spaces
from-maintenance-to-innovation-freeing-developers-with-ai-automation
george-xu
github-configuration
github-features-dosu-in-first-awesome-continuous-ai-list
github-installation
how-dosu-used-langsmith-to-achieve-a-30-accuracy-improvement-with-no-prompt-engineering
how-lancedb-supercharged-our-knowledge-graph
how-preset-keeps-apache-superset-healthy
how-triliumnext-revitalized-an-abandoned-open-source-project-with-dosus-help
index
index
internal-vs-external-documentation-audience-first
iterating-towards-llm-reliability-with-evaluation-driven-development
january-2026-dosu-drop
july-dosu-drop-public-spaces-enter-the-chat
knowledge-management-in-the-ai-era-why-documentation-is-more-critical-than-ever
li-zheng
lock-advisory
lock-deadlock-prevention
lock-short-transactions
lock-skip-locked
march-2025-newsletter-dosu-knows
marcos
markdown
mastering-auto-labeling-taming-the-backlog-with-intelligent-labels
may-2025-dosu-drop-new-agent-self-serve-pricing-fresh-look
member-invitation
michael-ludden
michael-mangus
migrate-celery-to-dbos-dosu
monitor-explain-analyze
monitor-pg-stat-statements
monitor-vacuum-analyze
notion_edited_markdown
notion_original_markdown
november-2025-dosu-drop
october-2025-dosu-drop
onboarding-introduction
onboarding-key-concepts
onboarding-quickstart
open-source-labeling-best-practices
page
page
pages
photos
pull_request_template
query-composite-indexes
query-covering-indexes
query-index-types
query-missing-indexes
query-partial-indexes
reliable-data-orchestration-for-ai-applications
response-previews
scaling-support-and-documentation-at-Dify-one-of-the-fastest-growing-oss-projects
schema-data-types
schema-foreign-key-indexes
schema-lowercase-identifiers
schema-partitioning
schema-primary-keys
security-privileges
security-rls-basics
security-rls-performance
september-2025-dosu-drop
settings
slack-configuration
slack-installation
sparrowhawk
taylor-dolezal
the-code-understanding-paradox-when-ai-makes-writing-code-fast-but-understanding-it-slow
top-5-zombie-problems-resurrected-by-ai-tools
using-ai-to-generate-and-maintain-documentation
what-lodashs-issue-backlog-reveals-about-oss-burnout
what-the-mythical-man-month-got-right-about-documentation
word2vec-to-transformers-ai-evolution