Skip to content

QVAC-13595 feat[api]: Add Bergamot pivot translation support#834

Merged
RamazTs merged 8 commits into
tetherto:mainfrom
RamazTs:QVAC-13595_sdk-bergamot-pivot-support
Mar 13, 2026
Merged

QVAC-13595 feat[api]: Add Bergamot pivot translation support#834
RamazTs merged 8 commits into
tetherto:mainfrom
RamazTs:QVAC-13595_sdk-bergamot-pivot-support

Conversation

@RamazTs

@RamazTs RamazTs commented Mar 11, 2026

Copy link
Copy Markdown
Contributor

🎯 What problem does this PR solve?

  • Enables pivot translation through intermediate languages using Bergamot models
  • Allows translations between language pairs without direct models (e.g., Spanish to Italian via English)
  • Extends SDK translation capabilities for more language combinations

📝 How does it solve it?

  • Adds pivotModel configuration to Bergamot translation config schema
  • Implements pivot model loading and path resolution in nmtcpp plugin
  • Updates dependency to @qvac/translation-nmtcpp@0.6.1 for pivot support
  • Includes complete example demonstrating Spanish → English → Italian translation

🧪 How was it tested?

  • Created translation-bergamot-pivot.ts example with full pivot translation workflow
  • Example demonstrates loading both primary and pivot models with proper configuration

🔌 API Changes

// New pivot translation API usage
await loadModel({
  modelSrc: BERGAMOT_ES_EN,  // Primary: Spanish → English
  modelType: "nmt",
  modelConfig: {
    engine: "Bergamot",
    from: "es",
    to: "it",  // Final target language
    // New pivotModel configuration
    pivotModel: {
      modelSrc: BERGAMOT_EN_IT,  // Pivot: English → Italian
      beamsize: 4,
      temperature: 0.3,
      topk: 100,
      normalize: 1,
      lengthpenalty: 1.2,
    }
  }
});

@RamazTs RamazTs requested review from a team as code owners March 11, 2026 18:23
olyasir
olyasir previously approved these changes Mar 11, 2026
NamelsKing
NamelsKing previously approved these changes Mar 12, 2026
@RamazTs RamazTs dismissed stale reviews from NamelsKing and olyasir via d54bb28 March 12, 2026 14:41
@RamazTs

RamazTs commented Mar 12, 2026

Copy link
Copy Markdown
Contributor Author

/review

@github-actions

github-actions Bot commented Mar 12, 2026

Copy link
Copy Markdown
Contributor

Tier-based Approval Status

**PR Tier:** TIER1

**Current Status:** ✅ APPROVED

**Requirements:**
- 1 Team Member approval ❌ (0/1)
- 1 Team Lead OR Management approval ✅ (2/1)

**Bypass rule:** Triggered (2+ Team Lead approvals (Tier 1 exception)). This PR is approved regardless of tier.

---
*This comment is automatically updated when reviews change.*

@RamazTs

RamazTs commented Mar 13, 2026

Copy link
Copy Markdown
Contributor Author

/review

@RamazTs RamazTs merged commit b7dd067 into tetherto:main Mar 13, 2026
12 checks passed
Proletter pushed a commit that referenced this pull request May 24, 2026
* Enables pivot translation through intermediate languages using Bergamot models
* Allows translations between language pairs without direct models (e.g., Spanish to Italian via English)
* Extends SDK translation capabilities for more language combinations
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants