diff --git a/.editorconfig b/.editorconfig
new file mode 100644
index 0000000..78a6420
--- /dev/null
+++ b/.editorconfig
@@ -0,0 +1,10 @@
+# EditorConfig is awesome: https://EditorConfig.org
+
+# Unix-style newlines with a newline ending every file
+[*]
+indent_style = space
+indent_size = 4
+end_of_line = lf
+charset = utf-8
+trim_trailing_whitespace = true
+insert_final_newline = true
diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 0000000..fc4f678
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1,10 @@
+.github/ export-ignore
+docs/ export-ignore
+Tests/ export-ignore
+.editorconfig export-ignore
+.git-blame-ignore-revs export-ignore
+.gitattributes export-ignore
+.gitignore export-ignore
+phpstan.neon export-ignore
+phpunit.xml.dist export-ignore
+ruleset.xml export-ignore
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
new file mode 100644
index 0000000..5e0e34e
--- /dev/null
+++ b/.github/workflows/ci.yml
@@ -0,0 +1,15 @@
+name: CI Joomla Framework
+
+on:
+ push:
+ pull_request:
+ schedule:
+ - cron: 15 2 * * 1
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
+ cancel-in-progress: true
+
+jobs:
+ framework-ci:
+ uses: joomla-framework/.github/.github/workflows/workflow-v4.yml@main
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..0439ad3
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,17 @@
+# IDE Related Files #
+.buildpath
+.project
+.settings
+.DS_Store
+.idea
+
+# Composer and test related files #
+vendor/
+composer.phar
+composer.lock
+phpunit.xml
+phpunit.*.xml
+.phpunit.cache/
+.idea/
+/.phpunit.result.cache
+/.phpunit.cache/
diff --git a/SECURITY.md b/SECURITY.md
new file mode 100644
index 0000000..e240890
--- /dev/null
+++ b/SECURITY.md
@@ -0,0 +1,20 @@
+# Security Policy
+
+## Supported Versions
+
+These versions are currently being supported with security updates:
+
+| Version | Supported |
+|---------| ------------------ |
+| 4.x.x | :white_check_mark: |
+
+## Reporting a Vulnerability
+
+To report a security issue in the core Joomla! CMS or Framework, or with a joomla.org website, please submit
+[the form on our portal](https://developer.joomla.org/security/contact-the-team.html) containing as much detail
+as possible about the issue. Additional information about our security team and their processes may be found on
+our [Security page](https://developer.joomla.org/security.html).
+
+To report an issue in a Joomla! extension, please submit it to the [Vulnerable Extensions List](https://vel.joomla.org/submit-vel).
+
+For support with a site which has been attacked, please visit the [Joomla! Forum](https://forum.joomla.org/viewforum.php?f=714).
diff --git a/composer.json b/composer.json
index 16d834b..3b7be4e 100644
--- a/composer.json
+++ b/composer.json
@@ -1,23 +1,20 @@
{
- "name": "joomla-framework/ai",
+ "name": "joomla/ai",
"type": "joomla-package",
"description": "Joomla AI Package",
"keywords": ["joomla", "framework", "ai"],
"homepage": "https://github.com/joomla-projects/gsoc25_ai_framework",
"license": "GPL-2.0-or-later",
- "repositories": [
- {
- "type": "vcs",
- "url": "https://github.com/joomla-framework/http.git"
- }
- ],
"require": {
- "php": "^8.1.0",
- "joomla/http": "dev-4.x-dev",
- "joomla/filesystem": "~3.0"
+ "php": "^8.3.0",
+ "joomla/http": "^4.0",
+ "joomla/filesystem": "^4.0"
},
"require-dev": {
- "phpunit/phpunit": "^9.5.28"
+ "phpunit/phpunit": "^12.0",
+ "squizlabs/php_codesniffer": "^3.10.2",
+ "phpstan/phpstan": "^2.1.17",
+ "phpstan/phpstan-deprecation-rules": "^2.0.3"
},
"autoload": {
"psr-4": {
@@ -29,4 +26,4 @@
"Joomla\\AI\\Tests\\": "Tests/"
}
}
-}
\ No newline at end of file
+}
diff --git a/docs/index.md b/docs/index.md
new file mode 100644
index 0000000..c87f1b4
--- /dev/null
+++ b/docs/index.md
@@ -0,0 +1 @@
+* [Overview](overview.md)
diff --git a/docs/overview.md b/docs/overview.md
new file mode 100644
index 0000000..063f86f
--- /dev/null
+++ b/docs/overview.md
@@ -0,0 +1,3 @@
+## Overview
+
+The AI package provides an abstraction layer to access the services of several AI providers.
diff --git a/phpstan.neon b/phpstan.neon
new file mode 100644
index 0000000..13fa968
--- /dev/null
+++ b/phpstan.neon
@@ -0,0 +1,10 @@
+
+includes:
+ - vendor/phpstan/phpstan-deprecation-rules/rules.neon
+
+parameters:
+ level: 5
+ phpVersion: 80300
+ reportUnmatchedIgnoredErrors: false
+ paths:
+ - src
diff --git a/phpunit.xml.dist b/phpunit.xml.dist
new file mode 100644
index 0000000..a4fd6ec
--- /dev/null
+++ b/phpunit.xml.dist
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Tests/Command
+ Tests/Monitor
+ Tests/Query
+ Tests/Service
+ Tests/AbstractDatabaseDriverTestCase.php
+ Tests/DatabaseAwareTraitTest.php
+ Tests/DatabaseExporterTest.php
+ Tests/DatabaseFactoryTest.php
+ Tests/DatabaseImporterTest.php
+ Tests/DatabaseIteratorTest.php
+ Tests/DatabaseQueryTest.php
+
+
+
diff --git a/ruleset.xml b/ruleset.xml
new file mode 100644
index 0000000..037a99b
--- /dev/null
+++ b/ruleset.xml
@@ -0,0 +1,21 @@
+
+
+
+ This is a PSR-12 compliant ruleset for Joomla.
+
+
+ src
+ Tests
+
+
+
+
+
+
+
+
+
+
+
+
+