forked from dai-hongtao/InkTime
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
141 lines (110 loc) · 5.35 KB
/
Copy path.env.example
File metadata and controls
141 lines (110 loc) · 5.35 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
# =============================================================================
# InkTime Configuration
# =============================================================================
# Copy this file to .env and customize values.
# Settings are used by both photo_analyzer and server packages.
# =============================================================================
# Selection Mode
# =============================================================================
# Selection mode: "date" (on-this-day history) or "curated" (sequential display)
SELECTION_MODE=date
# =============================================================================
# Date Mode Settings (required when SELECTION_MODE=date)
# =============================================================================
# Photo library paths (comma-separated for multiple sources)
# Example: ./photos, ./more-photos, /absolute/path/to/photos
IMAGE_DIRS=./photo_analyzer/test
# SQLite database path (stores photo analysis results)
DB_PATH=./photo_analyzer/photos.db
# =============================================================================
# Curated Mode Settings (required when SELECTION_MODE=curated)
# =============================================================================
# Curated photo paths (comma-separated for multiple sources)
CURATED_DIRS=./curated
# SQLite database path for curated photos
CURATED_DB_PATH=./photo_analyzer/curated.db
# =============================================================================
# photo_analyzer Settings (photo analysis only)
# =============================================================================
# VLM API configuration (OpenAI-compatible endpoint)
API_URL=http://127.0.0.1:1234/v1/chat/completions
MODEL_NAME=qwen3.5-4b
# API_KEY=your_api_key_here
# Processing limits
# BATCH_LIMIT=100 # Uncomment to limit photos per run (default: unlimited)
TIMEOUT=600
VLM_MAX_LONG_EDGE=2560
# City resolution (GPS to city name)
WORLD_CITIES_CSV=./photo_analyzer/world_cities_zh.csv
CITY_GRID_DEG=1.0
CITY_MAX_DISTANCE_KM=80.0
# Local areas (familiar places where you live/spend time)
# Photos taken within these areas are NOT considered "travel"
# Maximum 5 areas supported (LOCAL_0_* through LOCAL_4_*)
LOCAL_0_LAT=22.543096
LOCAL_0_LON=114.057865
LOCAL_0_RADIUS=60.0
# =============================================================================
# server Settings (Flask server only)
# =============================================================================
# Photo selection criteria
MEMORY_THRESHOLD=70.0
DAILY_PHOTO_QUANTITY=3
# Server binding
FLASK_HOST=0.0.0.0
FLASK_PORT=8765
DEBUG=false
# =============================================================================
# Language Settings
# =============================================================================
# Display languages (comma-separated, order matters)
# - First value: default display language (used by server)
# - All values: languages to generate captions and location names for
# Supported: zh, en
DISPLAY_LANGUAGES=zh,en
# Language-specific fonts (required for each configured language)
FONT_PATH_ZH=./server/fonts/LXGWWenKaiLite-Medium.ttf
FONT_PATH_EN=./server/fonts/Lora-Medium.ttf
# =============================================================================
# Enhanced Caption Settings
# =============================================================================
# Enable enhanced caption generation using online API
# When enabled, daily selected photos get improved captions from a more capable model
ENHANCED_CAPTION_ENABLED=false
# Base URL for OpenAI-compatible API (include /chat/completions suffix)
ENHANCED_BASE_URL=https://generativelanguage.googleapis.com/v1beta/openai/chat/completions
# API key for the enhanced caption service
# ENHANCED_API_KEY=
# Model name for enhanced caption generation
ENHANCED_MODEL_NAME=gemini-3.1-flash-lite-preview
# Timeout for enhanced caption API requests (seconds)
ENHANCED_TIMEOUT=60
# Number of retry attempts for enhanced caption API requests
ENHANCED_RETRY_TIMES=3
# Maximum concurrent requests for enhanced caption generation
ENHANCED_CONCURRENT_LIMIT=3
# =============================================================================
# Dithering Settings
# =============================================================================
# Dithering algorithm for photo area
# Options: floyd_steinberg, burkes, atkinson, sierra, stucki, jarvis
#
# | Mode | Quality | Speed | Best For |
# |-----------------|-----------|----------|---------------------------|
# | floyd_steinberg | Good | Fast | Classic algorithm |
# | burkes | Good | Fast | General purpose (default) |
# | atkinson | High | Medium | High contrast, artistic |
# | sierra | High | Medium | Balanced quality |
# | stucki | Very High | Slow | Maximum quality |
# | jarvis | Highest | Slowest | Smooth gradients |
#
PHOTO_DITHER_MODE=burkes
# Dynamic range compression for photo area
# Maps image luminance to the display's actual range
# - 0.0 (default): No compression, preserves original exposure
# - 0.5: Partial compression, subtle enhancement
# - 1.0: Full compression to display range
# - auto: Histogram-based stretching (may over-brighten)
PHOTO_TONE=0.0
# Dithering algorithm for text area (default: atkinson for sharp edges)
TEXT_DITHER_MODE=atkinson