Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
LLM-Filter
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
2026_NGIT
LLM-Filter
Commits
c2fb1149
Commit
c2fb1149
authored
Jan 04, 2026
by
uuo00_n
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
docs: 更新文档以反映新增的Security微服务
在SPEAK.md和LLM_FILTER_TECHNICAL_WHITE_PAPER.md中添加了Security微服务的相关信息
parent
d7f2b648
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
3 deletions
+9
-3
LLM_FILTER_TECHNICAL_WHITE_PAPER.md
LLM_FILTER_TECHNICAL_WHITE_PAPER.md
+5
-2
SPEAK.md
SPEAK.md
+4
-1
No files found.
LLM_FILTER_TECHNICAL_WHITE_PAPER.md
View file @
c2fb1149
...
...
@@ -85,7 +85,7 @@ LLM-Filter 不仅仅是一个“过滤器”,它被定义为**AI 时代的防
LLM-Filter 的架构可以拆成两层理解:
1)
**系统级(Microservices)**
:通过网关对外暴露统一入口,内部按领域拆成 Auth(认证/绑定)、Edu(教务/看板)、LLM(对话/过滤/审计)。
1)
**系统级(Microservices)**
:通过网关对外暴露统一入口,内部按领域拆成 Auth(认证/绑定)、Edu(教务/看板)、LLM(对话/过滤/审计)
、Security(安全/监控)
。
2)
**服务内(Clean Architecture)**
:以 LLM Service 为例,服务内部再使用整洁架构分层,保证可测试性与可替换性。
...
...
@@ -97,10 +97,13 @@ graph TD
Gateway --> AuthSvc[Auth Service (Go/Gin)]
Gateway --> EduSvc[Edu Service (Java/Spring Boot)]
Gateway --> LLMSvc[LLM Service (Python/FastAPI)]
Gateway --> SecSvc[Security Service (Python/FastAPI)]
AuthSvc --> PG[(PostgreSQL)]
EduSvc --> PG
LLMSvc --> Mongo[(MongoDB)]
SecSvc --> Mongo
LLMSvc --> LLM[Ollama / Dify]
SecSvc --> LLM
```
服务内从逻辑上划分为四层同心圆结构:
...
...
@@ -141,7 +144,7 @@ async with httpx.AsyncClient() as client:
*
优势:外键/事务保障、便于做复杂查询与报表。
2.
**MongoDB(高写入 + 半结构化)**
*
适用:对话历史、敏感词库、过滤命中记录、审计轨迹等。
*
适用:对话历史、敏感词库、过滤命中记录、审计轨迹
、安全分析日志
等。
*
优势:天然承载嵌套结构(messages 数组、元数据扩展),对迭代友好。
这种组合让系统既能在“身份/教务”上获得关系模型的完整性,又能在“对话/审计”上保持 Schema 的弹性。对于 LLM Service,我们仍然使用 Pydantic 做应用层校验,避免 Schema-less 带来的数据漂移。
...
...
SPEAK.md
View file @
c2fb1149
...
...
@@ -9,7 +9,7 @@
**演讲参考:**
“各位好!前端安全更像是‘门口保安’,而后端安全才是‘教务系统的总闸门’:身份、权限、数据、审计、合规,都必须在服务端形成闭环。
在我们的校园 AI 智能助手项目里,后端并不是一个单体应用,而是由
**网关(Nginx)+
三个微服务(Auth/Edu/LLM
)**
组成。今天我会沿着一条请求从入口到模型的路径,把我们的后端安全‘五道防线’讲清楚。”
在我们的校园 AI 智能助手项目里,后端并不是一个单体应用,而是由
**网关(Nginx)+
四个微服务(Auth/Edu/LLM/Security
)**
组成。今天我会沿着一条请求从入口到模型的路径,把我们的后端安全‘五道防线’讲清楚。”
---
...
...
@@ -28,6 +28,9 @@
-
鉴权依赖:
`microservices/llm-service/app/api/deps.py`
-
敏感词过滤:
`microservices/llm-service/app/utils/sensitive_word_filter.py`
-
对话写入与审计:
`microservices/llm-service/app/services/conversation.py`
-
**Security 层(Security Service / Python + FastAPI)**
:AI 驱动的安全分析、风险监控、应急响应
-
入口:
`microservices/security-service/app/main.py`
-
历史查询:
`microservices/security-service/app/api/v1/endpoints.py`
---
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment