Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
170 commits
Select commit Hold shift + click to select a range
0231805
feat(Navbar): add color mode toggle and update navbar styles for ligh…
alwaysmavs Nov 5, 2025
fe4710a
refactor: remove unused pages and styles for about-us, oomol-api, oom…
alwaysmavs Nov 10, 2025
fc32347
feat: implement OOMOL design tokens for consistent theming across lig…
alwaysmavs Nov 10, 2025
39a84e4
refactor(styles): update styles to use OOMOL design tokens for consis…
alwaysmavs Nov 10, 2025
f08e581
refactor(styles): update styles to use OOMOL design tokens for color …
alwaysmavs Nov 10, 2025
2763e71
refactor(styles): update styles to use OOMOL design tokens for consis…
alwaysmavs Nov 10, 2025
ab5aaee
refactor(styles): replace hardcoded colors and backgrounds with OOMOL…
alwaysmavs Nov 10, 2025
2974293
refactor(styles): update button styles for consistency with OOMOL des…
alwaysmavs Nov 10, 2025
e26d066
refactor(pricing): update styles and SVG stroke color for consistency…
alwaysmavs Nov 10, 2025
924ae15
refactor(styles): move color definition for signInButton to theme-spe…
alwaysmavs Nov 10, 2025
a21b19d
chore: update @iconify/json to version 2.2.405 and mark several depen…
alwaysmavs Nov 10, 2025
a904d29
refactor(community): replace SVG icons with Iconify components for im…
alwaysmavs Nov 10, 2025
bf46e6a
refactor(support, footer): replace image components with icon classes…
alwaysmavs Nov 10, 2025
2cc6fe8
refactor(downloads): update color definitions to use design tokens fo…
alwaysmavs Nov 10, 2025
ac38b1b
refactor(pricing): replace hardcoded color values with design token f…
alwaysmavs Nov 10, 2025
6390763
refactor(pricing): update styles to use design tokens for consistency…
alwaysmavs Nov 10, 2025
f4f4dbc
refactor(LocalDropdown): update item colors for consistency with desi…
alwaysmavs Nov 10, 2025
5b7e8a5
refactor(babel): remove unused Babel configuration file
alwaysmavs Nov 10, 2025
674e45b
refactor(index.mdx): update info block syntax for consistency
alwaysmavs Nov 10, 2025
39f8769
Implement code changes to enhance functionality and improve performance
alwaysmavs Nov 10, 2025
3416dcc
refactor(docusaurus.config.js): move onBrokenMarkdownLinks to markdow…
alwaysmavs Nov 10, 2025
1c6971e
feat(Footer): add color mode toggle and update styles for better acce…
alwaysmavs Nov 10, 2025
075787d
refactor(Navbar): remove color mode toggle and related imports for cl…
alwaysmavs Nov 10, 2025
003bcc3
fix(LocalDropdown): ensure language button color is consistent in dar…
alwaysmavs Nov 10, 2025
6f7e653
feat(Footer): integrate ColorModeDropdown for theme switching and upd…
alwaysmavs Nov 10, 2025
ff7f284
fix(styles): update button text color to use var(--oomol-white) for c…
alwaysmavs Nov 10, 2025
7744f1d
feat(Navbar): update gotoHubButton to use anchor tag for improved nav…
alwaysmavs Nov 10, 2025
a8a7ec7
feat(Button): add ariaLabel and type props for accessibility and flex…
alwaysmavs Nov 10, 2025
34256f3
feat(Navbar): add dark mode styles for navbar with improved backgroun…
alwaysmavs Nov 10, 2025
838d4ed
Add new logo SVG files for English and Chinese versions
alwaysmavs Nov 10, 2025
9726b67
feat(HomepageStarter): update logo handling to support dynamic light …
alwaysmavs Nov 10, 2025
5009ba9
Remove unused SVG assets including logo, macOS icons, and tech backgr…
alwaysmavs Nov 10, 2025
258281b
feat: add ESLint configuration and linting scripts
alwaysmavs Nov 10, 2025
6b3b53c
refactor: remove iconPos prop from LinkBtn usage across multiple comp…
alwaysmavs Nov 10, 2025
64be166
feat: Update Chinese localization and enhance homepage components
alwaysmavs Nov 10, 2025
2a5a542
feat: add PORT configuration for local development in settings
alwaysmavs Nov 10, 2025
32518d2
fix: improve cursor visibility handling in CyclicTypewriterText and r…
alwaysmavs Nov 10, 2025
dc21452
refactor: improve type handling in various components and optimize st…
alwaysmavs Nov 10, 2025
b963bc2
Refactor image assets from PNG/WebP to SVG format across multiple com…
alwaysmavs Nov 10, 2025
8bab823
fix: reduce margin for navbar links to improve layout consistency
alwaysmavs Nov 10, 2025
61bd2a7
fix: standardize quotes for onUntruncatedBlogPosts in docusaurus.conf…
alwaysmavs Nov 11, 2025
c9a7a1d
refactor: remove unused signin handler and clean up Navbar component …
alwaysmavs Nov 11, 2025
0503c79
feat: add login button to Navbar and adjust styles for improved usabi…
alwaysmavs Nov 11, 2025
369936a
feat: update Navbar to include community and download links with impr…
alwaysmavs Nov 11, 2025
3609c3c
feat: update navigation links in docusaurus.config.js to include Cont…
alwaysmavs Nov 11, 2025
3016dfc
fix: update community link in Navbar to point to the correct URL
alwaysmavs Nov 11, 2025
8e50173
feat: enhance login button styles for light and dark themes with impr…
alwaysmavs Nov 11, 2025
27157a3
feat: update dark theme design tokens for improved contrast and usabi…
alwaysmavs Nov 11, 2025
31e22e7
feat: add new navbar items for Cloud and Headless, and update Contact…
alwaysmavs Nov 11, 2025
17bd1fe
Add OOMOL Headless product page with Docker deployment, package manag…
alwaysmavs Nov 11, 2025
a35f848
Refactor Studio Page: Revamp layout and content structure, introducin…
alwaysmavs Nov 11, 2025
1de79fa
feat: Enhance Cloud and CoreTech sections with new features and produ…
alwaysmavs Nov 11, 2025
047ce15
Add PDF-Craft showcase and Studio case study components
alwaysmavs Nov 11, 2025
28446f2
feat: Update slogans and subtitles for improved clarity and engagemen…
alwaysmavs Nov 12, 2025
60fe3e7
feat: Update homepage content by refining the script and removing out…
alwaysmavs Nov 12, 2025
03b5bd5
feat: Revamp HomepageFirstScreen layout and styles for improved respo…
alwaysmavs Nov 12, 2025
7f9f6b0
feat: Update PDF-Craft content for improved clarity and engagement in…
alwaysmavs Nov 12, 2025
2849a4c
feat: Remove unused HomepageCoreTech component from the homepage layout
alwaysmavs Nov 12, 2025
a9dfdbe
feat: Refactor navigation and community pages; remove unused componen…
alwaysmavs Nov 12, 2025
7f170cc
feat: Add "Community" link to navbar and remove outdated links from H…
alwaysmavs Nov 12, 2025
4541abe
feat: Add login button to navbar and style updates for download button
alwaysmavs Nov 12, 2025
05d924f
feat: Update icon font size in navbar styles for improved visibility
alwaysmavs Nov 12, 2025
886b3bb
feat: Remove unused LinkBtn import from HomepageFirstScreen and simpl…
alwaysmavs Nov 12, 2025
394fbf2
feat: Update styles for improved layout and typography; remove unused…
alwaysmavs Nov 12, 2025
c3141e7
feat: Refactor product comparison data structure to card layout and u…
alwaysmavs Nov 12, 2025
c21d7f9
feat: Update card header background gradient to use active color for …
alwaysmavs Nov 12, 2025
508b3e2
feat: Enhance AuroraText component to support light and dark mode col…
alwaysmavs Nov 12, 2025
15fcc01
feat: Update homepage first screen content and styles for improved me…
alwaysmavs Nov 14, 2025
f9c8a47
feat: Add value propositions and core features sections to homepage f…
alwaysmavs Nov 14, 2025
a9d63d6
feat: Add "Why Choose OOMOL?" section with feature comparisons to enh…
alwaysmavs Nov 15, 2025
d16a3bb
feat: Add "Complete Development Lifecycle" section to enhance user gu…
alwaysmavs Nov 15, 2025
16c0804
fix: Adjust connector position for improved layout alignment
alwaysmavs Nov 15, 2025
afd31d0
feat: Update product comparison subtitle for clarity and consistency …
alwaysmavs Nov 15, 2025
71f6227
feat: Add Chat Agent section to enhance user interaction with feature…
alwaysmavs Nov 15, 2025
8172e20
feat: Update built-in module titles and subtitles for clarity and con…
alwaysmavs Nov 15, 2025
d638080
feat: Update permissions in settings and remove outdated development …
alwaysmavs Nov 15, 2025
ec40674
refactor: Replace AuroraText with h2 for title in HomePageBuiltInLLM …
alwaysmavs Nov 15, 2025
1f4913d
feat: Update Get Started subtitle for improved clarity and user engag…
alwaysmavs Nov 15, 2025
e12e9d0
feat: Add CodeExample component with syntax highlighting for Python, …
alwaysmavs Nov 15, 2025
aea4fd0
feat: Enhance codeExample styles and add global tab styles for improv…
alwaysmavs Nov 15, 2025
f430745
feat: Update UI styles for Homepage Core Features to enhance layout a…
alwaysmavs Nov 15, 2025
64d06bd
feat: Refactor gradient backgrounds and enhance table styles for impr…
alwaysmavs Nov 15, 2025
7cae5b5
chore: update Docusaurus dependencies to version 3.9.2 and refactor S…
alwaysmavs Nov 15, 2025
15dbadc
fix: change heading element to span in AuroraText component for seman…
alwaysmavs Nov 15, 2025
883849d
feat: Add Blog item to navbar and implement privacy policy and terms …
alwaysmavs Nov 16, 2025
7d4d323
feat: Update Chinese localization for improved clarity and consistency
alwaysmavs Nov 16, 2025
7c3a061
feat: Split homepage slogan into two lines for improved readability i…
alwaysmavs Nov 16, 2025
f5422b3
feat: Add additional Bash commands for testing and debugging in settings
alwaysmavs Nov 16, 2025
ea34614
fix: Correct markdown syntax for info block and clarify API-key usage…
alwaysmavs Nov 16, 2025
7c27d2c
feat: Enhance documentation for Executors, including detailed explana…
alwaysmavs Nov 16, 2025
26d9656
refactor: remove unused components and styles from Homepage sections
alwaysmavs Nov 16, 2025
1c4903c
feat: Refactor button components to use new UI button implementation …
alwaysmavs Nov 16, 2025
efbcc8b
refactor: remove LinkBtn component and associated styles for cleanup
alwaysmavs Nov 16, 2025
1a8c0b2
feat: integrate Radix UI components for improved UI interactions
alwaysmavs Nov 16, 2025
a1dd1d0
feat: refactor pricing and product cards to use Card component for im…
alwaysmavs Nov 16, 2025
b0594d7
refactor: streamline permissions in settings and enhance design token…
alwaysmavs Nov 16, 2025
32017b4
feat: enhance permissions in settings, add color mode translations, a…
alwaysmavs Nov 16, 2025
1d45d39
fix: ensure elevated background color is applied consistently with !i…
alwaysmavs Nov 16, 2025
d87c91d
feat: implement reusable table components for improved structure and …
alwaysmavs Nov 16, 2025
7304004
feat: update permissions and enhance Chinese translations for lifecyc…
alwaysmavs Nov 16, 2025
4ceac8e
feat: update permissions in settings, add new HTML element types to E…
alwaysmavs Nov 16, 2025
c2d09db
refactor: remove HomepageWhyOomol component and related styles, updat…
alwaysmavs Nov 16, 2025
c374da1
feat: add HomepageWhyOomol component with feature comparison and rela…
alwaysmavs Nov 16, 2025
dc88a4c
feat: add "Contact Us" label to footer and update translations in i18…
alwaysmavs Nov 16, 2025
266ddc7
feat: update footer label to "Contact Us" and enhance translations in…
alwaysmavs Nov 17, 2025
f4235c0
refactor: remove unused QA section and related components from pricin…
alwaysmavs Nov 17, 2025
76007d4
refactor: remove className properties from navbar items in docusaurus…
alwaysmavs Nov 17, 2025
50d3ec3
refactor: remove HomepageGuide component from the homepage
alwaysmavs Nov 17, 2025
a417864
feat: add code examples for Python, JavaScript, and curl in Built-in …
alwaysmavs Nov 17, 2025
35af1f7
feat: update internationalization strings for developer-focused messa…
alwaysmavs Nov 24, 2025
04c660e
Refactor code structure for improved readability and maintainability
alwaysmavs Nov 24, 2025
27c6bec
refactor: remove HomepageValueProps component from the homepage
alwaysmavs Nov 24, 2025
6c65b41
refactor: update import statement to use syntax for design tokens
alwaysmavs Nov 25, 2025
7366be4
feat: enhance homepage with updated PDF-Craft messaging, improved lay…
alwaysmavs Nov 28, 2025
2074586
feat: add PixelBlast component for interactive background effects
alwaysmavs Nov 28, 2025
c878552
refactor: remove PixelBlast component and associated styles
alwaysmavs Nov 28, 2025
ede2bec
feat: add GridBackground component and integrate it into HomepageFirs…
alwaysmavs Nov 29, 2025
49633ed
refactor: remove unused components and styles from Homepage and UI el…
alwaysmavs Nov 29, 2025
d297c7e
refactor: remove HomepageFeatures component and associated styles
alwaysmavs Nov 29, 2025
6aaec22
refactor: remove HomepageCoreFeatures component and associated styles
alwaysmavs Nov 29, 2025
b650cd4
feat: add HomepageCoreFeatures component with styles and integrate in…
alwaysmavs Nov 29, 2025
307900b
refactor: replace hardcoded logo paths with useBaseUrl for dynamic UR…
alwaysmavs Dec 1, 2025
8f94e35
refactor: update slogans and descriptions for HomepageFirstScreen in …
alwaysmavs Dec 1, 2025
2ea4e57
refactor: improve clarity of script message in HomepageFirstScreen
alwaysmavs Dec 1, 2025
e724bed
feat: add text highlighting functionality and styles to HomepageFirst…
alwaysmavs Dec 1, 2025
7afd235
refactor: update text and styles for improved clarity and consistency…
alwaysmavs Dec 2, 2025
04cc7b9
feat: add subtitle for Core Features section with responsive styles
alwaysmavs Dec 2, 2025
257d302
refactor: adjust card width and aspect ratio for improved responsiveness
alwaysmavs Dec 2, 2025
073d76a
refactor: enhance slogan styles for improved readability and responsi…
alwaysmavs Dec 2, 2025
7929d34
refactor: update feature descriptions for improved formatting and rea…
alwaysmavs Dec 2, 2025
41e1983
refactor: update lifecycle steps and styles for improved clarity and …
alwaysmavs Dec 2, 2025
67a78a1
refactor: update step titles and descriptions for improved readabilit…
alwaysmavs Dec 2, 2025
9fa75f4
refactor: update lifecycle step subtitles and descriptions for improv…
alwaysmavs Dec 2, 2025
9bfa0f3
refactor: adjust container styles for improved layout consistency
alwaysmavs Dec 2, 2025
71458f2
refactor: update product comparison messages for improved clarity and…
alwaysmavs Dec 2, 2025
996a24d
refactor: update secondary and tertiary card styles for improved colo…
alwaysmavs Dec 2, 2025
e8635ab
refactor: update PDF-Craft descriptions and features for improved cla…
alwaysmavs Dec 2, 2025
37f50ac
refactor: update Get Started prompt subtitle for improved clarity and…
alwaysmavs Dec 2, 2025
a5c06b5
refactor: update container feature media type to 'empty' and adjust r…
alwaysmavs Dec 2, 2025
2966135
refactor: enhance privacy policy and terms of service documents; upda…
alwaysmavs Dec 2, 2025
d139a53
refactor: extract FeatureItem component for improved readability and …
alwaysmavs Dec 2, 2025
cb05eea
refactor: enhance FeatureItem component with lazy loading and improve…
alwaysmavs Dec 2, 2025
b830e5f
refactor: optimize GridBackground component and styles for improved r…
alwaysmavs Dec 2, 2025
d50e626
refactor: enhance HomepageLifecycle component with progress tracking …
alwaysmavs Dec 2, 2025
53dbca7
Refactor code structure for improved readability and maintainability
alwaysmavs Dec 2, 2025
c7f6895
Update Privacy Policy and Terms of Service for Oomol
alwaysmavs Dec 3, 2025
0409466
refactor: enhance HomePageBuiltInLLM component with dark mode support…
alwaysmavs Dec 3, 2025
06cfc12
Remove unused SVG and image assets from the home page, including icon…
alwaysmavs Dec 3, 2025
ea2ae97
Refactor code structure for improved readability and maintainability
alwaysmavs Dec 3, 2025
0f0d7de
Refactor code structure for improved readability and maintainability
alwaysmavs Dec 3, 2025
89077c6
style: enhance media styling with border, background, and shadow effects
alwaysmavs Dec 3, 2025
98a3813
style: update product screenshot styles with new background, border, …
alwaysmavs Dec 3, 2025
b3b1c65
style: toggle visibility of HomepageLifecycle component in the main l…
alwaysmavs Dec 3, 2025
f65c4c8
style: comment out the Product dropdown in the navbar configuration
alwaysmavs Dec 3, 2025
fe145c0
style: update Community component to use useBaseUrl for image paths
alwaysmavs Dec 3, 2025
46f94e0
style: update contact-us page to use Card components and enhance styl…
alwaysmavs Dec 3, 2025
d46efcd
style: add download options for MacOS and Windows in the Downloads pa…
alwaysmavs Dec 3, 2025
6497efb
style: update download title from "下载 OOMOL" to "下载悟墨" for improved b…
alwaysmavs Dec 3, 2025
ac8a8c7
style: update pricing titles and subtitles for clarity and improved m…
alwaysmavs Dec 3, 2025
3a73b14
style: add subscription and pay-as-you-go pricing sections with corre…
alwaysmavs Dec 3, 2025
1bf0566
style: refactor pricing table layout and styles for improved responsi…
alwaysmavs Dec 3, 2025
fe34b15
feat: add @radix-ui/themes dependency and improve pricing page transl…
alwaysmavs Dec 3, 2025
d446e42
style: add download options for MacOS Apple Silicon, MacOS Intel, and…
alwaysmavs Dec 4, 2025
191bc06
feat: add pay-as-you-go pricing section with task execution, LLM, and…
alwaysmavs Dec 4, 2025
f6edb5a
feat: add support page with GitHub, Discord, and email support options
alwaysmavs Dec 4, 2025
e9f1780
feat: update pricing descriptions and features for free, standard, an…
alwaysmavs Dec 4, 2025
918b4c0
feat(Navbar): add signin button
Cheerego7 Dec 5, 2025
794f925
feat(Navbar): hide pricing link in the footer
alwaysmavs Dec 5, 2025
567bd2c
feat: remove settings.local.json file and associated permissions
alwaysmavs Dec 5, 2025
671eecf
feat: update .gitignore, ESLint config, and various components for im…
alwaysmavs Dec 5, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ src/styles/uno.css
.env.test.local
.env.production.local

# Claude local settings (machine-specific)
.claude/settings.local.json

npm-debug.log*
yarn-debug.log*
yarn-error.log*
3 changes: 0 additions & 3 deletions babel.config.js

This file was deleted.

3 changes: 2 additions & 1 deletion blog/2025-07-05-Export-Workflow-as-Image/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -305,8 +305,9 @@ After running, you can find the image:

Since the image runs outside OOMOL Studio, we cannot identify the user running the container. The current Workflow uses AI for translation, and OOMOL will convert the translation cost into credits. Using an API-key allows the credits to be deducted from the corresponding user's account, enabling the Workflow to run normally.

::info
:::info
If the Workflow does not use built-in services like AI, or uses your own AI service, you still need to pass in the API-key when starting the container, but no credits will be deducted.
:::

You can generate an API-key in the [OOMOL Console](https://console.oomol.com/panel/api-key).

Expand Down
82 changes: 75 additions & 7 deletions docs/advanced-guide/universal-block-settings.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -177,9 +177,11 @@ Universal Block configuration includes executor and Handle configuration.

### Executor

The executor is used to specify the entry file and invocation method when the current Block runs.
The executor is the runtime engine that loads and executes Block code. It acts as the bridge between OOMOL's workflow orchestration system and the actual code execution environment.

Each code language environment has an executor for running code.
Each code language environment has a corresponding executor implementation. When configuring a Block, you specify which executor to use and how it should invoke your code.

For a comprehensive understanding of executors, see [Executor Concepts](/docs/concepts/executor).

<Image
sources={{
Expand All @@ -197,24 +199,90 @@ Each code language environment has an executor for running code.

Currently, executors are implemented internally by the oomol team and support Python and Node.js runtime environments, so there are two corresponding options.

**Python Executor:**
- Executes Python code in a Python runtime environment
- Default entry function name: `main`
- Supports standard Python libraries and packages installed via Poetry
- Can pass complex Python objects (DataFrame, pandas instances, etc.) using [Variable type Handles](#variable)

**Node.js Executor:**
- Executes JavaScript/TypeScript code in a Node.js runtime environment
- Default entry function name: `default export function`
- Supports npm packages with full TypeScript support
- Can pass complex JavaScript objects using [Variable type Handles](#variable)

#### Entry

Select the code entry file. The default file is generated when users create scriptlet Blocks. If there are no special requirements, no changes are needed. Users can also specify any file, but must ensure implementation according to the code template, otherwise it won't run properly.

Refer to [Node.js template](/docs/workflow-engine/nodejs-sdk-api#scriptlet-template) and [Python template](/docs/workflow-engine/python-sdk-api#scriptlet-template)
**Important considerations:**

- The entry file must implement the required function signature with two parameters:
1. Input parameters (dictionary/object containing Handle values)
2. Context object (providing runtime utilities)
- The function must return output values as a dictionary/object
- For async operations in Node.js, return a Promise

Refer to [Node.js template](/docs/workflow-engine/nodejs-sdk-api#scriptlet-template) and [Python template](/docs/workflow-engine/python-sdk-api#scriptlet-template) for implementation details.

#### Function

Specify the code entry method name. Default is the main method of the entry file (Python code) or default export function (Node.js code). You can specify custom methods if needed, but must include method parameters from the template code.

**Custom function example:**

For Python:
```python
def custom_function_name(params: dict, context: Context):
# Your implementation
return {"output": result}
```

For Node.js:
```typescript
export async function customFunctionName(params, context) {
// Your implementation
return { output: result };
}
```

#### Spawn

When oomol studio runs workflows, it performs automatic detection. If upstream and downstream Blocks are implemented in the same code language (for shared Blocks, they must also belong to the same package), the internal scheduler will place both Block codes in the same process for invocation. The benefits are:
The Spawn setting controls whether a Block runs in an independent process or shares a process with adjacent Blocks.

1. Resource saving
2. Allows upstream and downstream to directly pass code variables, eliminating serialization and deserialization steps for output Handle values, simplifying code.
**Automatic Optimization:**

When oomol studio runs workflows, it performs automatic detection. If upstream and downstream Blocks meet the following conditions, the internal scheduler will place both Block codes in the same process for invocation:

1. Implemented in the same code language (both Python or both Node.js)
2. For shared Blocks, they must also belong to the same package

**Benefits of same-process execution:**

1. **Resource efficiency**: Reduces memory overhead and eliminates process startup time
2. **Direct variable passing**: Upstream and downstream Blocks can pass code variables directly using [Variable type Handles](#variable), eliminating serialization and deserialization steps
3. **Performance improvement**: Eliminates inter-process communication overhead

**When to enable Spawn (independent process):**

You may want to manually enable independent process execution in these scenarios:

- **Isolation**: The Block contains potentially unstable code that might crash
- **Memory management**: The Block performs memory-intensive operations that should be isolated
- **Resource limits**: You need strict resource limits for this specific Block
- **Debugging**: You want to debug this Block in isolation from others
- **Concurrency**: The Block uses threading or async operations that might interfere with other Blocks

**Performance implications:**

- **Same process**: Fastest execution, can use Variable Handles, shared memory
- **Independent process**: Slight performance overhead for process creation and inter-process communication, but better isolation and stability

:::tip
In most cases, you can rely on OOMOL's automatic optimization. Only enable Spawn if you have specific requirements for isolation or resource management.
:::

Considering users may have special situations, we also allow users to choose whether to run Blocks in independent processes.
For more details on how executors manage processes and data transfer, see [Executor Concepts - Process Management](/docs/concepts/executor#process-management).

### Handle Configuration

Expand Down
166 changes: 166 additions & 0 deletions docs/concepts/executor.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,166 @@
---
sidebar_position: 4
---

import Image from "@theme/ThemedImage";
import useBaseUrl from "@docusaurus/useBaseUrl";

# Executor

Executor is the runtime engine that executes Block code within OOMOL.

## What is an Executor

An Executor is a runtime component responsible for loading and executing Block code. It acts as the bridge between OOMOL's workflow orchestration system (OOCANA) and the actual code execution environment.

Each code language environment has a corresponding Executor implementation. When a [Node](/docs/concepts/node) in a [Flow](/docs/concepts/flow) is triggered, the Executor loads the specified entry file and invokes the defined function to execute the Block's logic.

## Position in OOMOL Architecture

In the OOMOL system architecture, Executor plays a crucial role in connecting multiple components:

```
OOMOL Studio (UI Layer)
OOCANA (Workflow Engine)
Executor (Runtime Layer)
OVM (Container Environment)
```

- **OOMOL Studio** provides the visual interface for users to design workflows
- **OOCANA** orchestrates the execution sequence and manages data flow between Blocks
- **Executor** loads and executes the actual code for each Block
- **OVM** provides the isolated containerized environment where code runs

## Executor Types

OOMOL currently supports two types of Executors, each designed for a specific programming language:

### Python Executor

- Executes Python code
- Default entry function: `main`
- Supports standard Python libraries and packages installed via Poetry
- Can pass complex Python objects (like DataFrame, pandas instances) between Blocks using [Variable type Handles](/docs/advanced-guide/universal-block-settings#variable)

### Node.js Executor

- Executes JavaScript/TypeScript code
- Default entry function: `default export function`
- Supports npm packages and TypeScript with full type checking
- Can pass complex JavaScript objects between Blocks using [Variable type Handles](/docs/advanced-guide/universal-block-settings#variable)

## Relationship with Other Concepts

### Executor and Block

Each [Block](/docs/concepts/block) is configured with an Executor that specifies:
- Which language runtime to use (Python or Node.js)
- The entry file containing the code
- The function name to invoke
- Whether to run in an independent process

The Executor configuration is part of the Block's metadata and can be modified in the [Block Configuration](/docs/advanced-guide/universal-block-settings#executor) panel.

### Executor and OOCANA

OOCANA (the workflow engine) coordinates with Executors to manage workflow execution:

1. OOCANA analyzes the Flow to determine execution order based on data dependencies
2. When a Block is ready to execute, OOCANA prepares the input data
3. OOCANA invokes the appropriate Executor with the Block's code and input data
4. The Executor runs the code and returns output data to OOCANA
5. OOCANA passes the output to downstream Blocks or caches it for future use

## Process Management

One of the Executor's key features is intelligent process management, which optimizes resource usage and execution performance.

### Same-Process Execution

When OOMOL Studio runs workflows, it automatically detects opportunities for optimization. If consecutive Blocks meet the following conditions, they will be executed in the same process:

- Implemented in the same programming language
- For shared Blocks, they must belong to the same package

**Benefits of same-process execution:**

1. **Resource efficiency**: Reduces memory overhead and startup time
2. **Direct variable passing**: Upstream and downstream Blocks can pass code variables directly without serialization/deserialization
3. **Performance improvement**: Eliminates the overhead of inter-process communication

### Independent Process Execution

Users can manually configure a Block to run in an independent process via the [Spawn configuration](/docs/advanced-guide/universal-block-settings#spawn). This is useful in scenarios such as:

- Isolating potentially unstable code
- Managing memory-intensive operations
- Enforcing strict resource limits
- Debugging specific Blocks in isolation

## Data Transfer Between Executors

Data transfer between Executors depends on whether they share the same process and language environment:

### JSON Serialization (Cross-Language or Cross-Process)

When Blocks run in different language environments or independent processes, data is transferred via JSON serialization:

```
Block A (Python) → JSON → Block B (Node.js)
Block A (same language, independent process) → JSON → Block B
```

**Characteristics:**
- Universal compatibility across all languages
- All Handle types except Variable can be serialized
- Slight performance overhead for serialization/deserialization
- Data can be cached for subsequent runs

### Direct Variable Passing (Same Language, Same Process)

When Blocks share the same language and process, they can use [Variable type Handles](/docs/advanced-guide/universal-block-settings#variable) to pass data directly:

```
Block A (Python) → Variable Reference → Block B (Python)
```

**Characteristics:**
- Maximum performance (no serialization overhead)
- Can pass complex objects that cannot be serialized (e.g., file handles, database connections)
- Variables follow pass-by-reference semantics (modifications affect all Blocks)
- Cannot be cached (upstream Block will always re-execute)
- Reduces Block portability (limited to same-language workflows)

:::info
Variable type Handles cannot be cached because they reference objects in the code execution environment that only exist during runtime. This means if a downstream Block depends on a Variable Handle, it will always trigger upstream Block execution, regardless of cache settings.
:::

## Executor Lifecycle

Understanding the Executor lifecycle helps in debugging and optimizing workflow performance:

1. **Initialization**: When a Block is first triggered, the Executor initializes the runtime environment
2. **Code Loading**: The Executor loads the entry file specified in the Block configuration
3. **Function Invocation**: The Executor calls the specified function with input parameters and the Context object
4. **Execution**: The Block code runs, potentially accessing the file system, network, or other resources
5. **Output Collection**: The Executor collects output values from the Block function
6. **Cleanup**: After execution completes (or fails), the Executor performs cleanup as needed
7. **Process Reuse or Termination**: Depending on configuration, the process may be reused for subsequent Blocks or terminated

## Configuration and Best Practices

For detailed information on configuring Executors, see:
- [Universal Block Settings - Executor](/docs/advanced-guide/universal-block-settings#executor)
- [Architecture Principles](/docs/workflow-engine/principle)

**Best Practices:**

1. **Use same-language Blocks together** when possible to benefit from same-process optimization
2. **Use Variable type Handles sparingly** - they improve performance but reduce Block reusability
3. **Enable independent process execution** for resource-intensive or potentially unstable code
4. **Follow the code templates** provided by OOMOL to ensure proper Executor integration:
- [Node.js Template](/docs/workflow-engine/nodejs-sdk-api#scriptlet-template)
- [Python Template](/docs/workflow-engine/python-sdk-api#scriptlet-template)
2 changes: 1 addition & 1 deletion docs/faq.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -145,4 +145,4 @@ Currently, OOMOL Studio's logs are stored in the following locations:

## Online Help

If you encounter issues while using OOMOL Studio, or have any suggestions or feedback, please feel free to contact us through the [community](/community).
If you encounter issues while using OOMOL Studio, or have any suggestions or feedback, please feel free to contact us through the [contact page](/contact-us).
33 changes: 32 additions & 1 deletion docs/workflow-engine/principle.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,38 @@ The `flow` file defines the triggering sequence and data transfer relationships

The execution sequence of `blocks` is determined by connections defined in the `flow`, following a data-flow driven model — when required data is ready, the corresponding `block` is automatically triggered for execution. This differs from event-driven step triggering in GitHub Actions (where the next step is triggered after the previous one completes), which is primarily used in CI/CD scenarios like compilation and packaging.

Currently, `blocks` support `Nodejs` and `Python` runtime environments. Blocks of the same language run in the same environment. Data between different language environments is transferred via JSON, while blocks in the same language environment can transfer data through JSON or directly via variables. Note that variables follow pass-by-reference principles, so modifying a variable value in one `block` affects the same variable in other `blocks`.
### Runtime Environments and Executors

Currently, `blocks` support `Nodejs` and `Python` runtime environments. Each runtime environment has a corresponding [Executor](/docs/concepts/executor) that loads and executes the block code.

**Key execution characteristics:**

- **Same-language blocks** run in the same runtime environment by default
- **Same-process optimization**: When consecutive blocks use the same language and belong to the same package, OOCANA places them in the same process to reduce overhead
- **Independent processes**: Blocks can be configured to run in independent processes for isolation or debugging purposes

For detailed information about executors and process management, see [Executor Concepts](/docs/concepts/executor).

### Data Transfer Between Blocks

Data transfer between different language environments is transferred via JSON, while blocks in the same language environment can transfer data through JSON or directly via variables.

**JSON Serialization (Cross-Language or Cross-Process):**
- Universal compatibility across all supported languages
- Used when blocks run in different languages or independent processes
- Slight performance overhead for serialization/deserialization
- All Handle types except Variable can be cached

**Direct Variable Passing (Same Language, Same Process):**
- Maximum performance with zero serialization overhead
- Used via [Variable type Handles](/docs/advanced-guide/universal-block-settings#variable)
- Can pass complex objects that cannot be serialized
- Variables follow pass-by-reference semantics - modifying a variable value in one `block` affects the same variable in other `blocks`
- Cannot be cached (upstream blocks will always re-execute)

:::info
When using Variable type Handles for maximum performance, be aware that the blocks become tightly coupled and can only work with blocks in the same language environment. This reduces block portability but provides significant performance benefits for complex object passing.
:::

## Block Data Transfer Specifications

Expand Down
Loading