docs: Unify guidance — AGENTS.md as source of truth

Establish clear governance hierarchy:
1. AGENTS.md — AI coding constitution, authoritative
2. CLAUDE.md — Project context, supplements AGENTS.md
3. Code — Implementation, must comply with AGENTS.md

Changes:
- AGENTS.md: Add explicit declaration that this is the authoritative source
- CLAUDE.md: Add governance statement, redirect database config to AGENTS.md
- Quick Start: Remove stale/incorrect database credentials, point to appsettings.Development.json

Prevent guidance fragmentation:
- Do not add conflicting rules to CLAUDE.md
- All harnesses and procedures go to AGENTS.md
- Supplementary info only in CLAUDE.md (status, architecture, overview)

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-08-15 10:53:24 +09:00
parent 6abc0551c5
commit d090538b17
2 changed files with 27 additions and 42 deletions
+10 -1
View File
@@ -1,4 +1,13 @@
# K-ArtSell Aegis AI Coding Constitution v12.0
# K-ArtSell Aegis AI Coding Constitution v16.0
**AGENTS.md IS THE AUTHORITATIVE SOURCE FOR ALL ENGINEERING DECISIONS.**
This document supersedes conflicting guidance in CLAUDE.md, MEMORY, or prior conversations. When in doubt, follow AGENTS.md.
**Hierarchy:**
1. **AGENTS.md** — This file (AI coding constitution, rules, harnesses)
2. **CLAUDE.md** — Supplements AGENTS.md (project context, architecture, status)
3. **Code** — Implementation (must comply with AGENTS.md)
## Default execution procedure
+17 -41
View File
@@ -1,6 +1,13 @@
# CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
This file provides project context and architecture for Claude Code (claude.ai/code).
**IMPORTANT: All engineering decisions are governed by AGENTS.md v16.0. This file supplements AGENTS.md but DOES NOT override it.**
**Single Source of Truth (Hierarchy):**
1. **AGENTS.md** — AI coding constitution, principles, rules (authoritative)
2. **CLAUDE.md** — Project context, status, architecture (supplementary)
3. **Project code** — Implementation (must comply with AGENTS.md)
## ⚖️ Governance: AGENTS.md v16.0 Strategic Principles
@@ -169,39 +176,21 @@ Invoke-WebRequest -Uri "http://127.0.0.1:5002/api/shadow-runs" `
## Quick Start
**→ See AGENTS.md v16.0 "Development Environment Configuration" for authoritative setup.**
This section follows AGENTS.md. Do not deviate.
### Prerequisites
- .NET 10 SDK
- Node.js 22 / pnpm 10
- SSH access to remote PostgreSQL server (178.104.200.7)
### Remote PostgreSQL Setup via SSH Port Forwarding
The project database is hosted on `178.104.200.7`. Connect via SSH port forwarding:
### Local Development Commands
```bash
# SSH Tunnel (required first, in separate terminal)
ssh -L 5432:127.0.0.1:5432 kjh2064@178.104.200.7
```
This command:
- Forwards local port 5432 to remote PostgreSQL (127.0.0.1:5432)
- Keeps the tunnel open while you develop
- Run in a separate terminal/window and keep it running during development
**Windows (PowerShell):**
```powershell
ssh -L 5432:127.0.0.1:5432 kjh2064@178.104.200.7
```
**macOS/Linux:**
```bash
ssh -L 5432:127.0.0.1:5432 kjh2064@178.104.200.7
```
Once the tunnel is open, your local `localhost:5432` connects to the remote database.
### Local Development Environment
```bash
# Backend: restore, build, migrate, test
dotnet restore KArtSell.sln
dotnet build KArtSell.sln -c Release
@@ -229,25 +218,12 @@ pnpm dev # Backend in another terminal
```
### Database Connection
```
Host: localhost
Port: 5432
Database: kartsell
User: kartsell
Password: kartsell
```
Environment variable: `KARTSELL_POSTGRES=Host=localhost;Port=5432;Database=kartsell;Username=kartsell;Password=kartsell`
**Read from `src/KArtSell.Host/appsettings.Development.json` (source of truth).**
**On Windows (PowerShell):**
```powershell
$env:KARTSELL_POSTGRES="Host=localhost;Port=5432;Database=kartsell;Username=kartsell;Password=kartsell"
```
Do NOT use environment variables or make up credentials. Backend reads from config file.
**On macOS/Linux (bash):**
```bash
export KARTSELL_POSTGRES="Host=localhost;Port=5432;Database=kartsell;Username=kartsell;Password=kartsell"
```
Database is accessed through SSH tunnel only.
## Architecture