Hyungi Ahn 01f144ab25 fix(search): soft_filter boost 약화 (domain 0.01, doctype 제거)
## 1차 측정 결과 (Phase 2.3 초안)

| metric | Phase 2.2 narrow | Phase 2.3 (boost 0.03+0.02) | Δ |
|---|---|---|---|
| Recall@10 | 0.737 | 0.721 | -0.016  |
| NDCG@10 | 0.668 | 0.661 | -0.007 |
| exact_keyword NDCG | 0.96 | 0.93 | -0.03  |

## 진단
- 같은 도메인 doc이 **무차별** boost → exact match doc 상대 우위 손상
- document_type 매칭은 ai_domain/match_reason 휴리스틱 → false positive 다수

## 수정
- SOFT_FILTER_DOMAIN_BOOST 0.03 → **0.01**
- document_type 매칭 로직 제거
- domain 매칭을 "정확 일치 또는 path 포함"으로 좁힘
- max cap 0.05 유지

## Phase 2.3 위치
 - 현재 평가셋(v0.1)에는 filter 쿼리 없음 → 효과 직접 측정 불가
 - Phase 2.4에서 queries_v0.2.yaml 확장 후 재측정 예정
 - 이 커밋의 목적은 "회귀 방지" — boost가 해를 끼치지 않도록만

(+ CLAUDE.md 동기화: infra_inventory.md 참조 / soft lock 섹션 포함)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 15:40:04 +09:00

hyungi_Document_Server

Self-hosted 개인 지식관리(PKM) 웹 애플리케이션

기술 스택

  • 백엔드: FastAPI + SQLAlchemy (async)
  • 데이터베이스: PostgreSQL 16 + pgvector + pg_trgm
  • 프론트엔드: SvelteKit
  • 문서 파싱: kordoc (HWP/HWPX/PDF → Markdown)
  • AI: Qwen3.5-35B-A3B (MLX), nomic-embed-text, Claude API (폴백)
  • 인프라: Docker Compose, Caddy, Synology NAS

주요 기능

  • 문서 자동 분류/태그/요약 (AI 기반)
  • 전문검색 + 벡터 유사도 검색
  • HWP/PDF/Markdown 문서 뷰어
  • 법령 변경 모니터링 (산업안전보건법 등)
  • 이메일 자동 수집 (MailPlus IMAP)
  • 일일 다이제스트
  • CalDAV 태스크 연동 (Synology Calendar)

Quick Start

git clone https://git.hyungi.net/hyungi/hyungi_document_server.git hyungi_Document_Server
cd hyungi_Document_Server

# 인증 정보 설정
cp credentials.env.example credentials.env
nano credentials.env  # 실제 값 입력

# 실행
docker compose up -d

http://localhost:8000/docs 에서 API 문서 확인

디렉토리 구조

├── app/              FastAPI 백엔드 (API, 워커, AI 클라이언트)
├── frontend/         SvelteKit 프론트엔드
├── services/kordoc/  문서 파싱 마이크로서비스 (Node.js)
├── gpu-server/       GPU 서버 배포 (AI Gateway)
├── migrations/       PostgreSQL 스키마
├── docs/             설계 문서, 배포 가이드
└── tests/            테스트 코드

인프라 구성

서버 역할
Mac mini M4 Pro Docker Compose (FastAPI, PostgreSQL, kordoc, Caddy) + MLX AI
Synology NAS 파일 원본 저장, Synology Office/Drive/Calendar/MailPlus
GPU 서버 AI Gateway, 벡터 임베딩, OCR, 리랭킹

문서

Description
No description provided
Readme 1.6 MiB
Languages
Python 51.7%
Svelte 40.1%
TypeScript 3.4%
HTML 2.4%
CSS 1%
Other 1.4%