
# 应用配置
[admin_app]
APP_NAME=后台管理
APP_VERSION=1.0.0
DEBUG=True
SECRET_KEY=dev-secret-key-change-in-production-12345678901234567890
ALGORITHM=HS256

# 服务器配置
HOST=0.0.0.0
PORT=8000
RELOAD=True

# 数据库配置 - 请根据实际情况修改
# 注意：如果密码包含特殊字符（如@），需要进行URL编码
# @ 编码为 %40
# 例如：密码 lq@123 应该写成 lq%40123
#DATABASE_URL=mysql+aiomysql://root:admin@localhost:3306/lq_db
DATABASE_URL=mysql+aiomysql://root:Lq123456!@192.168.92.61:13306/lq_db
DATABASE_ECHO=False

# Milvus向量数据库配置信息
MILVUS_HOST=192.168.92.61
MILVUS_PORT=19530
MILVUS_DB=lq_db
MILVUS_USER=
MILVUS_PASSWORD=

# Redis配置
REDIS_URL=redis://localhost:6379/0
REDIS_PASSWORD=

# JWT配置
ACCESS_TOKEN_EXPIRE_MINUTES=30
REFRESH_TOKEN_EXPIRE_DAYS=30
JWT_SECRET_KEY=dev-jwt-secret-key-change-in-production-12345678901234567890

# 后台管理Token配置
ADMIN_TOKEN_EXPIRE_MINUTES=3
ADMIN_REFRESH_TOKEN_EXPIRE_HOURS=24

# OAuth2配置
OAUTH2_AUTHORIZATION_CODE_EXPIRE_MINUTES=10
OAUTH2_ACCESS_TOKEN_EXPIRE_MINUTES=120
OAUTH2_REFRESH_TOKEN_EXPIRE_DAYS=30

# 邮件配置
SMTP_HOST=
SMTP_PORT=587
SMTP_USER=
SMTP_PASSWORD=
SMTP_TLS=True
SMTP_SSL=False

# 文件上传配置
UPLOAD_DIR=./uploads
MAX_FILE_SIZE=5242880
ALLOWED_EXTENSIONS=["jpg","jpeg","png","gif"]

# 日志配置
LOG_LEVEL=INFO
LOG_FILE=./logs/app.log

# CORS配置
CORS_ORIGINS=http://localhost:3000,http://localhost:8080,http://localhost:3001
CORS_CREDENTIALS=True
CORS_METHODS=*
CORS_HEADERS=*

# 安全配置
BCRYPT_ROUNDS=12
PASSWORD_MIN_LENGTH=8
MAX_LOGIN_ATTEMPTS=5
LOCKOUT_DURATION_MINUTES=30

# 缓存配置
CACHE_TTL=3600
SESSION_TTL=86400

# Celery配置
CELERY_BROKER_URL=redis://localhost:6379/1
CELERY_RESULT_BACKEND=redis://localhost:6379/2

# MinIO配置
MINIO_ENDPOINT=192.168.91.15:19000
MINIO_ACCESS_KEY=HVFOa38zUDg3X6c14hpH
MINIO_SECRET_KEY=ilVITuWEmjG0YDBAWspSG6UniHpEoMDECSuCo0f1
MINIO_BUCKET_NAME=aidata
MINIO_USE_SSL=False
MINIO_BASE_PATH=sampledata
# 文件访问基础URL
FILE_BASE_URL=http://192.168.91.15:19000/aidata/sampledata

# MinERU 配置
MINERU_ACCESS_KEY=
MINERU_SECRET_KEY=
MINERU_TOKEN=eyJ0eXBlIjoiSldUIiwiYWxnIjoiSFM1MTIifQ.eyJqdGkiOiI0MjcwMDM4NiIsInJvbCI6IlJPTEVfUkVHSVNURVIiLCJpc3MiOiJPcGVuWExhYiIsImlhdCI6MTc3MDM2MjIyNSwiY2xpZW50SWQiOiJsa3pkeDU3bnZ5MjJqa3BxOXgydyIsInBob25lIjoiIiwib3BlbklkIjpudWxsLCJ1dWlkIjoiYzgzOWVlYTAtYWZkOC00YTdjLWJmMTUtNTQ1YTU3ODQ2M2ZkIiwiZW1haWwiOiIiLCJleHAiOjE3NzE1NzE4MjV9.0DmDNrg7eSq8PxY043dyW08eKcIJOSOsVIDUx9oAmuMV1bQ6fMKBAXE1blL6mWyDn6B6jdbt3OESnVdNm3TqDQ
MINERU_API_APPLY=https://mineru.net/api/v4/file-urls/batch
MINERU_API_BATCH_RESULT=https://mineru.net/api/v4/extract-results/batch/{}

# 外部标注平台配置
[external_api]
admin_token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJ1c2VyXzIwMjYwMTI5MTUxMTM4XzkzYjIyMjZkIiwidXNlcm5hbWUiOiJhZG1pbiIsImVtYWlsIjoiYWRtaW5AZXhhbXBsZS5jb20iLCJyb2xlIjoiYWRtaW4iLCJleHAiOjEwNDEwMTg5NjYxLCJpYXQiOjE3NzAyNzYwNjEsInR5cGUiOiJhY2Nlc3MifQ.QW5qwNXop3Id4fVE9rpelTgdyGZUzMralQAFOVj4Mtw
project_api_url=http://192.168.92.61:9003/api/external/projects
download_base_url=http://192.168.92.61:9003

# embedding模型配置
EMBEDDING_BASE_URL=http://192.168.91.253:9003/v1
EMBEDDING_MODEL=Qwen3-Embedding-8B
EMBEDDING_API_KEY=dummy