An Azure Function that translates text between English (Common) and the Drow language. This project is inspired by a 2003 Perl script by Brian Sidharta, focusing on translating English to Drow and vice versa using an SQLite database for the word list.
- Translate text from English to Drow and from Drow to English.
- Handles plurals, possessives, and contractions.
- Utilizes an SQLite database for efficient word lookup.
- Web UI served directly from the function.
- REST API with plain-text and JSON endpoints.
- Returns plain text responses for easy integration with applications like Second Life scripts.
- Configurable for any constructed language — all language-specific settings live in a single
Data/language.jsonfile.
- .NET SDK (version 10 or later)
- Azure Functions Core Tools (for local development and testing)
- Python 3 (for dictionary maintenance scripts only)
- NuGet Packages (restored automatically via
dotnet restore):Microsoft.Azure.Functions.Workerand related extensionsMicrosoft.Data.Sqlite(SQLite database access)Humanizer.Core(pluralization and singularization)Microsoft.Azure.Functions.Worker.Extensions.OpenApi(Swagger / OpenAPI docs for isolated worker)
git clone https://github.com/auroris/DrowTranslatascan.git
cd DrowTranslatascandotnet restoreCreate a local.settings.json in the project root (this file is not committed to source control):
{
"IsEncrypted": false,
"Values": {
"AzureWebJobsStorage": "UseDevelopmentStorage=true",
"FUNCTIONS_WORKER_RUNTIME": "dotnet-isolated"
},
"ConnectionStrings": {}
}dotnet buildfunc startThe function will be available at http://localhost:7071.
Open http://localhost:7071/api/Home (or just http://localhost:7071/ — it redirects) in a browser for the dark-fantasy themed translator UI.
GET|POST /api/Translate?text={text}&lang={Drow|Common}
Returns translated text as text/plain.
Example:
curl "http://localhost:7071/api/Translate?text=Hello,+how+are+you?&lang=Drow"Response:
Vendui, lu'oh ph' dos?
POST /api/TranslateJson
Content-Type: application/json
{"text": "Hello, how are you?", "lang": "Drow"}
Response:
{
"translation": "Vendui, lu'oh ph' dos?",
"originalText": "Hello, how are you?",
"targetLanguage": "Drow"
}text: The text to translate.lang: Target language —Drow(English → Drow) orCommon(Drow → English).
With the function running locally, visit:
- Swagger UI:
http://localhost:7071/swagger/index.html - OpenAPI spec:
http://localhost:7071/swagger/v1/swagger.json
cd drowtest
dotnet runWant to adapt this project for your own constructed language? Everything language-specific is driven by Data/language.json — no C# changes required for most conlangs.
- TUTORIAL.md — Step-by-step guide: fork the project, edit the config, provide a dictionary, and run. Includes a worked example building a "Sylvan" translator from scratch.
- LLM_CONLANG_GUIDE.md — Instruction file for LLM assistants (Claude, ChatGPT, etc.) helping you design your conlang's rules, build a dictionary, and configure the translator. Feed this file to your AI assistant to get structured help with phonology, pluralization, cipher tables, and vocabulary generation.
The word list lives in Data/drow_dictionary.csv and is compiled into Data/drow_dictionary.db (SQLite). See scripts/README.md for full instructions on finding missing words and adding new entries.
Quick reference:
# Find common English words not yet in the dictionary
python3 scripts/missing_words.py
# Add new entries and rebuild the database
python3 scripts/patch_missing_words.pyDeploy the Azure Function to your Azure account using your preferred deployment method (e.g., Visual Studio publish, Azure CLI, or GitHub Actions).
Ensure that the Data folder and the drow_dictionary.db file are included in your deployment package.
By default, Azure Functions shows its own homepage at /. To disable it so that the / → /api/Home redirect works correctly, set the following application setting in the Azure Portal:
| Setting | Value |
|---|---|
AzureWebJobsDisableHomepage |
true |
This can be configured under Configuration → Application settings in your Function App's Azure Portal page.
DrowTranslatascan/
├── Data/ # Dictionary (CSV + SQLite DB) and language.json config
├── analysis/ # Corpus analysis scripts and output (phonotactics)
├── drowtest/ # Test runner project
├── lsl/ # Second Life LSL script example
├── scripts/ # Dictionary maintenance scripts (see scripts/README.md)
├── tel'mithrim/ # Original unmodified Tel'Mithrim word list and license
├── AlgorithmicConverter.cs # Fallback algorithmic conversion (config-driven)
├── HomeFunction.cs # Web UI (themed HTML, config-driven)
├── LanguageConfig.cs # Language configuration model (deserialized from language.json)
├── Program.cs # Host configuration and startup
├── ProgramState.cs # Shared program state (DB path, language config)
├── Translate.cs # Translation logic and HTTP trigger functions
├── TranslateModels.cs # Request/response model types
├── TUTORIAL.md # Guide: adapt this project for your own conlang
└── LLM_CONLANG_GUIDE.md # Instructions for LLM assistants helping build a conlang
This project is licensed under the MIT License.
The original Drow word list is by Tel'Mithrim/Brian Sidharta and is licensed under Tel'Mithrim/Brian Sidharta's Software License Version 1.0. The unmodified original is preserved in tel'mithrim/. The version in Data/ is a derivative work distributed under the same license terms.
- Tel'Mithrim/The Grey Company and Brian Sidharta: For developing the original Drow dictionary and Perl script. See
tel'mithrim/WORDLIST_LICENSE.md. - Humanizer Library: For providing pluralization and singularization utilities.
Contributions are welcome! Please open an issue or submit a pull request for any improvements or additions.
For questions or support, please open an issue.