25'ten fazla konu seçemezsiniz Konular bir harf veya rakamla başlamalı, kısa çizgiler ('-') içerebilir ve en fazla 35 karakter uzunluğunda olabilir.

4.0KB

SKILLS.md

Purpose

This is the main skill index for AI coding agents working on MindVisionCode PHP.

Read this file after AGENTS.md, then load only the focused skill files needed for the current task.


Project Overview

MindVisionCode PHP is a small PHP MVC framework inspired by a Classic ASP MVC framework style.

The project favors:

  • Central dispatcher
  • Controllers and actions
  • ViewModels
  • Repository classes
  • Simple validation
  • Database migrations
  • Small, readable files
  • Minimal dependencies

Do not turn this into Laravel, Symfony, Slim, CakePHP, or another large framework.


Tech Stack

  • PHP 8.2+
  • Composer
  • PSR-4 autoloading
  • PDO
  • PHP views
  • Optional SQLite/MySQL/SQL Server through PDO
  • Minimal dependencies

Preferred Project Structure

project-root/
  AGENTS.md
  .ai/
    SKILLS.md
    skills/
      php/
        SKILL.md
      mvc/
        SKILL.md
      database/
        SKILL.md
      security/
        SKILL.md
      testing/
        SKILL.md
      workflow/
        SKILL.md
  public/
    index.php
  src/
    Controller/
    Service/
    Repository/
    Entity/
    ValueObject/
    ViewModel/
    Http/
    Routing/
    Validation/
    Database/
    Migration/
  templates/
  config/
  tests/
  var/
    cache/
    logs/
  vendor/
  composer.json

Rules:

  • public/ is the web root.
  • Do not expose src/, config/, tests/, vendor/, .ai/, or .env files through the web server.
  • Put application code under src/.
  • Put generated cache/log files under var/ or another ignored runtime directory.
  • Keep secrets outside the web root.

Setup Commands

Install dependencies:

composer install

Regenerate autoload files:

composer dump-autoload

Run local server:

php -S localhost:8000 -t public

Run basic tests:

php tests/run.php

Request Flow

Browser
  → public/index.php
  → Request
  → Dispatcher
  → Router
  → Route
  → Controller
  → ViewModel/Repository/Service
  → View
  → Response

Skill Routes

PHP Language, Style, Composer, OOP

Read:

./.ai/skills/php/SKILL.md

Use for:

  • PHP version decisions
  • PSR standards
  • Composer dependencies
  • Namespaces and autoloading
  • OOP design
  • Dependency injection
  • Documentation and PHPDoc
  • Performance and caching

MVC Framework Architecture

Read:

./.ai/skills/mvc/SKILL.md

Use for:

  • Dispatcher changes
  • Router changes
  • Controllers and actions
  • ViewModels
  • PHP templates/views
  • HTTP request/response flow
  • Framework structure

Database and Persistence

Read:

./.ai/skills/database/SKILL.md

Use for:

  • PDO
  • SQL
  • Repositories
  • Migrations
  • Transactions
  • Database configuration
  • SQLite/MySQL/SQL Server support

Security

Read:

./.ai/skills/security/SKILL.md

Use for:

  • Input validation
  • Output escaping
  • Passwords
  • Authentication
  • Authorization
  • Sessions
  • CSRF
  • Secrets
  • Error disclosure
  • Dangerous functions

Testing and Quality

Read:

./.ai/skills/testing/SKILL.md

Use for:

  • Tests
  • Test runner changes
  • Static analysis
  • Composer quality scripts
  • Code style tools
  • Verification steps

Agent Workflow

Read:

./.ai/skills/workflow/SKILL.md

Use for:

  • Multi-file changes
  • Pull-request style review
  • Legacy PHP changes
  • Non-negotiable rules
  • Response format
  • Skill feedback updates

Default Coding Rules

  • Keep code simple and readable.
  • Prefer small classes.
  • Use typed properties and return types where practical.
  • Avoid hidden magic.
  • Do not add dependencies without a clear reason.
  • Preserve the framework style.
  • Explain any architectural changes.

Default Security Rules

  • Validate input.
  • Escape output.
  • Use prepared statements for SQL.
  • Do not expose sensitive errors.
  • Check authorization separately from authentication.

Default Testing Rules

  • Add or update tests for meaningful behavior changes.
  • Explain how to verify changes.
  • If tests are not added, explain why.

Powered by TurnKey Linux.