| 1 |
<?php |
| 2 |
/** |
| 3 |
* AI |
| 4 |
* |
| 5 |
* @package ai |
| 6 |
* @author WordPress.org Contributors |
| 7 |
* @copyright 2025 Plugin Contributors |
| 8 |
* @license GPL-2.0-or-later |
| 9 |
* |
| 10 |
* @wordpress-plugin |
| 11 |
* Plugin Name: AI |
| 12 |
* Plugin URI: https://github.com/WordPress/ai |
| 13 |
* Description: AI features, experiments and capabilities for WordPress. |
| 14 |
* Version: 1.0.1 |
| 15 |
* Requires at least: 7.0 |
| 16 |
* Requires PHP: 7.4 |
| 17 |
* Author: WordPress.org Contributors |
| 18 |
* Author URI: https://make.wordpress.org/ai/ |
| 19 |
* License: GPL-2.0-or-later |
| 20 |
* License URI: https://spdx.org/licenses/GPL-2.0-or-later.html |
| 21 |
* Text Domain: ai |
| 22 |
*/ |
| 23 |
|
| 24 |
declare(strict_types=1); |
| 25 |
|
| 26 |
namespace WordPress\AI; |
| 27 |
|
| 28 |
// Exit if accessed directly. |
| 29 |
defined( 'ABSPATH' ) || exit; |
| 30 |
|
| 31 |
/** |
| 32 |
* Define the plugin constants. |
| 33 |
*/ |
| 34 |
function constants(): void { |
| 35 |
/** |
| 36 |
* Main plugin file path. |
| 37 |
*/ |
| 38 |
if ( ! defined( 'WPAI_PLUGIN_FILE' ) ) { |
| 39 |
define( 'WPAI_PLUGIN_FILE', __FILE__ ); |
| 40 |
} |
| 41 |
|
| 42 |
/** |
| 43 |
* Plugin version. |
| 44 |
*/ |
| 45 |
if ( ! defined( 'WPAI_VERSION' ) ) { |
| 46 |
define( 'WPAI_VERSION', '1.0.1' ); |
| 47 |
} |
| 48 |
|
| 49 |
/** |
| 50 |
* Plugin directory path. |
| 51 |
*/ |
| 52 |
if ( ! defined( 'WPAI_PLUGIN_DIR' ) ) { |
| 53 |
define( 'WPAI_PLUGIN_DIR', plugin_dir_path( WPAI_PLUGIN_FILE ) ); |
| 54 |
} |
| 55 |
|
| 56 |
/** |
| 57 |
* Plugin directory URL. |
| 58 |
*/ |
| 59 |
if ( ! defined( 'WPAI_PLUGIN_URL' ) ) { |
| 60 |
define( 'WPAI_PLUGIN_URL', plugin_dir_url( WPAI_PLUGIN_FILE ) ); |
| 61 |
} |
| 62 |
|
| 63 |
/** |
| 64 |
* Default ability category for the plugin. |
| 65 |
*/ |
| 66 |
if ( ! defined( 'WPAI_DEFAULT_ABILITY_CATEGORY' ) ) { |
| 67 |
define( 'WPAI_DEFAULT_ABILITY_CATEGORY', 'ai-experiments' ); |
| 68 |
} |
| 69 |
|
| 70 |
// Define other plugin constants here as needed. |
| 71 |
} |
| 72 |
constants(); |
| 73 |
|
| 74 |
// Load the autoloader. |
| 75 |
require_once WPAI_PLUGIN_DIR . 'includes/autoload.php'; |
| 76 |
|
| 77 |
\WordPress\AI\Main::get_instance(); |
| 78 |
|