LuoChinWen 1740b548dd -dev:修改了样式、配色,以及前端性能和前端逻辑优化 hace 1 mes
..
.hypothesis 3408bea816 -dev:完成task和project相关接口 hace 1 mes
routers 3408bea816 -dev:完成task和project相关接口 hace 1 mes
schemas 3408bea816 -dev:完成task和project相关接口 hace 1 mes
services 53564ecbf7 -init:初始化项目 hace 1 mes
test 3408bea816 -dev:完成task和project相关接口 hace 1 mes
.env.example 53564ecbf7 -init:初始化项目 hace 1 mes
README.md 53564ecbf7 -init:初始化项目 hace 1 mes
SAMPLE_DATA_README.md f4b2447602 stage1 hace 1 mes
database.py e495e45135 -dev:后端接口开发:任务相关 hace 1 mes
init_image_annotation_data.py f4b2447602 stage1 hace 1 mes
init_sample_data.py c55a8d7f6c -dev:接入了labelstudio的组件 hace 1 mes
main.py 3408bea816 -dev:完成task和project相关接口 hace 1 mes
models.py 53564ecbf7 -init:初始化项目 hace 1 mes
pytest.ini e495e45135 -dev:后端接口开发:任务相关 hace 1 mes
requirements.txt c55a8d7f6c -dev:接入了labelstudio的组件 hace 1 mes
test_annotation.py c55a8d7f6c -dev:接入了labelstudio的组件 hace 1 mes

README.md

Annotation Platform Backend

FastAPI-based backend for the annotation platform.

Setup

  1. Install dependencies:

    pip install -r requirements.txt
    
  2. Configure environment variables (optional):

    cp .env.example .env
    # Edit .env with your configuration
    

Running the Server

Development mode:

python main.py

Or with uvicorn directly:

uvicorn main:app --reload --host 0.0.0.0 --port 8000

API Documentation

Once the server is running, visit:

Project Structure

backend/
├── main.py              # FastAPI application entry point
├── database.py          # Database connection and initialization
├── models.py            # Database models
├── requirements.txt     # Python dependencies
├── routers/            # API route handlers
├── services/           # Business logic
└── schemas/            # Pydantic schemas for validation

Database

The application uses SQLite for data storage. The database file is created automatically on first run.

Default location: annotation_platform.db

To use a custom location, set the DATABASE_PATH environment variable.

Testing

Run tests with pytest:

pytest