Skip to content

Welcome

Welcome to the documentation for CodeTransEngine. This is a ready-to-use backend for Large Language Model (LLM) based code translation across programming languages. This tool enables practitioners to translate source code across programming languages at scale, by leveraging off-the-shelf Large Language Models (LLM). This backend integrates the Tree of Code Translation (ToCT) algorithm used in the InterTrans Paper and earlier methodologies such as zero-shot prompting and few-shot prompting.

🌟 Why use CodeTransEngine?

CodeTransEngine serves as a backend for code translation, helping you save time and effort in building such infrastructure from scratch. It is extensible and high-performant due to its concurrent architecture and other optimizations.

Features

  • 🧠 Multiple algorithms (InterTrans, Direct Translation, Few-shot Prompting and more)
  • ⚡ Efficient inference using vLLM as backend and OpenAI Compatible APIs
  • 🌐 Distributed inference supported
  • 🛡️ Safe and containerized code execution
  • 📊 Automatic translation evaluation using test-cases
  • 🔧 Extensible to new datasets, prompts and translation algorithms
  • ♻️ Configurable cache for resource saving
  • 🚆 Fully concurrent architecture for maximum throughput or sequential for resource saving
  • 🔗 Can be used standalone or integrated into existing workflows for code translation

Advantages of using CodeTransEngine

🏢 For Industrial Applications:

  • Time-Saving: A ready-to-use, high-performance pipeline eliminates the time and effort of building infrastructure from scratch.
  • Scalability: Fully concurrent architecture maximizes throughput or allows for sequential processing to optimize resource usage.
  • Seamless Integration: Can be used standalone or integrated into existing workflows for code translation.
  • Efficiency Improvements: Configurable caching leads to significant resource savings, optimizing compute and storage costs.
  • Safe & Reliable: Ensures secure code execution using Singularity containers, giving confidence in large-scale deployments or sensitive projects.

🎓 For Researchers:

  • Rigorous Comparisons: Ensures trustworthy, comparable results by standarizing inference, code processing and verification. This reduces the risk of bias or inconsistencies in the evaluation process, which is important when comparing results across works.
  • Increased Reproducibility: Benefit from enhacinging the reproducibility of your research by leveraging ready-to-use open-source tools.
  • Extensive to New Methodologies: Easily integrates as a backend to test cutting-edge techniques or new research ideas. Incorporate agents, compiler feedback, or other methodologies while leveraging CodeTransEngine as a backend.