fast-crewai 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (63) hide show
  1. fast_crewai-0.1.0/.github/workflows/ci.yml +102 -0
  2. fast_crewai-0.1.0/.github/workflows/compatibility-tests.yml +145 -0
  3. fast_crewai-0.1.0/.github/workflows/publish.yml +169 -0
  4. fast_crewai-0.1.0/.gitignore +120 -0
  5. fast_crewai-0.1.0/BENCHMARK.md +92 -0
  6. fast_crewai-0.1.0/CLAUDE.md +332 -0
  7. fast_crewai-0.1.0/COMPATIBILITY.md +62 -0
  8. fast_crewai-0.1.0/Cargo.lock +530 -0
  9. fast_crewai-0.1.0/Cargo.toml +25 -0
  10. fast_crewai-0.1.0/LICENSE +21 -0
  11. fast_crewai-0.1.0/MANIFEST.in +8 -0
  12. fast_crewai-0.1.0/Makefile +118 -0
  13. fast_crewai-0.1.0/PKG-INFO +299 -0
  14. fast_crewai-0.1.0/README.md +252 -0
  15. fast_crewai-0.1.0/benchmark_test/benchmark_runner.py +68 -0
  16. fast_crewai-0.1.0/conftest.py +6 -0
  17. fast_crewai-0.1.0/crewai_comparison_test/accelerated_avg_time.txt +1 -0
  18. fast_crewai-0.1.0/crewai_comparison_test/baseline_avg_time.txt +1 -0
  19. fast_crewai-0.1.0/crewai_comparison_test/comparison_results.json +10 -0
  20. fast_crewai-0.1.0/crewai_comparison_test/crewai_test_workflow.py +235 -0
  21. fast_crewai-0.1.0/docs/API_REFERENCE.md +537 -0
  22. fast_crewai-0.1.0/docs/ARCHITECTURE.md +559 -0
  23. fast_crewai-0.1.0/docs/CONFIGURATION.md +210 -0
  24. fast_crewai-0.1.0/docs/PERFORMANCE.md +516 -0
  25. fast_crewai-0.1.0/docs/README.md +17 -0
  26. fast_crewai-0.1.0/docs/TROUBLESHOOTING.md +386 -0
  27. fast_crewai-0.1.0/fast_crewai/__init__.py +96 -0
  28. fast_crewai-0.1.0/fast_crewai/__main__.py +121 -0
  29. fast_crewai-0.1.0/fast_crewai/_constants.py +38 -0
  30. fast_crewai-0.1.0/fast_crewai/benchmark.py +1284 -0
  31. fast_crewai-0.1.0/fast_crewai/bootstrap.py +52 -0
  32. fast_crewai-0.1.0/fast_crewai/database.py +479 -0
  33. fast_crewai-0.1.0/fast_crewai/integration.py +332 -0
  34. fast_crewai-0.1.0/fast_crewai/memory.py +222 -0
  35. fast_crewai-0.1.0/fast_crewai/serialization.py +301 -0
  36. fast_crewai-0.1.0/fast_crewai/shim.py +359 -0
  37. fast_crewai-0.1.0/fast_crewai/tasks.py +481 -0
  38. fast_crewai-0.1.0/fast_crewai/tools.py +464 -0
  39. fast_crewai-0.1.0/fast_crewai/utils.py +225 -0
  40. fast_crewai-0.1.0/pyproject.toml +108 -0
  41. fast_crewai-0.1.0/pytest.ini +43 -0
  42. fast_crewai-0.1.0/run_tests.py +117 -0
  43. fast_crewai-0.1.0/scripts/build_and_test.sh +26 -0
  44. fast_crewai-0.1.0/scripts/run_tests.sh +117 -0
  45. fast_crewai-0.1.0/scripts/test_benchmarking.py +448 -0
  46. fast_crewai-0.1.0/scripts/test_benchmarking.sh +317 -0
  47. fast_crewai-0.1.0/scripts/test_crewai_comparison.py +679 -0
  48. fast_crewai-0.1.0/scripts/test_crewai_comparison.sh +526 -0
  49. fast_crewai-0.1.0/scripts/test_crewai_compatibility.py +658 -0
  50. fast_crewai-0.1.0/scripts/test_crewai_compatibility.sh +304 -0
  51. fast_crewai-0.1.0/src/lib.rs +1229 -0
  52. fast_crewai-0.1.0/tests/__init__.py +7 -0
  53. fast_crewai-0.1.0/tests/conftest.py +202 -0
  54. fast_crewai-0.1.0/tests/test_all_patches.py +288 -0
  55. fast_crewai-0.1.0/tests/test_backward_compatibility.py +335 -0
  56. fast_crewai-0.1.0/tests/test_compatibility_report.py +239 -0
  57. fast_crewai-0.1.0/tests/test_comprehensive.py +436 -0
  58. fast_crewai-0.1.0/tests/test_integration.py +251 -0
  59. fast_crewai-0.1.0/tests/test_memory.py +212 -0
  60. fast_crewai-0.1.0/tests/test_package_import.py +149 -0
  61. fast_crewai-0.1.0/tests/test_shim.py +342 -0
  62. fast_crewai-0.1.0/tests/test_tasks.py +220 -0
  63. fast_crewai-0.1.0/tests/test_tools.py +245 -0
@@ -0,0 +1,102 @@
1
+ name: CI
2
+
3
+ on:
4
+ push:
5
+ branches: [ main, develop ]
6
+ pull_request:
7
+ branches: [ main, develop ]
8
+ workflow_dispatch:
9
+
10
+ jobs:
11
+ test:
12
+ name: Test on ${{ matrix.os }} - Python ${{ matrix.python-version }}
13
+ runs-on: ${{ matrix.os }}
14
+
15
+ strategy:
16
+ fail-fast: false
17
+ matrix:
18
+ os: [ubuntu-latest, macos-latest, windows-latest]
19
+ python-version: ['3.9', '3.10', '3.11', '3.12', '3.13']
20
+
21
+ steps:
22
+ - uses: actions/checkout@v4
23
+
24
+ - name: Install uv
25
+ uses: astral-sh/setup-uv@v4
26
+ with:
27
+ enable-cache: true
28
+ cache-dependency-glob: "pyproject.toml"
29
+
30
+ - name: Set up Python ${{ matrix.python-version }}
31
+ run: uv python install ${{ matrix.python-version }}
32
+
33
+ - name: Set up Rust
34
+ uses: actions-rust-lang/setup-rust-toolchain@v1
35
+ with:
36
+ toolchain: stable
37
+
38
+ - name: Cache Rust build
39
+ uses: actions/cache@v4
40
+ with:
41
+ path: |
42
+ ~/.cargo/registry
43
+ ~/.cargo/git
44
+ target
45
+ key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
46
+ restore-keys: |
47
+ ${{ runner.os }}-cargo-
48
+
49
+ - name: Install dependencies
50
+ run: uv sync --dev
51
+
52
+ - name: Build Rust extension
53
+ run: uv run maturin develop
54
+ continue-on-error: true
55
+
56
+ - name: Run fast tests
57
+ run: uv run pytest -m "not slow and not integration and not performance" -v --tb=short
58
+
59
+ - name: Run all tests with coverage
60
+ if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.11'
61
+ run: uv run pytest --cov=fast_crewai --cov-report=xml --cov-report=html --cov-report=term -v
62
+
63
+ - name: Upload coverage to Codecov
64
+ if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.11'
65
+ uses: codecov/codecov-action@v4
66
+ with:
67
+ file: ./coverage.xml
68
+ flags: unittests
69
+ name: codecov-umbrella
70
+ fail_ci_if_error: false
71
+
72
+ lint:
73
+ name: Lint and Format Check
74
+ runs-on: ubuntu-latest
75
+
76
+ steps:
77
+ - uses: actions/checkout@v4
78
+
79
+ - name: Install uv
80
+ uses: astral-sh/setup-uv@v4
81
+ with:
82
+ enable-cache: true
83
+ cache-dependency-glob: "pyproject.toml"
84
+
85
+ - name: Set up Python
86
+ run: uv python install 3.11
87
+
88
+ - name: Install dependencies
89
+ run: uv sync --dev
90
+
91
+ - name: Check formatting with black
92
+ run: uv run black --check fast_crewai tests
93
+
94
+ - name: Check import sorting with isort
95
+ run: uv run isort --check-only fast_crewai tests
96
+
97
+ - name: Lint with flake8
98
+ run: uv run flake8 fast_crewai tests --max-line-length=100 --extend-ignore=E203,W503
99
+
100
+ - name: Type check with mypy
101
+ run: uv run mypy fast_crewai --ignore-missing-imports
102
+ continue-on-error: true
@@ -0,0 +1,145 @@
1
+ name: CrewAI Compatibility Tests
2
+
3
+ permissions:
4
+ contents: write
5
+
6
+ on:
7
+ # Run on pushes to main
8
+ push:
9
+ branches: [ main ]
10
+
11
+ # Allow manual trigger
12
+ workflow_dispatch:
13
+
14
+ # Run weekly to catch CrewAI changes
15
+ schedule:
16
+ - cron: '0 0 * * 0' # Every Sunday at midnight
17
+
18
+ jobs:
19
+ compatibility-test:
20
+ name: Test with CrewAI (Python ${{ matrix.python-version }})
21
+ runs-on: ubuntu-latest
22
+
23
+ strategy:
24
+ fail-fast: false
25
+ matrix:
26
+ python-version: ['3.10', '3.11', '3.12', '3.13']
27
+
28
+ steps:
29
+ - name: Checkout Fast-CrewAI
30
+ uses: actions/checkout@v4
31
+
32
+ - name: Install uv
33
+ uses: astral-sh/setup-uv@v4
34
+ with:
35
+ enable-cache: true
36
+ cache-dependency-glob: "pyproject.toml"
37
+
38
+ - name: Set up Python ${{ matrix.python-version }}
39
+ run: uv python install ${{ matrix.python-version }}
40
+
41
+ - name: Set up Rust
42
+ uses: actions-rust-lang/setup-rust-toolchain@v1
43
+ with:
44
+ toolchain: stable
45
+
46
+ - name: Cache Rust build
47
+ uses: actions/cache@v4
48
+ with:
49
+ path: |
50
+ ~/.cargo/registry
51
+ ~/.cargo/git
52
+ target
53
+ key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
54
+ restore-keys: |
55
+ ${{ runner.os }}-cargo-
56
+
57
+ - name: Install system dependencies
58
+ run: |
59
+ sudo apt-get update
60
+ sudo apt-get install -y build-essential
61
+
62
+ - name: Install dependencies
63
+ run: uv sync --dev
64
+
65
+ - name: Run Compatibility Tests
66
+ run: |
67
+ # Run tests that don't require OPENAI_API_KEY
68
+ uv run python scripts/test_crewai_compatibility.py \
69
+ --crewai-branch main \
70
+ --keep-env \
71
+ --verbose \
72
+ --no-api-key \
73
+ --report-output COMPATIBILITY.md
74
+
75
+ - name: Upload compatibility report
76
+ uses: actions/upload-artifact@v4
77
+ with:
78
+ name: compatibility-report-py${{ matrix.python-version }}
79
+ path: COMPATIBILITY.md
80
+ retention-days: 30
81
+
82
+ - name: Upload test results
83
+ if: always()
84
+ uses: actions/upload-artifact@v4
85
+ with:
86
+ name: test-results-py${{ matrix.python-version }}
87
+ path: |
88
+ test_compatibility/pytest_results.json
89
+ COMPATIBILITY.md
90
+ retention-days: 30
91
+
92
+ update-compatibility-report:
93
+ name: Update COMPATIBILITY.md
94
+ needs: compatibility-test
95
+ runs-on: ubuntu-latest
96
+ # Only run on push to main or scheduled runs, not on PRs
97
+ if: github.event_name == 'push' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
98
+
99
+ steps:
100
+ - name: Checkout Fast-CrewAI
101
+ uses: actions/checkout@v4
102
+ with:
103
+ token: ${{ secrets.GITHUB_TOKEN }}
104
+
105
+ - name: Download compatibility report
106
+ uses: actions/download-artifact@v4
107
+ with:
108
+ # Use Python 3.12 report as the canonical one
109
+ name: compatibility-report-py3.12
110
+ path: .
111
+
112
+ - name: Check for changes
113
+ id: check_changes
114
+ run: |
115
+ if git diff --quiet COMPATIBILITY.md 2>/dev/null; then
116
+ echo "changed=false" >> $GITHUB_OUTPUT
117
+ else
118
+ echo "changed=true" >> $GITHUB_OUTPUT
119
+ fi
120
+
121
+ - name: Commit and push COMPATIBILITY.md
122
+ if: steps.check_changes.outputs.changed == 'true'
123
+ run: |
124
+ git config --local user.email "github-actions[bot]@users.noreply.github.com"
125
+ git config --local user.name "github-actions[bot]"
126
+ git add COMPATIBILITY.md
127
+ git commit -m "Update COMPATIBILITY.md [skip ci]"
128
+ git push
129
+
130
+ compatibility-test-summary:
131
+ name: Compatibility Test Summary
132
+ needs: compatibility-test
133
+ runs-on: ubuntu-latest
134
+ if: always()
135
+
136
+ steps:
137
+ - name: Check test results
138
+ run: |
139
+ if [ "${{ needs.compatibility-test.result }}" == "success" ]; then
140
+ echo "✅ All compatibility tests passed!"
141
+ exit 0
142
+ else
143
+ echo "❌ Some compatibility tests failed"
144
+ exit 1
145
+ fi
@@ -0,0 +1,169 @@
1
+ name: Publish to PyPI
2
+
3
+ on:
4
+ push:
5
+ tags:
6
+ - 'v*'
7
+ workflow_dispatch:
8
+ inputs:
9
+ dry_run:
10
+ description: 'Dry run (build but do not publish)'
11
+ required: false
12
+ default: 'true'
13
+ type: choice
14
+ options:
15
+ - 'true'
16
+ - 'false'
17
+
18
+ permissions:
19
+ contents: read
20
+
21
+ jobs:
22
+ build-linux:
23
+ name: Build Linux wheels
24
+ runs-on: ubuntu-latest
25
+ strategy:
26
+ matrix:
27
+ target: [x86_64, aarch64]
28
+ steps:
29
+ - uses: actions/checkout@v4
30
+
31
+ - name: Build wheels
32
+ uses: PyO3/maturin-action@v1
33
+ with:
34
+ target: ${{ matrix.target }}
35
+ # Explicitly specify Python versions to avoid building for unsupported versions
36
+ # PyO3 0.23.x supports up to Python 3.13 (not 3.14 yet)
37
+ args: --release --out dist -i python3.9 -i python3.10 -i python3.11 -i python3.12 -i python3.13
38
+ sccache: 'true'
39
+ manylinux: auto
40
+
41
+ - name: Upload wheels
42
+ uses: actions/upload-artifact@v4
43
+ with:
44
+ name: wheels-linux-${{ matrix.target }}
45
+ path: dist
46
+
47
+ build-macos:
48
+ name: Build macOS wheels
49
+ runs-on: ${{ matrix.runner }}
50
+ strategy:
51
+ matrix:
52
+ include:
53
+ - runner: macos-15
54
+ target: x86_64
55
+ - runner: macos-15
56
+ target: aarch64
57
+ steps:
58
+ - uses: actions/checkout@v4
59
+
60
+ - name: Build wheels
61
+ uses: PyO3/maturin-action@v1
62
+ with:
63
+ target: ${{ matrix.target }}
64
+ # Explicitly specify Python versions to avoid building for unsupported versions
65
+ # PyO3 0.23.x supports up to Python 3.13 (not 3.14 yet)
66
+ args: --release --out dist -i python3.9 -i python3.10 -i python3.11 -i python3.12 -i python3.13
67
+ sccache: 'true'
68
+
69
+ - name: Upload wheels
70
+ uses: actions/upload-artifact@v4
71
+ with:
72
+ name: wheels-macos-${{ matrix.target }}
73
+ path: dist
74
+
75
+ build-windows:
76
+ name: Build Windows wheels
77
+ runs-on: windows-latest
78
+ strategy:
79
+ matrix:
80
+ target: [x64]
81
+ steps:
82
+ - uses: actions/checkout@v4
83
+
84
+ - name: Build wheels
85
+ uses: PyO3/maturin-action@v1
86
+ with:
87
+ target: ${{ matrix.target }}
88
+ # Explicitly specify Python versions to avoid building for unsupported versions
89
+ # PyO3 0.23.x supports up to Python 3.13 (not 3.14 yet)
90
+ args: --release --out dist -i python3.9 -i python3.10 -i python3.11 -i python3.12 -i python3.13
91
+ sccache: 'true'
92
+
93
+ - name: Upload wheels
94
+ uses: actions/upload-artifact@v4
95
+ with:
96
+ name: wheels-windows-${{ matrix.target }}
97
+ path: dist
98
+
99
+ build-sdist:
100
+ name: Build source distribution
101
+ runs-on: ubuntu-latest
102
+ steps:
103
+ - uses: actions/checkout@v4
104
+
105
+ - name: Build sdist
106
+ uses: PyO3/maturin-action@v1
107
+ with:
108
+ command: sdist
109
+ args: --out dist
110
+
111
+ - name: Upload sdist
112
+ uses: actions/upload-artifact@v4
113
+ with:
114
+ name: wheels-sdist
115
+ path: dist
116
+
117
+ publish:
118
+ name: Publish to PyPI
119
+ needs: [build-linux, build-macos, build-windows, build-sdist]
120
+ runs-on: ubuntu-latest
121
+ if: (github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')) || (github.event_name == 'workflow_dispatch' && github.event.inputs.dry_run == 'false')
122
+ environment:
123
+ name: pypi
124
+ url: https://pypi.org/project/fast-crewai/
125
+ permissions:
126
+ id-token: write
127
+ steps:
128
+ - name: Download all artifacts
129
+ uses: actions/download-artifact@v4
130
+ with:
131
+ path: dist
132
+ pattern: wheels-*
133
+ merge-multiple: true
134
+
135
+ - name: List built wheels
136
+ run: ls -la dist/
137
+
138
+ - name: Publish to PyPI
139
+ uses: PyO3/maturin-action@v1
140
+ with:
141
+ command: upload
142
+ args: --non-interactive --skip-existing dist/*
143
+
144
+ publish-testpypi:
145
+ name: Publish to TestPyPI (dry run)
146
+ needs: [build-linux, build-macos, build-windows, build-sdist]
147
+ runs-on: ubuntu-latest
148
+ if: github.event_name == 'workflow_dispatch' && github.event.inputs.dry_run == 'true'
149
+ environment:
150
+ name: testpypi
151
+ url: https://test.pypi.org/project/fast-crewai/
152
+ permissions:
153
+ id-token: write
154
+ steps:
155
+ - name: Download all artifacts
156
+ uses: actions/download-artifact@v4
157
+ with:
158
+ path: dist
159
+ pattern: wheels-*
160
+ merge-multiple: true
161
+
162
+ - name: List built wheels
163
+ run: ls -la dist/
164
+
165
+ - name: Publish to TestPyPI
166
+ uses: PyO3/maturin-action@v1
167
+ with:
168
+ command: upload
169
+ args: --non-interactive --skip-existing --repository testpypi dist/*
@@ -0,0 +1,120 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+ *.pyc
6
+
7
+ # C extensions
8
+ *.so
9
+ *.dylib
10
+ *.dll
11
+
12
+ # Distribution / packaging
13
+ .Python
14
+ build/
15
+ develop-eggs/
16
+ dist/
17
+ downloads/
18
+ eggs/
19
+ .eggs/
20
+ lib/
21
+ lib64/
22
+ parts/
23
+ sdist/
24
+ var/
25
+ wheels/
26
+ *.egg-info/
27
+ .installed.cfg
28
+ *.egg
29
+ MANIFEST
30
+
31
+ # Rust/Maturin build artifacts
32
+ /target/
33
+ **/*.rs.bk
34
+ *.so
35
+ *.dylib
36
+ *.dll
37
+
38
+ # PyInstaller
39
+ *.manifest
40
+ *.spec
41
+
42
+ # Installer logs
43
+ pip-log.txt
44
+ pip-delete-this-directory.txt
45
+
46
+ # Unit test / coverage reports
47
+ htmlcov/
48
+ .tox/
49
+ .nox/
50
+ .coverage
51
+ .coverage.*
52
+ .cache
53
+ nosetests.xml
54
+ coverage.xml
55
+ *.cover
56
+ *.py,cover
57
+ .hypothesis/
58
+ .pytest_cache/
59
+ test_results/
60
+ *.log
61
+
62
+ # Fast-CrewAI specific test artifacts
63
+ test_compatibility/
64
+ test_results.log
65
+ *.db
66
+ *.db-journal
67
+
68
+ # Jupyter Notebook
69
+ .ipynb_checkpoints
70
+
71
+ # IPython
72
+ profile_default/
73
+ ipython_config.py
74
+
75
+ # Environments
76
+ .env
77
+ .venv
78
+ env/
79
+ venv/
80
+ ENV/
81
+ env.bak/
82
+ venv.bak/
83
+
84
+ # IDEs
85
+ .vscode/
86
+ .idea/
87
+ *.swp
88
+ *.swo
89
+ *~
90
+
91
+ # OS generated files
92
+ .DS_Store
93
+ .DS_Store?
94
+ ._*
95
+ .Spotlight-V100
96
+ .Trashes
97
+ ehthumbs.db
98
+ Thumbs.db
99
+
100
+ # Logs
101
+ *.log
102
+
103
+ # Temporary files
104
+ *.tmp
105
+ *.temp
106
+
107
+ # mypy
108
+ .mypy_cache/
109
+ .dmypy.json
110
+ dmypy.json
111
+
112
+ # Pyre type checker
113
+ .pyre/
114
+
115
+ # Documentation build
116
+ docs/_build/
117
+ /site
118
+
119
+ # uv
120
+ uv.lock
@@ -0,0 +1,92 @@
1
+ # Fast-CrewAI Benchmark Report
2
+
3
+ > Generated: 2025-12-10 00:16:33 UTC
4
+
5
+ ## Summary
6
+
7
+ | Metric | Value |
8
+ |--------|-------|
9
+ | Rust Acceleration | ✅ Available |
10
+ | Iterations | 300 |
11
+ | Average Improvement | 🚀 13.43x |
12
+
13
+ ## Performance Improvements
14
+
15
+ | Component | Improvement |
16
+ |-----------|-------------|
17
+ | Memory Storage | 🚀 1.00x faster |
18
+ | Tool Execution | 🚀 17.34x faster |
19
+ | Serialization | 🚀 34.51x faster |
20
+ | Database | ⚠️ 1.16x slower |
21
+
22
+ ## Memory Usage
23
+
24
+ | Component | Python | Rust | Savings |
25
+ |-----------|--------|------|---------|
26
+ | Memory Storage | 0.1 MB | 0.1 MB | ➡️ Same |
27
+ | Tool Execution | 1.2 MB | 0.0 MB | 🚀 99.2% less |
28
+ | Serialization | 8.0 MB | 3.4 MB | 🚀 57.7% less |
29
+ | Database | 0.1 MB | 0.1 MB | 🚀 30.8% less |
30
+
31
+ ## Environment
32
+
33
+ | Component | Version |
34
+ |-----------|---------|
35
+ | Python | 3.12.3 |
36
+ | Platform | Linux-6.14.0-36-generic-x86_64-with-glibc2.39 |
37
+ | Fast-CrewAI | 0.1.0 |
38
+ | Rust Extension | available |
39
+
40
+ ## Detailed Results
41
+
42
+ ### Memory Storage
43
+
44
+ | Metric | Performance |
45
+ |--------|-------------|
46
+ | Save | Python: 541,201 ops/s | Rust: 541,666 ops/s |
47
+ | Search | Python: 667,584 ops/s | Rust: 674,161 ops/s |
48
+ | Memory | Python: 0.1 MB | Rust: 0.1 MB |
49
+
50
+ ### Tool Execution
51
+
52
+ | Metric | Performance |
53
+ |--------|-------------|
54
+ | Execute | Python: 670 ops/s | Rust: 11,616 ops/s |
55
+ | Memory | Python: 1.2 MB | Rust: 0.0 MB |
56
+
57
+ ### Serialization
58
+
59
+ | Metric | Performance |
60
+ |--------|-------------|
61
+ | Serialize | Python: 2,333 ops/s | Rust: 80,525 ops/s |
62
+ | Deserialize | Python: 3,531 ops/s | Rust: 51,525 ops/s |
63
+ | Memory | Python: 8.0 MB | Rust: 3.4 MB |
64
+
65
+ ### Database Operations
66
+
67
+ | Metric | Performance |
68
+ |--------|-------------|
69
+ | Insert | Python: 484 ops/s | Rust: 416 ops/s |
70
+ | Query | Python: 1,262 ops/s | Rust: 1,586 ops/s |
71
+ | FTS Search | Python: 913 ops/s | Rust: 10,206 ops/s |
72
+ | Memory | Python: 0.1 MB | Rust: 0.1 MB |
73
+
74
+ ## How to Reproduce
75
+
76
+ ```bash
77
+ # Run benchmarks locally
78
+ uv run python scripts/test_benchmarking.py \
79
+ --iterations 300 \
80
+ --report-output BENCHMARK.md
81
+ ```
82
+
83
+ ## Notes
84
+
85
+ - Benchmarks compare Python implementations with Rust-accelerated implementations
86
+ - Higher improvement numbers indicate better Rust performance
87
+ - Results may vary based on hardware and system load
88
+ - The Rust extension must be built for acceleration to be available
89
+
90
+ ---
91
+
92
+ *This report was automatically generated by the Fast-CrewAI benchmark suite.*