feat: 添加配置文件 config.ini
This commit is contained in:
2
.gitignore
vendored
2
.gitignore
vendored
@@ -16,8 +16,6 @@ __pycache__/
|
|||||||
*.swp
|
*.swp
|
||||||
*.swo
|
*.swo
|
||||||
|
|
||||||
# Config with sensitive data
|
|
||||||
config.ini
|
|
||||||
|
|
||||||
# Logs
|
# Logs
|
||||||
*.log
|
*.log
|
||||||
|
|||||||
35
config.ini
Normal file
35
config.ini
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
[image]
|
||||||
|
cdn_base = http://images11.bxmkb.cn/Images/
|
||||||
|
|
||||||
|
[database]
|
||||||
|
host = localhost
|
||||||
|
port = 3306
|
||||||
|
user = root
|
||||||
|
password = liang20020523
|
||||||
|
database = ai_article
|
||||||
|
charset = utf8mb4
|
||||||
|
|
||||||
|
[dashvector]
|
||||||
|
api_key = sk-55x6oBXypSlPHQ8NvPHfyBABcMIMUE0407A0FCC2A11F0B9C802831A608ABB
|
||||||
|
endpoint = vrs-cn-2ml4jm42o0001r.dashvector.cn-hangzhou.aliyuncs.com
|
||||||
|
collection_name = image_vectors
|
||||||
|
# 多模态模型维度 1024 (multimodal-embedding-v1)
|
||||||
|
vector_dimension = 1024
|
||||||
|
|
||||||
|
[dashscope]
|
||||||
|
api_key = sk-d3f235925afa4e4e83d707dde04b9e52
|
||||||
|
|
||||||
|
[similarity]
|
||||||
|
# pHash 汉明距离阈值,<=5 视为完全相同
|
||||||
|
phash_threshold = 5
|
||||||
|
# 向量相似度阈值,>=0.94 视为重复
|
||||||
|
vector_threshold = 0.94
|
||||||
|
|
||||||
|
[process]
|
||||||
|
# 每批处理数量
|
||||||
|
batch_size = 100
|
||||||
|
# 并发下载数
|
||||||
|
concurrent_downloads = 10
|
||||||
|
# 日志级别
|
||||||
|
log_level = INFO
|
||||||
|
log_file = image_similarity.log
|
||||||
Reference in New Issue
Block a user