Skip to content

miwidot/tarkovwikide

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

1 Commit
ย 
ย 

Repository files navigation

Tarkov Wiki Translation System - How It Works

๐Ÿ“š Table of Contents

  1. What is This System?
  2. Data Source & Credits
  3. How the Data Flows
  4. The Smart Translation System
  5. The Tarkov Wiki Website
  6. The Translation Tool (MCP)
  7. How Translations Work
  8. Real-World Example
  9. Technical Details

๐ŸŽฏ What is This System?

Imagine you have a massive website about the game "Escape from Tarkov" with over 4,000 items that need to be translated from English to German. Doing this manually would take months! This system automates the process using AI.

The Two Main Components:

  1. ๐ŸŒ Tarkov Wiki Website: A German gaming website that displays item information, quests, maps, and more from Escape from Tarkov
  2. ๐Ÿค– AI Translation Tool: A smart assistant (Claude) that can connect to the website's database and translate content automatically

Think of it like this:

  • The website is like a library with thousands of books (items)
  • The translation tool is like having a translator who can read all the books and rewrite them in German
  • The data source (tarkov.dev) provides all the game information in English

๐Ÿ™ Data Source & Credits

All Game Data Comes from tarkov.dev API

IMPORTANT: This project wouldn't exist without the amazing work of the tarkov.dev community!

The tarkov.dev API provides:

  • Real-time game data updated multiple times daily
  • 4,195+ items with complete statistics
  • Trader information and reset timers
  • Quest data with objectives and rewards
  • Ammunition ballistics and penetration values
  • Maps and boss spawn information
  • Market prices from the in-game flea market

We fetch this data regularly and store it in our database for translation. The tarkov.dev team does the hard work of:

  • Extracting data from the game files
  • Maintaining data accuracy
  • Providing a free, open API for the community
  • Updating whenever the game patches

Big thanks to the tarkov.dev team for making this possible! ๐ŸŽ‰


๐Ÿ“Š How the Data Flows

Here's the journey of data from the game to German players:

Escape from Tarkov (Game)
         โ†“
    tarkov.dev API
    (Extracts & maintains game data)
         โ†“
    Our Import System
    (Fetches data via API)
         โ†“
    MySQL Database
    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
    โ”‚ English Data | German Dataโ”‚
    โ”‚ (Protected)  | (Editable) โ”‚
    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
         โ†“
    MCP Translation Tool
    (Claude translates)
         โ†“
    German Website
    (Players see translations)

The Smart Column Protection System

Our database has a clever design to prevent translation conflicts:

Database Structure:

items table:
- name              (English - NEVER modified)
- name_german       (German translation)
- description       (English - NEVER modified)  
- description_german (German translation)

Why This Matters:

  1. English columns are sacred - We NEVER touch the original English data
  2. Updates don't break translations - When tarkov.dev updates, only English columns change
  3. German columns are preserved - Your translations remain safe during updates
  4. Easy comparison - Can always see original vs translation

The Update & Translation Cycle:

  1. Daily Data Fetch (Automated):

    tarkov.dev API โ†’ English columns only
    
  2. Detection System:

    -- Find items needing translation
    SELECT * FROM items 
    WHERE description_german = description
    -- This means German is same as English = needs translation
  3. MCP Auto-Translation:

    • Finds untranslated items automatically
    • Translates ONLY the German columns
    • Preserves all existing translations
  4. Smart Updates:

    • If tarkov.dev changes an item's English description
    • System detects: English changed but German didn't
    • Flags for re-translation without losing old work

๐Ÿค– The Smart Translation System

Automatic Translation Detection:

The system automatically knows what needs translation:

# Pseudo-code of how it works
if (description_german == description):
    # German is same as English = needs translation
    item_needs_translation = True
    
if (english_updated_date > german_updated_date):
    # English was updated after German = needs re-translation
    item_needs_update = True

Translation Protection Rules:

  1. Never Modify English Columns:

    UPDATE items SET name = 'New Name'  -- โŒ FORBIDDEN
    UPDATE items SET name_german = 'Neuer Name'  -- โœ… ALLOWED
  2. Preserve Existing Translations:

    • When tarkov.dev updates English data
    • German translations remain untouched
    • System flags changes for review
  3. Batch Translation Process:

    1. Fetch untranslated items (where German = English)
    2. Claude translates in batches of 50-100
    3. Updates ONLY German columns
    4. Marks items as translated
    

๐ŸŒ The Tarkov Wiki Website

What It Does:

The Tarkov Wiki is a comprehensive German resource for Escape from Tarkov players. It provides:

  • ๐Ÿ“ฆ Item Database: 4,195+ items with names, descriptions, and stats
  • ๐Ÿ”ซ Weapons & Ammo: Detailed ballistics and weapon statistics
  • ๐Ÿ—บ๏ธ Maps & Quests: Interactive maps and quest guides
  • ๐Ÿ‘ฅ Trader Information: Real-time trader reset timers
  • ๐Ÿ“Š Stats Dashboard: Tracks what players are searching for

Key Features Explained:

1. Smart Search System

  • Users can search in German (including special characters like รค, รถ, รผ)
  • Finds items instantly from thousands of entries
  • Shows results as you type

2. Real-Time Updates

  • Trader reset timers count down automatically
  • Prices update from the game's economy
  • New items are added as the game updates

3. Mobile Friendly

  • Works on phones, tablets, and computers
  • Adjusts layout automatically
  • Fast loading even on slow connections

Behind the Scenes:

The website uses three main technologies (think of them as different departments):

  1. Frontend (What users see):

    • HTML/CSS/JavaScript - The visual design and interactions
    • Like the storefront of a shop
  2. Backend (The brain):

    • Node.js server - Processes requests and manages data
    • Like the warehouse manager
  3. Database (The storage):

    • MySQL - Stores all items, translations, and data
    • Like a giant filing cabinet

๐Ÿค– The Translation Tool (MCP)

What is MCP?

MCP (Model Context Protocol) is a way for AI assistants like Claude to connect to external tools and databases. Think of it as giving Claude "hands" to reach out and touch other systems.

How the Translation Tool Works:

  1. Secure Connection:

    • Uses SSH (like a secure phone line) to connect to your server
    • All data is encrypted during transfer
    • Only authorized users can connect
  2. Database Access:

    • Reads data that needs translation
    • Writes translated content back
    • Can handle thousands of items in batches
  3. Smart Translation:

    • Claude understands gaming context (not just word-for-word)
    • Maintains consistency across translations
    • Can apply custom rules (like keeping brand names unchanged)

Translation Features:

Batch Processing

Instead of translating one item at a time, the tool can:

  • Grab 50-100 items at once
  • Translate them all together
  • Save everything back in one go

Custom Rules

You can set rules like:

  • Keep weapon names in English
  • Always translate "damage" as "Schaden"
  • Add [DE] prefix to translated items

Progress Tracking

  • See how many items are translated
  • Know which items still need work
  • Track translation quality

๐Ÿ“ How Translations Work

The Automated Translation Workflow:

The beauty of this system is how it automatically detects and handles translations:

Step 1: Automatic Detection

The system continuously monitors for:

  • New items from tarkov.dev (where German = English)
  • Updated items (where English changed but German didn't)
  • Items flagged for re-translation

Step 2: MCP Connection

When Claude connects via MCP, it can:

-- Instantly see what needs translation
SELECT COUNT(*) as untranslated 
FROM items 
WHERE description_german = description;

Step 3: Smart Batching

Claude processes items efficiently:

  • Groups similar items (all weapons, all meds, etc.)
  • Maintains consistency across related items
  • Uses gaming context for accurate translations

Step 4: Protection System in Action

-- Claude can ONLY do this:
UPDATE items 
SET name_german = 'Sturmgewehr AK-74M',
    description_german = 'Modernisierte Version...'
WHERE id = 'weapon_ak74m';

-- Claude CANNOT do this (English columns protected):
UPDATE items SET name = 'Something' -- โŒ Blocked

Step 5: Verification

The system tracks:

  • How many items translated today
  • Which items were updated
  • Translation completion percentage

Best Practices:

  1. Start Small: Translate 10-20 items first to check quality
  2. Review Samples: Look at translations before doing hundreds
  3. Use Consistent Terms: Create a glossary of gaming terms
  4. Backup First: Always backup your database before big changes

๐ŸŽฎ Real-World Example

Let's walk through translating weapon descriptions:

Scenario: Translating AK-74 Weapons

  1. Connect to Database:

    You: "Connect to my Tarkov database"
    Claude: "Connected successfully. I can see 4,195 items in the database."
    
  2. Find Untranslated Weapons:

    You: "Show me AK-74 weapons that need German translation"
    Claude: "Found 23 AK-74 variants without German descriptions."
    
  3. Set Context:

    You: "These are gaming items. Keep weapon names but translate descriptions. 
          Make them sound natural for German gamers."
    Claude: "Understood. I'll maintain weapon names and create gamer-friendly German descriptions."
    
  4. Translate:

    You: "Translate all 23 AK-74 weapons"
    Claude: "Translating... Done! Here's a sample:
            
            AK-74M:
            English: 'A modernized version of the AK-74 assault rifle'
            German: 'Eine modernisierte Version des AK-74 Sturmgewehrs'
            
            All 23 weapons have been translated and saved."
    
  5. Verify:

    • Go to your website
    • Search for "AK-74"
    • See the German descriptions appear

๐Ÿ’ก Technical Details

Why This Architecture?

  1. Data Integrity:

    • English data from tarkov.dev is never modified
    • German translations are isolated in separate columns
    • Updates don't overwrite translations
  2. Automation:

    • System auto-detects what needs translation
    • MCP tool provides direct database access
    • Claude handles translation context naturally
  3. Scalability:

    • Can handle 4,000+ items efficiently
    • Batch processing prevents overload
    • Parallel columns allow A/B comparison

The Column Protection System Explained:

// How the protection works internally
class DatabaseManager {
  // These columns are READ-ONLY
  protected_columns = ['name', 'description', 'short_name'];
  
  // These columns are EDITABLE
  translation_columns = ['name_german', 'description_german', 'short_name_german'];
  
  validateUpdate(column, value) {
    if (this.protected_columns.includes(column)) {
      throw new Error("Cannot modify English columns!");
    }
    // Only German columns can be updated
    return this.translation_columns.includes(column);
  }
}

Data Flow Architecture:

1. IMPORT PHASE (Daily)
   tarkov.dev API โ†’ Importer โ†’ English Columns Only
   
2. DETECTION PHASE (Continuous)  
   Monitor System โ†’ Find where German = English โ†’ Flag for translation
   
3. TRANSLATION PHASE (On-Demand)
   MCP Tool โ†’ Fetch Untranslated โ†’ Claude Translates โ†’ Update German Columns
   
4. SERVING PHASE (Real-time)
   Website reads German columns โ†’ Display to users

Database Performance Optimizations:

-- Indexes for fast translation detection
CREATE INDEX idx_needs_translation 
ON items((description_german = description));

-- Composite index for update tracking
CREATE INDEX idx_translation_status 
ON items(updated_at, description_german, description);

Translation Statistics:

The system tracks comprehensive metrics:

  • Total items: 4,195
  • Fully translated: ~90%
  • Daily translations: 50-200 items
  • Average translation time: 2-3 seconds per item
  • Batch efficiency: 50-100 items per session

๐ŸŽฏ Summary

This system brilliantly combines:

  1. tarkov.dev API - Provides fresh game data continuously
  2. Protected Database Design - English data stays pure, German translations are safe
  3. MCP Translation Tool - Claude directly accesses and translates data
  4. Smart Detection - Automatically finds what needs translation
  5. German Gaming Website - Serves translations to thousands of players

The Magic:

  • No manual copying - Everything flows automatically
  • No data loss - Translations are protected during updates
  • No conflicts - English and German data live separately
  • No delays - Translations appear on website immediately

Key Innovation:

The separation of English (protected) and German (editable) columns means:

  • tarkov.dev can update anytime without breaking translations
  • Claude can translate without touching source data
  • System always knows what needs work
  • Perfect data integrity maintained

๐Ÿ“ž Credits & Resources

๐Ÿ™ Special Thanks:

  • tarkov.dev - For providing the amazing API that powers all our data
  • Escape from Tarkov - Created by Battlestate Games
  • German Tarkov Community - For supporting the project
  • Claude & Anthropic - For the AI translation capabilities

๐Ÿ“š Learn More:

This project shows how modern AI tools can bridge language barriers in gaming, making content accessible to international communities while respecting and crediting original data sources. ๐Ÿš€

Releases

No releases published

Packages

 
 
 

Contributors