Skip to content

Commit 29542ac

Browse files
authored
Sync changes from internal repo (#32)
* Copy repo * Readd .env.example
1 parent 5c3df39 commit 29542ac

File tree

105 files changed

+5185
-2953
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

105 files changed

+5185
-2953
lines changed

.env.example

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ TOGETHER_API_KEY=
66
HYPERBOLIC_API_KEY=
77
CEREBRAS_API_KEY=
88
SAMBANOVA_API_KEY=
9+
DEEPSEEK_API_KEY=
10+
CUSTOM_API_KEY=
911

1012
# Service URLs
1113
DOCIO_URL=http://docio:6979/api/docio

.gitattributes

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
# https://git-scm.com/docs/gitattributes#_text
2020
*.css text
2121
*.html text
22-
*.js text
22+
*.js* text
2323
*.md text
2424
*.py text
2525
*.sh text

.github/workflows/ci-win.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,23 @@ concurrency:
1717
cancel-in-progress: true
1818

1919
jobs:
20+
check_changes:
21+
name: Check for changes
22+
runs-on: ubuntu-latest
23+
outputs:
24+
has-changes: ${{ steps.check.outputs.has-changes }}
25+
steps:
26+
- name: Check
27+
id: check
28+
uses: jiahuei/check-changes-action@v0
29+
with:
30+
watch-dirs: "clients/python/ services/api/ services/docio/ docker/ .github/"
31+
2032
pyinstaller_electron_app:
2133
name: PyInstaller JamAIBase Electron App Compilation
2234
runs-on: windows-11-desktop
35+
needs: check_changes
36+
if: needs.check_changes.outputs.has-changes == 'true' || github.event_name == 'push'
2337
timeout-minutes: 60
2438

2539
steps:
@@ -98,6 +112,8 @@ jobs:
98112
pyinstaller_api:
99113
name: PyInstaller API Service Compilation
100114
runs-on: windows-11-desktop
115+
needs: check_changes
116+
if: needs.check_changes.outputs.has-changes == 'true' || github.event_name == 'push'
101117
timeout-minutes: 60
102118

103119
steps:
@@ -179,6 +195,8 @@ jobs:
179195
pyinstaller_docio:
180196
name: PyInstaller DocIO Service Compilation
181197
runs-on: windows-11-desktop
198+
needs: check_changes
199+
if: needs.check_changes.outputs.has-changes == 'true' || github.event_name == 'push'
182200
timeout-minutes: 60
183201

184202
steps:

.github/workflows/ci.yml

Lines changed: 43 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: CI
1+
name: CI (OSS)
22

33
on:
44
pull_request:
@@ -18,10 +18,38 @@ concurrency:
1818
cancel-in-progress: true
1919

2020
jobs:
21+
check_changes:
22+
name: Check for changes
23+
runs-on: ubuntu-latest
24+
outputs:
25+
has-changes: ${{ steps.check.outputs.has-changes }}
26+
steps:
27+
- name: Check
28+
id: check
29+
uses: jiahuei/check-changes-action@v0
30+
with:
31+
watch-dirs: "clients/python/ services/api/ docker/ .github/"
32+
33+
sdk_tests_noop:
34+
# This job is needed so that status checks can still pass
35+
# This is because strategy matrix is evaluated after if condition
36+
name: SDK unit tests
37+
runs-on: ubuntu-latest
38+
needs: check_changes
39+
if: ${{ !(needs.check_changes.outputs.has-changes == 'true' || github.event_name == 'push') }}
40+
strategy:
41+
matrix:
42+
python-version: ["3.10"]
43+
timeout-minutes: 2
44+
steps:
45+
- name: No-op
46+
run: echo Tests skipped !!!
47+
2148
sdk_tests:
2249
name: SDK unit tests
2350
runs-on: ubuntu-latest-l
24-
# runs-on: namespace-profile-ubuntu-latest-8cpu-16gb-96gb
51+
needs: check_changes
52+
if: needs.check_changes.outputs.has-changes == 'true' || github.event_name == 'push'
2553
strategy:
2654
matrix:
2755
python-version: ["3.10"]
@@ -42,18 +70,23 @@ jobs:
4270
run: |
4371
git --version
4472
73+
- name: Check Docker Version
74+
run: docker version
75+
76+
- name: Check Docker Compose Version
77+
run: docker compose version
78+
4579
- name: Remove cloud-only modules and install Python client
4680
run: |
4781
set -e
4882
bash scripts/remove_cloud_modules.sh
4983
cd clients/python
5084
python -m pip install .[test]
5185
52-
- name: Check Docker Version
53-
run: docker version
54-
55-
- name: Check Docker Compose Version
56-
run: docker compose version
86+
- name: Install ffmpeg
87+
run: |
88+
set -e
89+
sudo apt-get update -qq && sudo apt-get install ffmpeg libavcodec-extra -y
5790
5891
- name: Authenticating to the Container registry
5992
run: echo $JH_PAT | docker login ghcr.io -u [email protected] --password-stdin
@@ -87,13 +120,14 @@ jobs:
87120
TOGETHER_API_KEY: ${{ secrets.TOGETHER_API_KEY }}
88121
COHERE_API_KEY: ${{ secrets.COHERE_API_KEY }}
89122
HYPERBOLIC_API_KEY: ${{ secrets.HYPERBOLIC_API_KEY }}
123+
CUSTOM_API_KEY: ${{ secrets.CUSTOM_API_KEY }}
90124

91125
- name: Launch services (OSS)
92126
id: launch_oss
93127
timeout-minutes: 20
94128
run: |
95129
set -e
96-
docker compose -p jamai -f docker/compose.cpu.yml --profile minio up --quiet-pull -d --wait
130+
docker compose -p jamai -f docker/compose.cpu.yml --profile minio --profile kopi up --quiet-pull -d --wait
97131
env:
98132
COMPOSE_DOCKER_CLI_BUILD: 1
99133
DOCKER_BUILDKIT: 1
@@ -116,7 +150,7 @@ jobs:
116150
--junitxml=junit/test-results-${{ matrix.python-version }}.xml \
117151
--cov-report=xml \
118152
--no-flaky-report \
119-
clients/python/tests/oss
153+
clients/python/tests/oss/
120154
121155
- name: Inspect owl logs if Python SDK tests failed
122156
if: failure() && steps.python_sdk_test_oss.outcome == 'failure'
@@ -170,11 +204,6 @@ jobs:
170204
--no-flaky-report \
171205
clients/python/tests/oss/test_file.py
172206
173-
- name: Inspect owl logs if Python SDK tests failed
174-
if: failure() && steps.python_sdk_test_oss_file.outcome == 'failure'
175-
timeout-minutes: 1
176-
run: docker exec jamai-owl-1 cat /app/api/logs/owl.log
177-
178207
lance_tests:
179208
name: Lance tests
180209
runs-on: ubuntu-latest

.github/workflows/github_bot.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: JambuBot
2+
3+
on:
4+
issues:
5+
types: [opened, edited]
6+
pull_request:
7+
types: [opened, synchronize]
8+
9+
# Cancel in-progress CI jobs if there is a new push
10+
# https://stackoverflow.com/a/72408109
11+
concurrency:
12+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
13+
cancel-in-progress: true
14+
15+
jobs:
16+
github-bot:
17+
runs-on: ubuntu-latest
18+
19+
steps:
20+
- name: Checkout code
21+
uses: actions/checkout@v2
22+
with:
23+
submodules: true # Ensure submodules are checked out
24+
25+
- name: Set up Go
26+
uses: actions/setup-go@v2
27+
with:
28+
go-version: "1.18"
29+
30+
- name: Launching JambuBot
31+
run: |
32+
cd examples/github-bot/github-bot/src
33+
go build -o github_bot cmd/main.go
34+
./github_bot
35+
env:
36+
TRIAGE_BOT_APP_ID: ${{ secrets.TRIAGE_BOT_APP_ID }}
37+
TRIAGE_BOT_INSTALLATION_ID: ${{ secrets.TRIAGE_BOT_INSTALLATION_ID }}
38+
TRIAGE_BOT_PRIVATE_KEY: ${{ secrets.TRIAGE_BOT_PRIVATE_KEY }}
39+
TRIAGE_BOT_JAMAI_KEY: ${{ secrets.TRIAGE_BOT_JAMAI_KEY }}
40+
TRIAGE_BOT_JAMAI_PROJECT_ID: ${{ secrets.TRIAGE_BOT_JAMAI_PROJECT_ID }}
41+
TRIAGE_BOT_NAME: ${{github.actor}}
42+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
43+
GITHUB_EVENT_NAME: ${{ github.event_name }}
44+
GITHUB_EVENT_PATH: ${{ github.event_path }}

.prettierignore

Lines changed: 23 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,41 @@
1+
# OS
2+
thumbs.db
3+
.DS_Store
4+
5+
# Internal references, dependencies, temporary folders & files
6+
.env
7+
archive/
8+
**/__ref__/
9+
*.log
10+
*.lock
11+
*.db
12+
*.parquet
13+
114
# Python
215
__pycache__/
3-
*.py[cod]
16+
*.py*
417
*$py.class
518
*.egg-info
619
.pytest_cache
720
.ipynb_checkpoints
821
venv/
9-
10-
# Frontend
11-
services/app
12-
clients/typescript
13-
14-
# Test files
1522
clients/python/tests/**/*
1623

17-
# Internal references, dependencies, temporary folders & files
18-
archive/
19-
/dependencies/
20-
logs/
21-
*.log
24+
# pip
25+
**/build/
2226

2327
# pytest-cov
2428
**/.coverage*
2529
/junit
2630
/htmlcov
2731
/coverage.xml
2832

29-
# pip
30-
**/build/
33+
# jest-cov
34+
**/coverage/*
3135

32-
# Docs
33-
/docs/source/generated/
34-
/docs/source/api/generated/
35-
/docs/source/specs/
36+
# JavaScript
37+
**/node_modules/
3638

37-
# OS
38-
thumbs.db
39-
.DS_Store
39+
# Frontend
40+
services/app
41+
clients/typescript

CHANGELOG.md

Lines changed: 64 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -16,32 +16,79 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
1616

1717
## [Unreleased]
1818

19-
Backend - owl (API server)
19+
### ADDED
20+
21+
Python SDK - jamaibase
2022

21-
- Fix bge-small embedding size (1024 -> 384)
22-
- Correctly filter models at auth level
23-
- Fix ollama model deployment config
23+
- Add `CodeGenConfig` for python code execution #446
2424

25-
Frontend
25+
TS SDK - jamaibase
26+
27+
UI
2628

27-
- Added support for multiple multiturn columns in Chat table chat view.
28-
- Added multiturn chat toggle to column settings.
29+
- Support chat mode multiturn option in add column and column resize #451
30+
- Support `audio` data type #457
2931

30-
Docker
32+
Backend - owl (API server)
3133

32-
- Added Mac Apple Silicon `compose.mac.yml`
33-
- Update `ollama.yml` to use Qwen2.5 3B
34-
- Fix ollama default config
34+
- GenTable
35+
- Support `audio` input column and data type #443
36+
- Support python code execution column #446
37+
- **Breaking**: Add `Page` column to knowledge table #464
38+
- LLM
39+
- Support function calling # 435
40+
- Support DeepSeek models #466
41+
- Billing
42+
- Include background tasks for processing billing events #462
43+
- Auth
44+
- Support specific user role in organization invite #446
45+
- Include background tasks for setting project updated at datetime #462
46+
- Handle and allow setting of file upload size limits for `embed file`, `image` and `audio` file types #443
3547

36-
## [v0.3.1] (2024-11-26)
48+
CI/CD
3749

38-
This is a bug fix release for frontend code. SDKs are not affected.
50+
- Added a new CI workflow for cloud environments in`.github/workflows/ci.cloud.yml` #440
51+
- Add dummy test job to pass status checks if skipped #468
52+
- Added a `check_changes` job to the CI workflows to conditionally run SDK tests based on changes. #462
3953

4054
### CHANGES / FIXED
4155

42-
Frontend
56+
Python SDK - jamaibase
57+
58+
TS SDK - jamaibase
4359

44-
- Enable Projects for OSS
60+
- Update the `uploadFile` method in `index.ts` to remove the trailing slash from the API endpoint #462
61+
62+
UI
63+
64+
- Remove unnecessary load function rerunning on client navigation #454
65+
- Add more export options with confirmation #459
66+
- Obfuscated external keys and credit values for non-admin users in the `+layout.server.ts` to enhance security and privacy #459
67+
- Update `FileSelect.svelte` and `NewRow.svelte` to remove trailing slashes from the file upload API endpoint #462
68+
- Bug fixes:
69+
- Fix chat table scrollbar not showing issue #459
70+
- Fix keyboard navigation #459
71+
- Fix inappropriate model not showing issue in knowledge table column settings #459
72+
73+
Backend - owl (API server)
74+
75+
- GenTable
76+
- **Breaking**: Change `file` data type to `image` data type #460
77+
- LLM
78+
- Handle usage tracking and improve error handling #462
79+
- Bug fixes
80+
- Fix model config embedding size #441
81+
- Fix bug with default model choosing invalid models #442
82+
- Fix regen sequences issue after columns reordering #455
83+
84+
CI/CD
85+
86+
- Dockerfile: Added `ffmpeg` installation for audio processing. #443
87+
- Dependency Updates:
88+
- Set `litellm` to version `1.50.0` #443
89+
- Add `pydub` as a dependency for audio processing #443
90+
91+
### REMOVED
4592

4693
## [v0.3] (2024-11-20)
4794

@@ -427,7 +474,7 @@ Backend - owl (API server)
427474
- Windows: StreamResponse from FastAPI accumulates all SSE before yielding everything all at once to the client Fixes #145
428475
- Enabled scanned pdf upload. Fixes #131
429476
- Dependencies
430-
- Support forked version of `unstructured-client==0.24.1`, changed nest-asyncio to ThreadPool, fixed the conflict with uvloop
477+
- Support forked version of `unstructured-client==0.24.1`, changed `nest-asyncio` to `ThreadPool`, fixed the conflict with `uvloop`
431478
- Added `tenacity`, `pandas`
432479
- Bumped dependency versions
433480

@@ -441,7 +488,7 @@ Backend - Admin (cloud)
441488

442489
- Improve insufficient credit error message: include quota/usage type in the message
443490
- Storage usage update is now a background process; fixes #87
444-
- Allow dot in the middle for project name and organization name.
491+
- Allow dot in the middle for project name and organization name.
445492
- Update `models.json` in `set_model_config()`
446493
- Billing: Don't include Lance version directories in storage usage computation
447494
- Bug fixes

0 commit comments

Comments
 (0)