cityhive / rules
Cursor rule2 starsChanged 18 months agoMITArchived repositoryView on GitHub
CityHive Project Overview
Where files are headingNew Cursor rule files have more rules about planning and tracking tasks, and fewer about code style.
Of the Cursor rule files we read, the 1,533 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository6 other files it gives its agents.
- .cursor/rules/always-enable-context7.mdcCursor rule
- .cursor/rules/cursor-rules.mdcCursor rule
- .cursor/rules/dependency-management.mdcCursor rule
- .cursor/rules/project-patterns.mdcCursor rule
- .cursor/rules/python-standards.mdcCursor rule
- .cursor/rules/testing-guidelines.mdcCursor rule
The file
We split this project-overview.mdc into the rules it gives an agent
2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 38
Test-Driven: All features need tests
- Distinctive: line 40
Async-First: All I/O operations use async/await patterns
≈ “Common” is an estimate: at least 1 in 5 of the 3,030 Cursor rule files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
--- description: CityHive Project Overview globs: alwaysApply: true --- # CityHive Project Overview **Context for AI:** This is a Python 3.12 project using clean architecture patterns with domain-driven design. ## Project Structure - **Web Application Layer**: `cityhive/app/` - aiohttp web server, routes, views, middleware - **Domain Layer**: `cityhive/domain/` - Business logic, services, and models - **Infrastructure Layer**: `cityhive/infrastructure/` - External integrations, database, config - **Tests**: `tests/unit/` and `tests/integration/` - Comprehensive test coverage required ## Technology Stack - **Language**: Python 3.12 - **Web Framework**: aiohttp with Jinja2 templates - **Database**: PostgreSQL + PostGIS with SQLAlchemy async - **Testing**: Pytest with coverage - **Package Management**: uv (NEVER pip) - **Linting**: Ruff (configured in pyproject.toml) ## Web Application Architecture - **Application Factory**: Async `create_app()` function with dependency injection - **Type-Safe Storage**: `web.AppKey` for application-wide data - **Middleware Stack**: Logging → Error handling → Routes - **Database Context**: SQLAlchemy async sessions with cleanup contexts - **Health Monitoring**: `/health` endpoint for production monitoring ## Key Development Principles - **Clean Architecture**: Separate concerns between web, domain, and infrastructure - **Type Safety**: Type hints required throughout - **Test-Driven**: All features need tests - **Domain-Driven**: Business logic stays in domain layer - **Async-First**: All I/O operations use async/await patterns ## Essential Commands - **Install dependencies**: `uv add package-name` - **Run application**: `uv run python -m cityhive.app` - **Run tests**: `uv run pytest ./tests` - **Lint code**: `uv run ruff check` - **Format code**: `uv run ruff format` ## Database - PostgreSQL with PostGIS extensions - Alembic migrations in `migration/` directory - Development database via docker-compose - Async SQLAlchemy with connection pooling --- **See also:** - [python-standards.mdc](mdc:.cursor/rules/python-standards.mdc) for coding conventions - [testing-guidelines.mdc](mdc:.cursor/rules/testing-guidelines.mdc) for test practices - [Development Guide](mdc:docs/development.md) for setup and workflows - [Architecture Guide](mdc:docs/architecture.md) for detailed design patterns - [Coding Standards](mdc:docs/coding-standards.md) for comprehensive style guide
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

