PHPackages                             diversen/gpt-translate - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. diversen/gpt-translate

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

diversen/gpt-translate
======================

Translate long texts using GPT

v1.2.1(2y ago)212MITPHP

Since Apr 1Pushed 2y ago1 watchersCompare

[ Source](https://github.com/diversen/gpt-translate)[ Packagist](https://packagist.org/packages/diversen/gpt-translate)[ RSS](/packages/diversen-gpt-translate/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (1)Versions (5)Used By (0)

README
======

[](#readme)

This is minimal howto about translating a long text using GPT using php. It may translate markdown texts, e.g. a novel, from one language to another. It does the job quite well, but in any case you will need to edit the translated document if you want a translation of high quality.

The auto-translation may serve as a good starting point.

It is only tested using markdown text. It will split a document into small parts based on double lines. And then translate one section at a time.

Usage
-----

[](#usage)

This example will make an effort to translate the first the part of the danish novel 'Lykke Per' (A Fortunate Man) into english.

```
git clone git@github.com:diversen/gpt-translate.git
cd gpt-translate
composer install

```

You will need to change the api key in [examples/example\_1/index.php](examples/example_1/index.php)Then run:

```
php examples/example_1/index.php

```

(There is also a couple of other examples).

As library
----------

[](#as-library)

```
composer require diversen/gpt-translate

```

Usage is the same as in [examples/example\_1/index.php](examples/example_1/index.php)

Related
-------

[](#related)

This repo will try and fetch a URL and turn a html page into markdown:

License
-------

[](#license)

MIT © [Dennis Iversen](https://github.com/diversen)

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~66 days

Total

4

Last Release

935d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/23ed91d104f16d10414811ecdafbd5c80a660e658d80ccaadf84f512cfb50629?d=identicon)[diversen](/maintainers/diversen)

---

Top Contributors

[![diversen](https://avatars.githubusercontent.com/u/142675?v=4)](https://github.com/diversen "diversen (20 commits)")

### Embed Badge

![Health badge](/badges/diversen-gpt-translate/health.svg)

```
[![Health](https://phpackages.com/badges/diversen-gpt-translate/health.svg)](https://phpackages.com/packages/diversen-gpt-translate)
```

###  Alternatives

[marcelog/pami

Asterisk Manager Interface (AMI) client for PHP, event driven, object oriented

415750.6k1](/packages/marcelog-pami)[spicyweb/craft-neo

A Matrix-like field type with block hierarchy

395798.1k10](/packages/spicyweb-craft-neo)[geedmo/yamm3

Yet another megamenu for Bootstrap 3.x

1.2k12.6k](/packages/geedmo-yamm3)[verbb/navigation

Create navigation menus for your site.

90683.7k17](/packages/verbb-navigation)[fusonic/opengraph

PHP library for consuming and publishing Open Graph resources.

104373.0k4](/packages/fusonic-opengraph)[jn-jairo/laravel-ngrok

Share Laravel application with ngrok.

95204.0k1](/packages/jn-jairo-laravel-ngrok)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
