Files
archived-gitea-ai-assistant/.cursor/rules/03-tech-stack-and-dependencies.mdc
jeffusion 7ef35fa8ee chore(deploy): remove obsolete env vars from deployment configs
- docker-compose.e2e.yml: remove WEBHOOK_SECRET, REVIEW_* env vars
  (now configured via assistant API in seed.sh)
- e2e/seed.sh: add step to configure assistant via Admin API after boot
  (login with default password, set webhook secret + review settings)
- k8s/gitea-assistant.yaml: Secret now only contains GITEA_ACCESS_TOKEN;
  ConfigMap reduced to GITEA_API_URL, PORT, QDRANT_URL
- cursor rules updated to document DB-first config architecture
2026-03-24 12:30:13 +08:00

50 lines
1.9 KiB
Plaintext

---
description:
globs:
alwaysApply: true
---
# Technology Stack and Dependencies
## Core Technologies
- **Runtime**: Bun (JavaScript/TypeScript runtime)
- **Language**: TypeScript
- **Framework**: Hono (lightweight web framework)
- **API Integration**: LLM Gateway (OpenAI Compatible, OpenAI Responses API, Anthropic, Google Gemini), Gitea API
- **Containerization**: Docker, Kubernetes
## Key Dependencies
From [package.json](mdc:package.json):
### Production Dependencies
- **hono**: Lightweight, ultrafast web framework
- **@hono/zod-validator**: Schema validation for Hono
- **zod**: TypeScript-first schema validation
- **openai**: OpenAI API client (used for OpenAI Compatible and Responses providers)
- **@anthropic-ai/sdk**: Anthropic Messages API client
- **@google/genai**: Google Gemini API client
- **axios**: HTTP client for API requests
- **dotenv**: Environment variable management
- **lodash-es**: Utility library
### Development Dependencies
- **typescript**: TypeScript compiler and type definitions
- **tslint**: Code linting
- **@types/node**: Node.js type definitions
- **@types/lodash-es**: Type definitions for lodash-es
## Environment Configuration
The application uses a **DB-first** configuration approach (Portainer model):
- **Environment variables** (minimal, infrastructure-level only):
- `PORT`: Server port
- `DATABASE_PATH`: SQLite file path (optional, default: `./data/assistant.db`)
- `MASTER_KEY_PATH`: Encryption key path (optional, default: `./data/master.key`)
- **Web UI + SQLite DB** ([src/db/](mdc:src/db)): All runtime config — Gitea, Feishu, webhook secret, admin password, review engine, memory settings — managed via Admin Dashboard
- **First-boot seed**: `configManager.seedDefaults()` auto-generates secrets and seeds defaults on first run
- **bun:sqlite**: Embedded database for all configuration persistence (encrypted for sensitive values)