本地源码方式部署启动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

相关推荐
可乐ea9 小时前
AI Agent 工具调用准确性评测:选择错误与参数错误分开测
大数据·人工智能·算法·大模型·工具调用·ai智能体·agent评测
Alice-YUE10 小时前
向量数据库选型实战:Chroma/Qdrant/Milvus/PgVector 怎么选
数据库·milvus·向量数据库·chroma·rag·qdrant
熊猫钓鱼>_>10 小时前
MetaAI深度研究研究报告
ai·meta·大模型·llm·agent·web·metaai
小范的技术工坊12 小时前
RAG完整链路拆解
大模型
汤姆yu12 小时前
GPT‑6 Astra大模型综述
gpt·ai·大模型
汤姆yu13 小时前
Claude Opus 5.5深度解析
ai·大模型·opus5.5
AI你一生一世14 小时前
当广告采集器成为大模型的“眼睛“:跨站上下文注入的架构与代价
人工智能·架构·大模型·rag·隐私安全·上下文注入·跨站追踪
AI你一生一世16 小时前
Attention is all you have:当上下文成为唯一的护城河
人工智能·大语言模型·注意力机制·rag·长上下文·上下文窗口·推理成本
dozenyaoyida1 天前
AI与大模型新闻日报 | 2026-09-30
大数据·人工智能·大模型·新闻
小范的技术工坊1 天前
大模型结构化输出
大模型·结构化