Skip to content
Projects

About

MetaOpenFOAM: an LLM-based multi-agent framework for CFD

AI & Machine Learning

How these counts are measured

Measured star growth

in 24h
0
in 7 days
+2
in 15 days
+2
in 1 month
Collecting history

Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.

README_en.md

Original
<!-- README_en.md -->

# ⚠️ This project is deprecated

> **This version of MetaOpenFOAM is deprecated and no longer maintained.** All capabilities of MetaOpenFOAM have been fully integrated into **[sim-cli](https://github.com/svd-ai-lab/sim-cli)**, which will continue to be actively developed. Please visit sim-cli for the latest version.
>
> 👉 **https://github.com/svd-ai-lab/sim-cli**

---

# MetaOpenFOAM One‑Click Installation Guide

> **Version**: 2025‑04‑18  
> **Overview**: Set up the entire development environment, dependencies, and build MetaOpenFOAM with a single script.

---

## Table of Contents

- [Prerequisites](#prerequisites)  
- [One‑Click Install](#one-click-install)  
- [Usage](#usage)  
  - [Activate Environment](#activate-environment)  
  - [Activate OpenFOAM](#activate-openfoam)  
  - [Configure Inputs](#configure-inputs)  
  - [Edit Makefile](#edit-makefile)  
  - [First Run](#first-run)  
  - [Run Main Program](#run-main-program)  
- [FAQ](#faq)  
- [Contributing & Support](#contributing--support)

---

## Prerequisites

1. **Conda** installed (Miniconda / Anaconda)  
2. **OpenFOAM‑10** installed and sourced (`source $WM_PROJECT_DIR/etc/bashrc`)  
3. Repository root contains:  
   - `environment.yml`  
   - `requirements.txt`  
   - `MetaGPT/` (local source)  
   - `active_subspaces/` (local source)  
   - `MetaOpenFOAM/` (MetaOpenFOAM source)  
   - `install_metaopenfoam.sh` (installation script)

---

## One‑Click Install

```bash
# 1. Grant execute permission
chmod +x install_metaopenfoam.sh

# 2. Run the installer
./install_metaopenfoam.sh

This script will:

  • Create & activate a Conda env at ./metaopenfoam_env
  • Install all Python dependencies (including local MetaGPT & active_subspaces)
  • Add MetaOpenFOAM/ to PYTHONPATH
  • Build and compile MetaOpenFOAM

Usage

Activate Environment

conda activate ./metaopenfoam_env

Activate OpenFOAM

source $WM_PROJECT_DIR/etc/bashrc

Configure Inputs

Edit inputs/config.yaml with your case settings:

usr_requirement: >-
  do a RANS simulation of buoyantCavity using buoyantFoam, which
  investigates natural convection in a heat cavity with a temperature
  difference of 20K between the hot and cold walls; remaining patches
  are adiabatic. Case name: Buoyant_Cavity

max_loop:    10
temperature: 0.0
batchsize:   10
searchdocs:  2
run_times:   1

MetaGPT_PATH:    "MetaGPT/"
DEEPSEEK_API_KEY: "YOUR_DEEPSEEK_KEY"
DEEPSEEK_BASE_URL:"https://api.deepseek.com"
model:           "deepseek-chat"

# —— Optional: Uncomment for OpenAI model —— 
# OPENAI_API_KEY:    "YOUR_OPENAI_KEY"
# OPENAI_PROXY:      "http://127.0.0.1:8118"
# OPENAI_BASE_URL:   "https://api.openai-proxy.com/v1"
# model:            "gpt-4o"

Note: Supports openai and deepseek models. Default uses HuggingFace Embedding; switch to OpenAI for the embedding method in the paper.

Edit Makefile

In the project root Makefile, adjust:

# Python interpreter (e.g. python3)
PYTHON     = python

# Input case name (matches filename in inputs/, without extension)
Case_input = Buoyant_Cavity

First Run

make
  • Initializes the database
  • Builds the project

Run Main Program

make run_main

FAQ

  • Script failed halfway—how to retry?
    Re-run ./install_metaopenfoam.sh. It skips completed steps and finishes the rest.

Contributing & Support

Feel free to open Issues or submit Pull Requests!

© 2025 MetaOpenFOAM Project Maintainers

Explore related projects

Loading…