# yawar2518/campus-lost-and-found architecture

> Architecture diagram of the GitHub repository yawar2518/campus-lost-and-found, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-25). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/yawar2518/campus-lost-and-found
- Repository: https://github.com/yawar2518/campus-lost-and-found

## Overview

Campus Lost & Found is a Django portal where campus users register, report lost or found items, browse and search reports, and review AI-suggested matches before contacting an owner. Views coordinate forms, item persistence, authentication, matching, and rendered pages; owners can manage their posts and mark them resolved. The README also describes image uploads and category/location-aware matching. The excerpts do not include model or full view implementations, so uncertain persistence wiring and individual route behavior are not expanded.

Main entry points: [`campusLostAndFound/items/views.py`](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py) (Request views), [`campusLostAndFound/items/models.py`](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/models.py) (Item records), [`campusLostAndFound/campusLostAndFound/urls.py`](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/campusLostAndFound/urls.py) (URL routing), [`campusLostAndFound/items/urls.py`](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/urls.py) (Item routes)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_web["Web interface"]
  node_routing["URL routing<br/>[urls.py]"]
  node_item_routes["Item routes<br/>[urls.py]"]
  node_views["Request views<br/>[views.py]"]
  node_templates["Portal pages"]
end

subgraph group_reports["Item reports"]
  node_forms["Input forms<br/>[forms.py]"]
  node_item_model["Item records<br/>[models.py]"]
  node_item_store[("SQLite database<br/>[settings.py]")]
  node_uploads[("Item images")]
  node_admin["Admin management<br/>[admin.py]"]
  node_search["Browse and search<br/>[views.py]"]
  node_dashboard["Dashboard<br/>[views.py]"]
  node_my_items["My items<br/>[views.py]"]
  node_resolution["Resolve reports<br/>[views.py]"]
end

subgraph group_identity["Accounts"]
  node_auth["Authentication<br/>[urls.py]"]
  node_registration["Registration<br/>[views.py]"]
end

subgraph group_matching["Matching"]
  node_matching_calls["Match selection<br/>[views.py]"]
  node_matching["AI similarity<br/>[ai_matching.py]"]
end

node_users(("Campus users"))
node_contact(("Item owners"))

node_users -->|"sends requests"| node_routing
node_routing -->|"routes"| node_item_routes
node_item_routes -->|"dispatches"| node_views
node_views -->|"renders pages"| node_templates
node_views -->|"validates input"| node_forms
node_views -->|"queries and saves"| node_item_model
node_item_model -->|"persists records"| node_item_store
node_forms -->|"defines fields"| node_item_model
node_views -->|"handles browsing"| node_search
node_views -->|"builds statistics"| node_dashboard
node_views -->|"filters owner posts"| node_my_items
node_views -->|"marks resolved"| node_resolution
node_views -->|"prepares candidates"| node_matching_calls
node_matching_calls -->|"requests matches"| node_matching
node_views -->|"uses login"| node_auth
node_views -->|"handles signup"| node_registration
node_registration -->|"logs in user"| node_auth
node_admin -->|"manages records"| node_item_model
node_users -.->|"contacts owner"| node_contact

click node_routing "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/campusLostAndFound/urls.py"
click node_item_routes "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/urls.py"
click node_views "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py"
click node_templates "https://github.com/yawar2518/campus-lost-and-found/tree/main/campusLostAndFound/templates"
click node_forms "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/forms.py"
click node_item_model "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/models.py"
click node_item_store "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/campusLostAndFound/settings.py"
click node_uploads "https://github.com/yawar2518/campus-lost-and-found/tree/main/campusLostAndFound/media/item_images"
click node_admin "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/admin.py"
click node_search "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py"
click node_dashboard "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py"
click node_my_items "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py"
click node_resolution "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py"
click node_auth "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/campusLostAndFound/urls.py"
click node_registration "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py"
click node_matching_calls "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py"
click node_matching "https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/ai_matching.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_routing,node_item_routes,node_views,node_templates,node_users toneBlue
class node_forms,node_item_model,node_item_store,node_uploads,node_admin,node_search,node_dashboard,node_my_items,node_resolution toneAmber
class node_auth,node_registration toneMint
class node_matching_calls,node_matching toneRose
class node_contact toneIndigo
```

## Components

### Web interface

- [URL routing](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/campusLostAndFound/urls.py): `campusLostAndFound/campusLostAndFound/urls.py`
- [Item routes](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/urls.py): `campusLostAndFound/items/urls.py`
- [Request views](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py): `campusLostAndFound/items/views.py`
- [Portal pages](https://github.com/yawar2518/campus-lost-and-found/tree/main/campusLostAndFound/templates): `campusLostAndFound/templates`

### Item reports

- [Input forms](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/forms.py): `campusLostAndFound/items/forms.py`
- [Item records](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/models.py): `campusLostAndFound/items/models.py`
- [SQLite database](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/campusLostAndFound/settings.py): `campusLostAndFound/campusLostAndFound/settings.py`
- [Item images](https://github.com/yawar2518/campus-lost-and-found/tree/main/campusLostAndFound/media/item_images): `campusLostAndFound/media/item_images`
- [Admin management](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/admin.py): `campusLostAndFound/items/admin.py`
- [Browse and search](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py): `campusLostAndFound/items/views.py`
- [Dashboard](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py): `campusLostAndFound/items/views.py`
- [My items](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py): `campusLostAndFound/items/views.py`
- [Resolve reports](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py): `campusLostAndFound/items/views.py`

### Accounts

- [Authentication](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/campusLostAndFound/urls.py): `campusLostAndFound/campusLostAndFound/urls.py`
- [Registration](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py): `campusLostAndFound/items/views.py`

### Matching

- [Match selection](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/views.py): `campusLostAndFound/items/views.py`
- [AI similarity](https://github.com/yawar2518/campus-lost-and-found/blob/main/campusLostAndFound/items/ai_matching.py): `campusLostAndFound/items/ai_matching.py`

### Other components

- **Campus users**
- **Item owners**

## Connections

- Campus users → URL routing: sends requests
- URL routing → Item routes: routes
- Item routes → Request views: dispatches
- Request views → Portal pages: renders pages
- Request views → Input forms: validates input
- Request views → Item records: queries and saves
- Item records → SQLite database: persists records
- Input forms → Item records: defines fields
- Request views → Browse and search: handles browsing
- Request views → Dashboard: builds statistics
- Request views → My items: filters owner posts
- Request views → Resolve reports: marks resolved
- Request views → Match selection: prepares candidates
- Match selection → AI similarity: requests matches
- Request views → Authentication: uses login
- Request views → Registration: handles signup
- Registration → Authentication: logs in user
- Admin management → Item records: manages records
- Campus users → Item owners: contacts owner
