@@ -181,7 +181,7 @@ python main.py
181181docker build -t ai-quiz-system .
182182
183183# Run container
184- docker run -p 8000:8000 -v $( pwd) /config.yaml:/app/config.yaml ai-quiz-system
184+ docker run -p 8081:8081 -v $( pwd) /config.yaml:/app/config.yaml ai-quiz-system
185185```
186186
187187### 🎯 Service Verification
@@ -193,11 +193,11 @@ After successful startup, you will see:
193193==================================================
194194👤 Author: Toni Wang
195195📧 Email: shell7@petalmail.com
196- 🌐 Address: http://0.0.0.0:8000
196+ 🌐 Address: http://0.0.0.0:8081
197197==================================================
198198```
199199
200- Visit http://localhost:8000 to view API documentation
200+ Visit http://localhost:8081 to view API documentation
201201
202202## 📖 API Documentation
203203
@@ -226,10 +226,10 @@ Intelligent quiz query and answer generation interface
226226** Request Examples:**
227227``` bash
228228# GET request
229- curl " http://localhost:8000 /api/query?title=What is the capital of China?&options=A. Beijing B. Shanghai C. Guangzhou&type=Multiple Choice"
229+ curl " http://localhost:8081 /api/query?title=What is the capital of China?&options=A. Beijing B. Shanghai C. Guangzhou&type=Multiple Choice"
230230
231231# POST request
232- curl -X POST http://localhost:8000 /api/query \
232+ curl -X POST http://localhost:8081 /api/query \
233233 -H " Content-Type: application/json" \
234234 -d ' {
235235 "title": "What is 1+1?",
@@ -325,12 +325,12 @@ curl -X POST http://localhost:8000/api/query \
325325
326326After starting the service, visit the following URLs for complete API documentation:
327327
328- - ** 📘 Swagger UI** : http://localhost:8000 /docs
328+ - ** 📘 Swagger UI** : http://localhost:8081 /docs
329329 - Support for online API testing
330330 - Detailed request/response examples
331331 - Parameter descriptions and constraints
332332
333- - ** 📗 ReDoc** : http://localhost:8000 /redoc
333+ - ** 📗 ReDoc** : http://localhost:8081 /redoc
334334 - Beautiful three-column documentation
335335 - Suitable for printing and sharing
336336 - Complete API specifications
@@ -340,7 +340,7 @@ After starting the service, visit the following URLs for complete API documentat
340340#### Batch Queries
341341``` bash
342342# Use POST for batch queries
343- curl -X POST http://localhost:8000 /api/query/batch \
343+ curl -X POST http://localhost:8081 /api/query/batch \
344344 -H " Content-Type: application/json" \
345345 -d ' {
346346 "questions": [
@@ -353,7 +353,7 @@ curl -X POST http://localhost:8000/api/query/batch \
353353#### Specify AI Provider
354354``` bash
355355# Temporarily specify AI platform
356- curl " http://localhost:8000 /api/query?title=Programming question&provider=deepseek"
356+ curl " http://localhost:8081 /api/query?title=Programming question&provider=deepseek"
357357```
358358
359359## ⚙️ Configuration Guide
@@ -363,7 +363,7 @@ curl "http://localhost:8000/api/query?title=Programming question&provider=deepse
363363``` yaml
364364server :
365365 host : " 0.0.0.0" # Server address
366- port : 8000 # Server port
366+ port : 8081 # Server port
367367 reload : false # Enable hot reload
368368` ` `
369369
@@ -402,13 +402,13 @@ python test_fastapi_app.py
402402
403403``` bash
404404# Test query interface
405- curl " http://localhost:8000 /api/query?title=1+1&?type=Fill in the Blank"
405+ curl " http://localhost:8081 /api/query?title=1+1&?type=Fill in the Blank"
406406
407407# Test health check
408- curl " http://localhost:8000 /api/health"
408+ curl " http://localhost:8081 /api/health"
409409
410410# Test system information
411- curl " http://localhost:8000 /api/system/info"
411+ curl " http://localhost:8081 /api/system/info"
412412```
413413
414414## 🔑 API Platform API Key Setup
@@ -550,8 +550,8 @@ project/
550550** Issue 1: Port Already in Use**
551551``` bash
552552# Find process occupying the port
553- netstat -ano | findstr :8000 # Windows
554- lsof -i :8000 # macOS/Linux
553+ netstat -ano | findstr :8081 # Windows
554+ lsof -i :8081 # macOS/Linux
555555
556556# Kill process or modify port in configuration file
557557```
@@ -647,10 +647,10 @@ logging:
647647tail -f app.log
648648
649649# Check system status
650- curl http://localhost:8000 /api/health
650+ curl http://localhost:8081 /api/health
651651
652652# Test AI provider status
653- curl http://localhost:8000 /api/ai-providers
653+ curl http://localhost:8081 /api/ai-providers
654654```
655655
656656### Getting Help
0 commit comments