Download the PHP package harmovich67/ai-translator without Composer

On this page you can find all versions of the php package harmovich67/ai-translator. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package ai-translator

TrueVs AI Translator

A reusable PHP 8.1+ package that combines:

The core has no framework dependency. The Laravel bridge is loaded only inside Laravel.

التثبيت السريع في Laravel

لو الحزمة في فولدر محلي بجانب مشروعك، أضفها كـ path repository:

ثم نفّذ:

بعد نشر الإعدادات عدّل config/ai-translator.php، ثم أضف قبل </body> في كل Blade layout:

وفي الـ admin header، أو أي مكان مناسب للمشرف:

صفحة الإدارة الافتراضية: /ai-translator. هي محمية بـ web وauth. غيّر middleware أو عرّف gate في الإعدادات لو مشروعك يستخدم guard/permission مختلفًا.

فعّل Gemini في .env:

المفتاح لا يصل إلى المتصفح. يمكن أيضًا حفظه من صفحة الإدارة، لكن متغير البيئة أفضل في الإنتاج.

Configure content tables

Live editing only writes to explicitly allowed tables. A table needs an integer id and locale-suffixed columns such as title_ar, title_en, features_ar, and features_en:

examples/truevs-laravel-config.php contains the ready mapping for the source True Ventures schema, including its settings table.

Localized models

The trait works with Eloquent models and plain PHP objects:

Resolution order is field_currentLocale, a locale map stored in the base field, then the fallback-locale column.

Translation files

Laravel continues to use its native helper:

Overrides saved by the package are injected into Laravel's translator during boot. For standalone PHP, use FileTranslator directly:

Standalone Composer usage

Install from Packagist after publishing:

Or use the same Composer path repository shown above. A minimal framework-free example is in examples/standalone.php.

Use JsonFileSettingsStore for a zero-database setup. For PDO storage:

The PDO table needs these columns: key (primary string), value (text), group (string), created_at, and updated_at. The full live resolver uses the same DatabaseConnection, ContentResolver, ContentWriter, Dictionary, and Manager classes, so a custom framework only needs to expose five authenticated POST endpoints matching the included JavaScript:

Laravel registers these automatically.

How live translation stores data

Visible text source Storage
field_ar / field_en content The exact localized row columns
Key/value content setting The configured host settings table
lang/<locale>/*.php line A package override; source files remain unchanged
Text written directly in a template The package dictionary, applied by runtime.js

Matching is exact after safe whitespace/entity normalization. Saving re-reads the source and refuses stale changes. Empty locale values never blank existing content. Client-supplied database references are accepted only if the resolver independently finds them again.

Full-page translation

When Gemini is enabled, the editor adds Translate page. It scans visible text, resolves where each item lives, skips complete items, translates missing locales in batches of 20, and opens a review dialog. Nothing is stored until the administrator chooses rows and saves them. live.scan_limit caps one page scan (default: 60).

Security checklist

Development

The test suite is dependency-free and also runs the PDO resolver/writer integration test when pdo_sqlite is installed.


All versions of ai-translator with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
ext-json Version *
ext-mbstring Version *
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package harmovich67/ai-translator contains the following files

Loading the files please wait ...