ghmark675
Committed by GitHub

Merge pull request #193 from 666ghj/docs/pg_db

docs(README): update database config
@@ -296,22 +296,32 @@ Copy the `.env.example` file in the project root directory to `.env` @@ -296,22 +296,32 @@ Copy the `.env.example` file in the project root directory to `.env`
296 296
297 Edit the `.env` file and fill in your API keys (you can also choose your own models and search proxies; see the `.env.example` file in the project root directory or the `config.py` file for details): 297 Edit the `.env` file and fill in your API keys (you can also choose your own models and search proxies; see the `.env.example` file in the project root directory or the `config.py` file for details):
298 298
299 -```python  
300 -# MySQL Database Configuration  
301 -DB_HOST = "localhost"  
302 -DB_PORT = 3306  
303 -DB_USER = "your_username"  
304 -DB_PASSWORD = "your_password"  
305 -DB_NAME = "your_db_name"  
306 -DB_CHARSET = "utf8mb4" 299 +```yml
  300 +# ====================== Database Configuration ======================
  301 +# Database host, e.g., localhost or 127.0.0.1
  302 +DB_HOST=your_db_host
  303 +# Database port number, default is 3306
  304 +DB_PORT=3306
  305 +# Database username
  306 +DB_USER=your_db_user
  307 +# Database password
  308 +DB_PASSWORD=your_db_password
  309 +# Database name
  310 +DB_NAME=your_db_name
  311 +# Database character set, utf8mb4 is recommended for emoji compatibility
  312 +DB_CHARSET=utf8mb4
  313 +# Database type: mysql or postgresql
  314 +DB_DIALECT=postgresql
307 315
308 # LLM configuration 316 # LLM configuration
309 # You can switch each Engine's LLM provider as long as it follows the OpenAI-compatible request format 317 # You can switch each Engine's LLM provider as long as it follows the OpenAI-compatible request format
310 318
311 # Insight Agent 319 # Insight Agent
312 -INSIGHT_ENGINE_API_KEY = "your_api_key"  
313 -INSIGHT_ENGINE_BASE_URL = "https://api.moonshot.cn/v1"  
314 -INSIGHT_ENGINE_MODEL_NAME = "kimi-k2-0711-preview" 320 +INSIGHT_ENGINE_API_KEY=
  321 +# Insight Agent LLM API BaseUrl, customize API provider
  322 +INSIGHT_ENGINE_BASE_URL=
  323 +# Insight Agent LLM Model Name, e.g., kimi-k2-0711-preview
  324 +INSIGHT_ENGINE_MODEL_NAME=
315 # Media Agent 325 # Media Agent
316 ... 326 ...
317 ``` 327 ```
@@ -297,22 +297,32 @@ playwright install chromium @@ -297,22 +297,32 @@ playwright install chromium
297 297
298 编辑 `.env` 文件,填入您的API密钥(您也可以选择自己的模型、搜索代理,详情见根目录.env.example文件内或根目录config.py中的说明): 298 编辑 `.env` 文件,填入您的API密钥(您也可以选择自己的模型、搜索代理,详情见根目录.env.example文件内或根目录config.py中的说明):
299 299
300 -```python  
301 -# MySQL数据库配置  
302 -DB_HOST = "localhost"  
303 -DB_PORT = 3306  
304 -DB_USER = "your_username"  
305 -DB_PASSWORD = "your_password"  
306 -DB_NAME = "your_db_name"  
307 -DB_CHARSET = "utf8mb4" 300 +```yml
  301 +# ====================== 数据库配置 ======================
  302 +# 数据库主机,例如localhost 或 127.0.0.1
  303 +DB_HOST=your_db_host
  304 +# 数据库端口号,默认为3306
  305 +DB_PORT=3306
  306 +# 数据库用户名
  307 +DB_USER=your_db_user
  308 +# 数据库密码
  309 +DB_PASSWORD=your_db_password
  310 +# 数据库名称
  311 +DB_NAME=your_db_name
  312 +# 数据库字符集,推荐utf8mb4,兼容emoji
  313 +DB_CHARSET=utf8mb4
  314 +# 数据库类型mysql或postgresql
  315 +DB_DIALECT=postgresql
308 316
309 # LLM配置 317 # LLM配置
310 # 您可以更改每个部分LLM使用的API,只要兼容OpenAI请求格式都可以 318 # 您可以更改每个部分LLM使用的API,只要兼容OpenAI请求格式都可以
311 319
312 # Insight Agent 320 # Insight Agent
313 -INSIGHT_ENGINE_API_KEY = "your_api_key"  
314 -INSIGHT_ENGINE_BASE_URL = "https://api.moonshot.cn/v1"  
315 -INSIGHT_ENGINE_MODEL_NAME = "kimi-k2-0711-preview" 321 +INSIGHT_ENGINE_API_KEY=
  322 +# Insight Agent LLM接口BaseUrl,可自定义厂商API
  323 +INSIGHT_ENGINE_BASE_URL=
  324 +# Insight Agent LLM模型名称,如kimi-k2-0711-preview
  325 +INSIGHT_ENGINE_MODEL_NAME=
316 # Media Agent 326 # Media Agent
317 ... 327 ...
318 ``` 328 ```