# fikricghuv/testpilot-test-manager architecture

> Architecture diagram of the GitHub repository fikricghuv/testpilot-test-manager, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-29). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/fikricghuv/testpilot-test-manager
- Repository: https://github.com/fikricghuv/testpilot-test-manager

## Overview

TestPilot is a self-hosted test-management product: teams organize cases and suites, assemble plans or cycles, record execution outcomes, and inspect project reports. Its backend also supports AI-assisted quality workflows, knowledge retrieval, automation, performance testing, and external integrations. The principal manual workflow is documented in the README; most frontend-to-backend wiring and several listed subsystems were not sampled, so those connections are omitted or marked unverified rather than inferred.

Main entry points: [`Testpilot-Backend-Nest/src/database/database.service.ts`](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/database/database.service.ts) (PostgreSQL and pgvector), [`Testpilot-Backend-Nest/src/nyra/nyra-review.service.ts`](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/nyra/nyra-review.service.ts) (Nyra review flow), [`Testpilot-Backend-Nest/src/rag/rag-retrieval.service.ts`](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/rag/rag-retrieval.service.ts) (Knowledge retrieval), [`Testpilot-Backend-Nest/src/legacy/legacy.controller.ts`](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/legacy/legacy.controller.ts) (Project API)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_workspace["Test management"]
  node_testcase_ui["Case repository<br/>[page.tsx]"]
  node_project_ui["Project workspace<br/>[page.tsx]"]
  node_cycle_ui["Cycles and runs<br/>[page.tsx]"]
  node_legacy_api["Project API"]
  node_legacy_domain["Project and case services<br/>[legacy.service.ts]"]
end

subgraph group_intelligence["AI and knowledge"]
  node_review_ui["Review board<br/>[ReviewBoard.tsx]"]
  node_review_api["Review endpoints"]
  node_review_service["Review analysis"]
  node_rag_ingestion["Knowledge ingestion"]
  node_rag_retrieval["Knowledge retrieval"]
  node_embedding_allocation["Embedding allocation"]
  node_ai_eval["AI evaluation<br/>[ai-eval.types.ts]"]
  node_nyra_review["Nyra review flow"]
end

subgraph group_execution["Test execution"]
  node_automation["Browser automation"]
  node_performance["Performance testing"]
end

subgraph group_platform["Identity and platform"]
  node_database[("PostgreSQL and pgvector")]
  node_storage[("File storage<br/>[storage.service.ts]")]
  node_auth["Authentication<br/>[auth.controller.ts]"]
  node_billing["Billing"]
end

subgraph group_connectors["Integrations and reporting"]
  node_integration_sync["Integration sync"]
  node_analytics["Analytics reports"]
end

node_user(("QA team member"))

node_user -->|"organizes cases"| node_testcase_ui
node_user -->|"records outcomes"| node_cycle_ui
node_testcase_ui -.->|"submits case requests"| node_legacy_api
node_cycle_ui -.->|"submits run requests"| node_legacy_api
node_legacy_api -->|"delegates project actions"| node_legacy_domain
node_review_ui -.->|"requests decisions"| node_review_api
node_review_api -->|"delegates review actions"| node_review_service
node_review_service -->|"reads test cases"| node_legacy_domain
node_rag_ingestion -->|"updates embedding state"| node_database
node_rag_retrieval -->|"queries knowledge"| node_database
node_rag_retrieval -->|"resolves embedding provider"| node_embedding_allocation
node_nyra_review -->|"reads and writes review data"| node_database
node_nyra_review -->|"uses project services"| node_legacy_domain
node_nyra_review -->|"checks embedding availability"| node_embedding_allocation
node_nyra_review -.->|"uses knowledge context"| node_rag_retrieval
node_storage -.->|"stores file metadata"| node_database
node_auth -.->|"authenticates"| node_user
node_integration_sync -.->|"persists sync state"| node_database

click node_testcase_ui "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Frontend/app/(app)/projects/%5Bid%5D/testcases/page.tsx"
click node_project_ui "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Frontend/app/(app)/projects/page.tsx"
click node_cycle_ui "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Frontend/app/(app)/projects/%5Bid%5D/cycles/page.tsx"
click node_legacy_api "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/legacy/legacy.controller.ts"
click node_legacy_domain "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/legacy/legacy.service.ts"
click node_review_ui "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Frontend/components/agents/ReviewBoard.tsx"
click node_review_api "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/review-board/review-board.controller.ts"
click node_review_service "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/review-board/review-board.service.ts"
click node_rag_ingestion "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/rag/rag-ingestion.service.ts"
click node_rag_retrieval "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/rag/rag-retrieval.service.ts"
click node_embedding_allocation "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/rag/rag-ai-allocation.ts"
click node_ai_eval "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/ai-eval/ai-eval.types.ts"
click node_nyra_review "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/nyra/nyra-review.service.ts"
click node_automation "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/automation/automation.controller.ts"
click node_performance "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/performance-tests/performance-tests.controller.ts"
click node_database "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/database/database.service.ts"
click node_storage "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/storage/storage.service.ts"
click node_auth "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/auth/auth.controller.ts"
click node_billing "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/billing/billing.controller.ts"
click node_integration_sync "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/integration-sync/integration-sync.service.ts"
click node_analytics "https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/analytics-report/analytics-report.service.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_testcase_ui,node_project_ui,node_cycle_ui,node_legacy_api,node_legacy_domain toneBlue
class node_review_ui,node_review_api,node_review_service,node_rag_ingestion,node_rag_retrieval,node_embedding_allocation,node_ai_eval,node_nyra_review toneAmber
class node_automation,node_performance toneMint
class node_database,node_storage,node_auth,node_billing toneRose
class node_integration_sync,node_analytics,node_user toneIndigo
```

## Components

### Test management

- [Case repository](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Frontend/app/(app)/projects/%5Bid%5D/testcases/page.tsx): `Testpilot-Frontend/app/(app)/projects/[id]/testcases/page.tsx`
- [Project workspace](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Frontend/app/(app)/projects/page.tsx): `Testpilot-Frontend/app/(app)/projects/page.tsx`
- [Cycles and runs](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Frontend/app/(app)/projects/%5Bid%5D/cycles/page.tsx): `Testpilot-Frontend/app/(app)/projects/[id]/cycles/page.tsx`
- [Project API](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/legacy/legacy.controller.ts): `Testpilot-Backend-Nest/src/legacy/legacy.controller.ts`
- [Project and case services](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/legacy/legacy.service.ts): `Testpilot-Backend-Nest/src/legacy/legacy.service.ts`

### AI and knowledge

- [Review board](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Frontend/components/agents/ReviewBoard.tsx): `Testpilot-Frontend/components/agents/ReviewBoard.tsx`
- [Review endpoints](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/review-board/review-board.controller.ts): `Testpilot-Backend-Nest/src/review-board/review-board.controller.ts`
- [Review analysis](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/review-board/review-board.service.ts): `Testpilot-Backend-Nest/src/review-board/review-board.service.ts`
- [Knowledge ingestion](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/rag/rag-ingestion.service.ts): `Testpilot-Backend-Nest/src/rag/rag-ingestion.service.ts`
- [Knowledge retrieval](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/rag/rag-retrieval.service.ts): `Testpilot-Backend-Nest/src/rag/rag-retrieval.service.ts`
- [Embedding allocation](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/rag/rag-ai-allocation.ts): `Testpilot-Backend-Nest/src/rag/rag-ai-allocation.ts`
- [AI evaluation](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/ai-eval/ai-eval.types.ts): `Testpilot-Backend-Nest/src/ai-eval/ai-eval.types.ts`
- [Nyra review flow](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/nyra/nyra-review.service.ts): `Testpilot-Backend-Nest/src/nyra/nyra-review.service.ts`

### Test execution

- [Browser automation](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/automation/automation.controller.ts): `Testpilot-Backend-Nest/src/automation/automation.controller.ts`
- [Performance testing](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/performance-tests/performance-tests.controller.ts): `Testpilot-Backend-Nest/src/performance-tests/performance-tests.controller.ts`

### Identity and platform

- [PostgreSQL and pgvector](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/database/database.service.ts): `Testpilot-Backend-Nest/src/database/database.service.ts`
- [File storage](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/storage/storage.service.ts): `Testpilot-Backend-Nest/src/storage/storage.service.ts`
- [Authentication](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/auth/auth.controller.ts): `Testpilot-Backend-Nest/src/auth/auth.controller.ts`
- [Billing](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/billing/billing.controller.ts): `Testpilot-Backend-Nest/src/billing/billing.controller.ts`

### Integrations and reporting

- [Integration sync](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/integration-sync/integration-sync.service.ts): `Testpilot-Backend-Nest/src/integration-sync/integration-sync.service.ts`
- [Analytics reports](https://github.com/fikricghuv/testpilot-test-manager/blob/main/Testpilot-Backend-Nest/src/analytics-report/analytics-report.service.ts): `Testpilot-Backend-Nest/src/analytics-report/analytics-report.service.ts`

### Other components

- **QA team member**

## Connections

- QA team member → Case repository: organizes cases
- QA team member → Cycles and runs: records outcomes
- Case repository → Project API: submits case requests
- Cycles and runs → Project API: submits run requests
- Project API → Project and case services: delegates project actions (evidence: `Testpilot-Backend-Nest/src/legacy/legacy.controller.ts`)
- Review board → Review endpoints: requests decisions
- Review endpoints → Review analysis: delegates review actions (evidence: `Testpilot-Backend-Nest/src/review-board/review-board.controller.ts`)
- Review analysis → Project and case services: reads test cases (evidence: `Testpilot-Backend-Nest/src/review-board/review-board.service.ts`)
- Knowledge ingestion → PostgreSQL and pgvector: updates embedding state (evidence: `Testpilot-Backend-Nest/src/rag/rag-ingestion.service.ts`)
- Knowledge retrieval → PostgreSQL and pgvector: queries knowledge (evidence: `Testpilot-Backend-Nest/src/rag/rag-retrieval.service.ts`)
- Knowledge retrieval → Embedding allocation: resolves embedding provider (evidence: `Testpilot-Backend-Nest/src/rag/rag-retrieval.service.ts`)
- Nyra review flow → PostgreSQL and pgvector: reads and writes review data (evidence: `Testpilot-Backend-Nest/src/nyra/nyra-review.service.ts`)
- Nyra review flow → Project and case services: uses project services (evidence: `Testpilot-Backend-Nest/src/nyra/nyra-review.service.ts`)
- Nyra review flow → Embedding allocation: checks embedding availability (evidence: `Testpilot-Backend-Nest/src/nyra/nyra-review.service.ts`)
- Nyra review flow → Knowledge retrieval: uses knowledge context
- File storage → PostgreSQL and pgvector: stores file metadata
- Authentication → QA team member: authenticates
- Integration sync → PostgreSQL and pgvector: persists sync state
