# Project Context

<!-- 
Template for project-wide context documentation.
Generated by reis_analyst at project start.
Updated when major technology or architecture changes occur.
-->

## Project Overview

- **Name**: {Project name}
- **Type**: {Web app / CLI / Library / API / Mobile app}
- **Stage**: {New / Existing / Migration}
- **Target Users**: {Who is this for}

## Technology Stack

### Core Technologies

<!-- Primary technology choices with rationale -->

| Category | Choice | Version | Rationale |
|----------|--------|---------|-----------|
| Language | {e.g., TypeScript} | {e.g., 5.x} | {Why chosen} |
| Runtime | {e.g., Node.js} | {e.g., 20.x} | {Why chosen} |
| Framework | {e.g., Next.js} | {e.g., 14.x} | {Why chosen} |
| Database | {e.g., PostgreSQL} | {e.g., 15.x} | {Why chosen} |
| ORM | {e.g., Prisma} | {e.g., 5.x} | {Why chosen} |
| Hosting | {e.g., Vercel} | {-} | {Why chosen} |

### Key Dependencies

<!-- Important packages that affect architecture -->

| Package | Version | Purpose | Notes |
|---------|---------|---------|-------|
| {package} | {version} | {what it does} | {any concerns} |
| {package} | {version} | {what it does} | {any concerns} |
| {package} | {version} | {what it does} | {any concerns} |

### Development Tools

<!-- Tooling choices for consistency -->

| Tool | Purpose |
|------|---------|
| {e.g., ESLint} | {Code linting} |
| {e.g., Prettier} | {Code formatting} |
| {e.g., Vitest} | {Testing} |
| {e.g., Husky} | {Git hooks} |

## Architecture Decisions

<!-- Key decisions using ADR (Architecture Decision Record) format -->

### Decision 1: {Decision Title}

- **Context**: {Why this decision was needed}
- **Decision**: {What was decided}
- **Consequences**: {Impact of this decision, both positive and negative}
- **Alternatives considered**: {What else was evaluated and why rejected}

### Decision 2: {Decision Title}

- **Context**: {Why this decision was needed}
- **Decision**: {What was decided}
- **Consequences**: {Impact of this decision}
- **Alternatives considered**: {What else was evaluated}

### Decision 3: {Decision Title}

- **Context**: {Why this decision was needed}
- **Decision**: {What was decided}
- **Consequences**: {Impact of this decision}
- **Alternatives considered**: {What else was evaluated}

## Constraints

<!-- Constraints that affect technical and scope decisions -->

### Technical Constraints

- {Constraint 1: e.g., Must support IE11}
- {Constraint 2: e.g., Maximum bundle size 200kb}
- {Constraint 3: e.g., Must work offline}

### Business Constraints

- {Constraint 1: e.g., Launch by Q2 2026}
- {Constraint 2: e.g., Budget under $100/month}
- {Constraint 3: e.g., Must integrate with existing CRM}

### Team Constraints

- {Constraint 1: e.g., Solo developer, 20hrs/week}
- {Constraint 2: e.g., No Kubernetes expertise}
- {Constraint 3: e.g., Strong React, weak backend}

## Integration Points

<!-- External systems and APIs the project interacts with -->

| System | Type | Direction | Status | Notes |
|--------|------|-----------|--------|-------|
| {External API} | REST/GraphQL/gRPC | Inbound/Outbound/Both | Planned/Active/Deprecated | {Any concerns} |
| {Database} | SQL/NoSQL | Outbound | Active | {Connection details location} |
| {Third-party service} | SDK/API | Outbound | Planned | {Rate limits, costs} |

## Team Context

<!-- Team information affecting technical decisions -->

- **Size**: {Solo / 2-3 / Small team / Large team}
- **Availability**: {Full-time / Part-time / Variable}
- **Expertise**: 
  - Strong: {Technologies team knows well}
  - Learning: {Technologies team is learning}
  - Avoid: {Technologies team should not use}

## Project Risks

<!-- Identified risks with assessment and mitigation -->

| Risk | Likelihood | Impact | Mitigation Strategy |
|------|------------|--------|---------------------|
| {Risk description} | High/Medium/Low | High/Medium/Low | {How to prevent or handle} |
| {Risk description} | High/Medium/Low | High/Medium/Low | {How to prevent or handle} |
| {Risk description} | High/Medium/Low | High/Medium/Low | {How to prevent or handle} |

## Assumptions

<!-- Documented assumptions that need validation -->

### Validated Assumptions
- [x] {Assumption 1 - validated by: evidence}
- [x] {Assumption 2 - validated by: evidence}

### Pending Validation
- [ ] {Assumption 3 - needs validation by: method}
- [ ] {Assumption 4 - needs validation by: method}

### Assumptions Made (No Validation Planned)
- {Assumption 5 - accepting risk because: reason}

## Glossary

<!-- Domain-specific terms for consistency -->

| Term | Definition |
|------|------------|
| {Term} | {Definition in project context} |
| {Term} | {Definition in project context} |

---

*Generated by reis_analyst on {timestamp}*
*Last updated: {timestamp}*
*Update this file when major decisions change.*
