本地源码方式部署启动MaxKB知识库问答系统

maxkb

https://github.com/1Panel-dev/MaxKB

安装 python

python 版本大于3.11

conda create -n mymaxkb python=3.12

pip install poetry

下载maxkb 安装

poetry install

构建 PostgreSQL docker

Dockerfile文件:

复制代码
# Use the official PostgreSQL 15 image as a base
FROM postgres:15

# Install necessary packages and clone the pgvector repository
RUN apt-get update && \
    apt-get install -y \
        postgresql-server-dev-15 \
        build-essential \
        git && \
    git clone https://github.com/pgvector/pgvector.git

# Build and install the pgvector extension
RUN cd pgvector && \
    make && \
    make install

# Clean up
RUN apt-get remove --purge -y \
        build-essential \
        git && \
    apt-get autoremove -y && \
    apt-get clean && \
    rm -rf /var/lib/apt/lists/* /pgvector

# Set the default command to run when starting the container
CMD ["postgres"]

docker build --no-cache -t postgres-with-vector .

运行容器

docker run --name vpostgres -e POSTGRES_USER=root -e POSTGRES_PASSWORD=shunwukong -e POSTGRES_DB=maxkb -p 5433:5432 -d postgres-with-vector

验证安装:检查 pgvector 扩展文件是否安装正确

此命令应列出所有可用的扩展。专门查找 pgvector.control .

docker exec -it vpostgres ls /usr/share/postgresql/15/extension/

创建扩展:

docker exec -it vpostgres psql -U root -d maxkb -c "CREATE EXTENSION vector;"

验证扩展:

docker exec -it vpostgres psql -U root -d maxkb -c "\dx"


启动后端

python main.py start

启动前端

pnpm install

pnpm run dev

登陆

初始的账号admin 密码 MaxKB@123.. 登录之后会提示你修改密码

参考:

https://blog.csdn.net/weixin_50503886/article/details/139223782

https://github.com/1Panel-dev/MaxKB

相关推荐
不爱记笔记4 小时前
上下班路上怎么消化技术视频?我把B站内容转成播客,通勤时间也能系统学习
学习·ai·音视频·知识库·知识管理
晓子文集5 小时前
Tushare接口文档:现金流量表(cashflow)
大数据·数据库·大模型·金融数据·量化投资·tushare
牧子川5 小时前
何时拒绝使用工具:Agent 不是万能钥匙
人工智能·大模型·agent·tools·functioncalling
codeの诱惑14 小时前
RAG 检索增强生成方案设计思路
推荐算法·rag
菩提小狗15 小时前
AI每日资讯|AI落地|最新情报|skill精选|2026年07月21日(11案例+10爆款Skill)
大模型·agent·skill·ai资讯·ai落地
weixin_4280053020 小时前
C#调用 AI学习从0开始-第3阶段RAG向量数据库-文档切分与入库第15天
人工智能·学习·c#·向量数据库·rag·qdrant·文档切分与入库
@Mr_LiuYang1 天前
从聊天框到空间智能:GIS接入大模型的5种架构模式
大模型·空间智能·geoai·架构方案·时空大模型·gis智能体
星核0penstarry1 天前
Coding Plan vs 运营商Token Plan:先选对赛道,再谈性价比
大模型·api
audyxiao0011 天前
人工智能顶会AAAI 2026论文分享|SlideBot:用于生成信息丰富、可靠、多模态幻灯片的多智能体框架
人工智能·大模型·aaai·智能体·幻灯片
做个文艺程序员1 天前
Linux第27篇:在Linux服务器部署本地大模型:Ollama+开源LLM实战
linux·服务器·开源·大模型·ollama