Project Overview
This system is an AI agent-based OKR scoring and training platform, supporting OKR file upload, automatic cleaning, intelligent scoring, and result export. It helps enterprises standardize OKR assessment and provides actionable feedback.
Technical Architecture
| Layer | Technology |
|---|---|
| Backend | FastAPI, Uvicorn, SQLite |
| Frontend | Vue 3, Vite |
| Scoring | LLM (DeepSeek via DashScope) / Coze API |
| Document Processing | python-docx, openpyxl |
Core Features
File Processing
- Supported formats: docx / xlsx / xls
- Auto cleaning: Parse O (Objective) and K (Key Result) structure, unify format
- Batch processing: Use ThreadPoolExecutor for concurrent analysis
Intelligent Scoring
System uses 130-point scale, with difficulty multiplier up to 10x:
| Part | Weight | System | Max |
|---|---|---|---|
| O (Objective) | 30% | Additive | 30 pts |
| K (Key Actions) | 40% | Deductive | 40 pts |
| R1 (Result) | 30% | Additive | 30 pts |
| R2 (Review) | 30% | Additive | 30 pts |
Formula: min(O,30) + min(R1,30) + min(R2,30) + max(0, 40-min(K,40))
Position Customization
Supports different scoring criteria for different positions, with customizable weights and scoring rules through configuration files.
Project Structure
app/
main.py # Streamlit entry (deprecated)
services/
okr_ingestion.py # File reading and record normalization
okr_cleaning.py # O/K parsing and cleaning
okr_scoring.py # Scoring backend selection
okr_export.py # Excel/document export
api/
main.py # FastAPI backend (streaming interface)
frontend/
src/ # Vue + Vite frontend
API Design
Streaming Scoring Endpoint
@app.post("/api/analyze/stream")
async def analyze_stream(file: UploadFile):
async def generate():
async for progress in okr_analyzer.analyze_stream(file):
yield f"data: {json.dumps(progress)}\n\n"
return StreamingResponse(generate(), media_type="text/event-stream")Export Endpoint
@app.post("/api/export")
async def export_results(results: List[AnalysisResult], format: str):
# Supports Excel, CSV, DOCX format export
return export_file(results, format)Usage
# Install dependencies
pip install -r requirements.txt
# Start backend
cd api && uvicorn main:app --reload
# Start frontend
cd frontend && npm run devCurrent Status
Production ready, continuously iterating and optimizing.
Related Links
Last updated: 2026-04-01