Code Translation Application

August 11, 2025 · View on GitHub

Code translation is the process of converting code written in one programming language to another programming language while maintaining the same functionality. This process is also known as code conversion, source-to-source translation, or transpilation. Code translation is often performed when developers want to take advantage of new programming languages, improve code performance, or maintain legacy systems. Some common examples include translating code from Python to Java, or from JavaScript to TypeScript.

Table of Contents

  1. Architecture
  2. Deployment Options
  3. Monitoring and Tracing

Architecture

The CodeTrans application is an end-to-end workflow that leverages the capability of LLMs. The workflow falls into the following architecture:

architecture

The CodeTrans example is implemented using the component-level microservices defined in GenAIComps.

This Code Translation use case demonstrates Text Generation Inference across multiple platforms. Currently, we provide examples for Intel Gaudi2, Intel Xeon Scalable Processors and AMD EPYC™ Processors, and we invite contributions from other hardware vendors to expand OPEA ecosystem.

Deployment Options

The table below lists currently available deployment options. They outline in detail the implementation of this example on selected hardware.

CategoryDeployment OptionDescription
On-premise DeploymentsDocker composeCodeTrans deployment on Xeon
CodeTrans deployment on Gaudi
CodeTrans deployment on AMD EPYC
CodeTrans deployment on AMD ROCm
KubernetesHelm Charts
AzureWork-in-progress
Intel Tiber AI CloudWork-in-progress

Validated Configurations

Deploy MethodLLM EngineLLM ModelHardware
Docker ComposevLLM, TGIQwen/Qwen2.5-Coder-7B-InstructIntel Gaudi
Docker ComposevLLM, TGIQwen/Qwen2.5-Coder-7B-InstructIntel Xeon
Docker ComposevLLM, TGIQwen/Qwen2.5-Coder-7B-InstructAMD EPYC
Docker ComposevLLM, TGIQwen/Qwen2.5-Coder-7B-InstructAMD ROCm
Helm ChartsvLLM, TGIQwen/Qwen2.5-Coder-7B-InstructIntel Gaudi
Helm ChartsvLLM, TGIQwen/Qwen2.5-Coder-7B-InstructIntel Xeon
Helm ChartsvLLM, TGIQwen/Qwen2.5-Coder-7B-InstructAMD ROCm