mirror of
https://github.com/RYDE-WORK/Langchain-Chatchat.git
synced 2026-01-21 06:19:29 +08:00
* remove llm_model_dict * optimize configs * fix get_model_path * 更改一些默认参数,添加千帆的默认配置 * Update server_config.py.example
17 lines
420 B
Python
17 lines
420 B
Python
from sqlalchemy import create_engine
|
|
from sqlalchemy.ext.declarative import declarative_base
|
|
from sqlalchemy.orm import sessionmaker
|
|
|
|
from configs import SQLALCHEMY_DATABASE_URI
|
|
import json
|
|
|
|
|
|
engine = create_engine(
|
|
SQLALCHEMY_DATABASE_URI,
|
|
json_serializer=lambda obj: json.dumps(obj, ensure_ascii=False),
|
|
)
|
|
|
|
SessionLocal = sessionmaker(autocommit=False, autoflush=False, bind=engine)
|
|
|
|
Base = declarative_base()
|