Compare commits

...

2262 Commits

Author SHA1 Message Date
Vitor Alcantara Batista
154301b3ad
Brazilian Portuguese translation (#6809)
Co-authored-by: Vitor Alcantara Batista <vitor.alcantara@petrobras.com.br>
2025-10-29 23:36:35 +05:30
Nghia Doan
e7b7ac9e94
Merge pull request #6831 from janhq/feat/proactive_mode
feat: Proactive mode
2025-10-29 21:02:05 +07:00
Nguyen Ngoc Minh
e531eaa4ad
Merge pull request #6836 from janhq/chore/deprecate-webhook-discord
chore: deprecate webhook discord
2025-10-29 12:15:07 +07:00
Minh141120
23b03da714 chore: deprecate webhook discord 2025-10-29 11:48:32 +07:00
Vanalite
22be93807d Merge remote-tracking branch 'origin/dev' into feat/proactive_mode 2025-10-28 17:56:47 +07:00
Nguyen Ngoc Minh
653ecdb494
Merge pull request #6834 from janhq/chore/update-org-name
chore: update org name
2025-10-28 17:56:07 +07:00
Minh141120
15c426aefc chore: update org name 2025-10-28 17:26:27 +07:00
Vanalite
2fa153ac34 fix: Remove unused Proactive icon on chatInput
This icon doesn't do anything on chatInput but just an indicator when the proactive capability is activated. Safely remove since this can be indicated from the model dropdown
2025-10-28 17:04:31 +07:00
Dinh Long Nguyen
62bd91a1e1
fix: model should not include file attachment tools if not supported (#6833) 2025-10-28 16:58:18 +07:00
Vanalite
f7e0e790b6 feat: remove unnecessary TODO 2025-10-28 15:49:17 +07:00
hiento09
c854c54c0c
chore: update api domain to jan.ai (#6832) 2025-10-28 15:45:42 +07:00
Vanalite
a14872666a feat: Add tests for proactive mode 2025-10-28 12:19:00 +07:00
Vanalite
e9f469b623 feat: Proactively take screenshot and snapshot for every browser tool call 2025-10-28 11:48:55 +07:00
utenadev
5a016860aa
feat: Add Japanese translation (#6806)
This commit introduces Japanese as a supported language in the web application.

Key changes include:
- Addition of a new `ja` locale with 15 translated JSON resource files, making the application accessible to Japanese-speaking users.
- Update of the `LanguageSwitcher.tsx` component to include '日本語' in the language selection dropdown menu, allowing users to switch to the new language.
- The localization files were added by creating a new `ja` directory under `web-app/src/locales` and translating the content from the `en` directory.

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
2025-10-27 19:53:36 +05:30
Vanalite
c773abb688 feat: Adding proactive button as experimental feature 2025-10-27 18:18:23 +07:00
Akarshan Biswas
2561fcd78a
feat: support multimodal tool results and improve tool message handling (#6816)
* feat: support multimodal tool results and improve tool message handling

- Added a temporary `ToolResult` type that mirrors the structure returned by tools (text, image data, URLs, errors).
- Implemented `convertToolPartToApiContentPart` to translate each tool output part into the format expected by the OpenAI chat completion API.
- Updated `CompletionMessagesBuilder.addToolMessage` to accept a full `ToolResult` instead of a plain string and to:
  - Detect multimodal content (base64 images, image URLs) and build a structured `content` array.
  - Properly handle plain‑text results, tool execution errors, and unexpected formats with sensible fallbacks.
  - Cast the final content to `any` for the `tool` role as required by the API.
- Modified `postMessageProcessing` to pass the raw tool result (`result as any`) to `addToolMessage`, avoiding premature extraction of only the first text part.
- Refactored several formatting and type‑annotation sections:
  - Added multiline guard for empty user messages to insert a placeholder.
  - Split the image URL construction into a clearer multiline object.
  - Adjusted method signatures and added minor line‑breaks for readability.
- Included extensive comments explaining the new logic and edge‑case handling.

These changes enable the chat system to handle richer tool outputs (e.g., images, mixed content) and provide more robust error handling.

* Satisfy ts linter

* Make ts linter happy x2

* chore: update test message creation

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-10-24 20:15:15 +05:30
locnguyen1986
28ed5e2af2
Merge pull request #6817 from menloresearch/fix/conversation-saving
we use POST to update now
2025-10-24 14:51:57 +07:00
nguyen.ngo
4c5c8e6aed we use POST to update now 2025-10-24 13:09:35 +07:00
Dinh Long Nguyen
f07e43cfe0
fix: conversation items (#6815) 2025-10-24 09:01:31 +07:00
Dinh Long Nguyen
e46200868e
web: update model capabilites (#6814)
* update model capabilites

* refactor + remove projects
2025-10-24 01:31:21 +07:00
Akarshan Biswas
147cab94a8
fix: Escape dollar signs followed by numbers in Markdown (#6797)
This commit introduces a change to prevent **Markdown** rendering issues where a dollar sign followed by a number (like **`$1`**) is incorrectly interpreted as **LaTeX** by the rendering engine.

---

The `normalizeLatex` function in `RenderMarkdown.tsx` now explicitly escapes these sequences (e.g., **`$1`** becomes **`\$1`**), ensuring they are displayed literally instead of being processed as mathematical expressions. This improves the fidelity of text that might contain currency or similar numerical notations.
2025-10-16 12:15:24 +05:30
Nguyen Ngoc Minh
2fb956ccaf
Merge pull request #6798 from menloresearch/docs/changelog-v0.7.2
docs: update changelog for Jan v0.7.2
2025-10-16 13:26:36 +07:00
Minh141120
4dee0a4ba1 docs: update changelog for Jan v0.7.2 2025-10-16 13:18:20 +07:00
Nguyen Ngoc Minh
418a48ab39
Merge pull request #6790 from menloresearch/chore/happy-dom-update
chore: update happy dom deps version
2025-10-15 02:53:24 -07:00
Minh141120
9bc56f6e30 chore: remove redudant deps in yarn lock file 2025-10-15 15:15:38 +07:00
Minh141120
f0ca9cce35 chore: update happy-dom version 2025-10-15 14:43:58 +07:00
Faisal Amir
746dbc632b
Merge pull request #6766 from menloresearch/feat/file-attachment
feat: file attachment
2025-10-15 11:01:40 +07:00
Faisal Amir
462b05e612 chore: fix conflict revert analytic 2025-10-15 10:35:36 +07:00
dinhlongviolin1
946b347f44 fix: lint 2025-10-15 00:21:10 +07:00
Dinh Long Nguyen
b23e88f078
Merge branch 'dev' into feat/file-attachment 2025-10-14 14:06:17 +07:00
Trang Le
476fdd6040
feat: Enable new prompt input while waiting for an answer (#6676)
* enable new prompt input while waiting for an answer

* correct spelling of handleSendMessage function

* remove test for disabling input while streaming content
2025-10-14 14:04:52 +07:00
Dinh Long Nguyen
fa8b3664cb
Merge branch 'dev' into feat/file-attachment 2025-10-14 14:00:10 +07:00
Nguyen Ngoc Minh
8b687619b2
Merge pull request #6783 from menloresearch/docs/update-jan-web-url
docs: update jan server url
2025-10-13 23:58:49 -07:00
Minh141120
176ad07f1d docs: update jan server url 2025-10-14 13:54:43 +07:00
Faisal Amir
7b5060c9be
Merge pull request #6774 from menloresearch/chore/disable-posthog-event
chore: revert track event posthog
2025-10-13 10:13:45 +07:00
Faisal Amir
584daa9682 chore: revert track event posthog 2025-10-11 21:46:15 +07:00
Akarshan
31f9501d8e
feat: Optimize state updates in server and model checks
- Added shallow equality guard for `connectedServers` state to prevent redundant updates when the fetched server list hasn't changed.
- Updated error handling for server fetch to only clear the state when it actually contains data.
- Introduced `newHasActiveModels` variable and conditional updater for `hasActiveModels` to avoid unnecessary state changes.
- Adjusted error handling for active model fetch to only set `hasActiveModels` to `false` when the current state differs.

These changes reduce needless re‑renders and improve component performance.
2025-10-10 20:25:17 +05:30
Roushan Kumar Singh
c096929d8b
fix(amd/linux): show dedicated VRAM on device list (override Vulkan UMA) (#6533) 2025-10-09 23:33:07 +07:00
Akarshan Biswas
01050f3103
fix: Gracefully handle offline mode during backend check (#6767)
The `listSupportedBackends` function now includes error handling for the `fetchRemoteSupportedBackends` call.

This addresses an issue where an error thrown during the remote fetch (e.g., due to no network connection in offline mode) would prevent the subsequent loading of locally installed or manually provided llama.cpp backends.

The remote backend versions array will now default to empty if the fetch fails, allowing the rest of the backend initialization process to proceed as expected.
2025-10-09 07:21:53 +05:30
Dinh Long Nguyen
45d57dd34d
Update web-app/src/services/uploads/default.ts
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-10-09 04:53:19 +07:00
Dinh Long Nguyen
f4066e6e5a
Update web-app/src/lib/fileMetadata.ts
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-10-09 04:50:31 +07:00
Dinh Long Nguyen
a2fbce698f fix thread scrolling 2025-10-09 04:41:18 +07:00
Dinh Long Nguyen
fc784620e0 fix tests 2025-10-09 04:28:08 +07:00
Dinh Long Nguyen
340042682a ui ux enhancement 2025-10-09 03:48:51 +07:00
Dinh Long Nguyen
6dd2d2d6c1
Merge branch 'dev' into feat/file-attachment 2025-10-09 02:21:22 +07:00
Akarshan
7762cea10a
feat: Distinguish and preserve embedding model sessions
This commit introduces a new field, `is_embedding`, to the `SessionInfo` structure to clearly mark sessions running dedicated embedding models.

Key changes:
- Adds `is_embedding` to the `SessionInfo` interface in `AIEngine.ts` and the Rust backend.
- Updates the `loadLlamaModel` command signatures to pass this new flag.
- Modifies the llama.cpp extension's **auto-unload logic** to explicitly **filter out** and **not unload** any currently loaded embedding models when a new text generation model is loaded. This is a critical performance fix to prevent the embedding model (e.g., used for RAG) from being repeatedly reloaded.

Also includes minor code style cleanup/reformatting in `jan-provider-web/provider.ts` for improved readability.
2025-10-08 20:03:35 +05:30
Faisal Amir
610b741db2
Merge pull request #6763 from menloresearch/chore/turn-off-zoomHotkeysEnabled
chore: turn off zoomHotkeysEnabled
2025-10-08 19:16:34 +07:00
Faisal Amir
814034d3d7
Merge pull request #6762 from menloresearch/fix/remove-setup-screen
fix: remove setup screen on project id to make same behavior with thread
2025-10-08 19:16:05 +07:00
Nguyen Ngoc Minh
839672b82f
Merge pull request #6765 from menloresearch/chore/license-path
chore: update license path
2025-10-08 03:28:43 -07:00
Minh141120
03762c3634 chore: revert packageManger 2025-10-08 16:57:21 +07:00
Minh141120
59c76bcb1c chore: revert copy asset script 2025-10-08 16:56:36 +07:00
Minh141120
1905f9a9ce chore: move license to resources 2025-10-08 16:55:24 +07:00
Dinh Long Nguyen
ff93dc3c5c Merge branch 'dev' into feat/file-attachment 2025-10-08 16:34:45 +07:00
Dinh Long Nguyen
510c4a5188 working attachments 2025-10-08 16:08:40 +07:00
Minh141120
c7d1a3c65d chore: update license path 2025-10-08 15:48:16 +07:00
hiento09
999b7b3cd8
chore: api change domain to menlo.ai (#6764) 2025-10-08 13:22:26 +07:00
Faisal Amir
f224d18d7f chore: turn off zoomHotkeysEnabled 2025-10-08 12:54:04 +07:00
Nghia Doan
1bf5c770cf
Merge pull request #6757 from menloresearch/fix/resolve-web-extensions-conflict
fix: resolve extensions conflict with correct path for web-app
2025-10-08 12:45:44 +07:00
Faisal Amir
613bc85a13 fix: remove setup screen on project id to make same behavior with thread 2025-10-08 12:41:26 +07:00
Faisal Amir
b1abc97bda
Merge pull request #6759 from menloresearch/fix/font-json-editor
fix: font mono default from mcp json ediitor
2025-10-08 10:20:11 +07:00
Faisal Amir
eec94c47dd chore: make class important 2025-10-07 22:28:58 +07:00
Faisal Amir
b2632a005c fix: font mono default from mcp json ediitor 2025-10-07 22:10:53 +07:00
Akarshan Biswas
706dad2687
feat: Add support for llamacpp MoE offloading setting (#6748)
* feat: Add support for llamacpp MoE offloading setting

Introduces the n_cpu_moe configuration setting for the llamacpp provider. This allows users to specify the number of Mixture of Experts (MoE) layers whose weights should be offloaded to the CPU via the --n-cpu-moe flag in llama.cpp.

This is useful for running large MoE models by balancing resource usage, for example, by keeping attention on the GPU and offloading expert FFNs to the CPU.

The changes include:

 - Updating the llamacpp-extension to accept and pass the --n-cpu-moe argument.

 - Adding the input field to the Model Settings UI (ModelSetting.tsx).

 - Including model setting migration logic and bumping the store version to 4.

* remove unused import

* feat: add cpu-moe boolean flag

* chore: remove unused migration cont_batching

* chore: fix migration delete old key and add new one

* chore: fix migration

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-10-07 19:37:58 +05:30
Faisal Amir
e5be683a97
Merge pull request #6755 from menloresearch/chore/analytic-model-used
chore: create event to track model provider and id model
2025-10-07 20:36:42 +07:00
Louis
e7fcc809e7
Merge pull request #6756 from menloresearch/sync/release-7-1-into-dev
Sync release 0.7.1 to dev
2025-10-07 19:57:28 +07:00
Louis
26006c143e
fix: build 2025-10-07 19:33:49 +07:00
Louis
28afafaad7
Update .github/workflows/template-tauri-build-windows-x64.yml
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-10-07 18:36:56 +07:00
Vanalite
dd1b3c98bf fix: resolve extensions conflict with correct path for web-app 2025-10-07 18:33:51 +07:00
Louis
3919cd0306
fix: build error 2025-10-07 18:32:43 +07:00
Faisal Amir
7d615b4163 chore: type fixed 2025-10-07 18:10:25 +07:00
Nguyen Ngoc Minh
4828f34fec
Merge pull request #6728 from menloresearch/fix/anthropic-model-load
Fix: Anthropic request to add models
2025-10-07 18:05:33 +07:00
Faisal Amir
61c3fd4b5a
Merge pull request #6727 from menloresearch/fix/prompt-token
fix: prompt token
2025-10-07 18:05:29 +07:00
Nguyen Ngoc Minh
816d60b22a
Merge pull request #6721 from menloresearch/chore/use-custom-nsis-template
chore: use custom nsis template
# Conflicts:
#	Makefile
#	package.json
#	src-tauri/tauri.windows.conf.json
2025-10-07 18:05:14 +07:00
Faisal Amir
310ca7cb23 chore: create message_sent event to track model provider and id model 2025-10-07 18:04:58 +07:00
Faisal Amir
fa397038ef
Merge pull request #6753 from menloresearch/fix/auto-select-download-model
fix: auto select download model
2025-10-07 17:16:19 +07:00
Faisal Amir
dabc49567c
Merge pull request #6743 from menloresearch/chore/dropdown-submenu-scrollable
chore: make dropdown sub menu assign projects scrollable
2025-10-07 13:36:01 +07:00
Faisal Amir
d8dcba3552 fix: auto select download model 2025-10-07 13:29:56 +07:00
Nghia Doan
f4efd479d5
Merge pull request #6746 from menloresearch/feat/hide-project-mobile
feat: Hide projects for mobile version
2025-10-07 10:38:03 +07:00
Dinh Long Nguyen
a72c74dbf9 initial layout 2025-10-07 10:36:45 +07:00
Louis
6c4dd85e6f
Merge pull request #6720 from menloresearch/release/v0.7.0
Sync release v0.7.0 to dev
2025-10-06 22:31:06 +07:00
Louis
9bfec5c7b3
Sync dev into release (#6747)
* feat: Init mobile app from current Tauri v2 framework

Feat:
- Using Tauri v2 by default
- Add new configuration to initiate mobile app
- Add dependencies needed for mobile build
Test:
- Confirm to be built successfully
- Confirm to keep settings for desktop and build successfully
- Reuse most of components from desktop version

* fix: Fix tests

* feat: Add android target

* fix: Reconfigure and add toolchain to wake up Android app

* fix: Fix parsing datatype inconsistent across platforms

* feat: Adjust UI for mobile res

Feature:
- Adjust homecreen and chatscreen for mobile device
- Fix tests for both FE and BE
Self-test:
- Confirm runnable on both Android and iOS
- Confirm runnable on desktop app
- All test suites passed
- Working with ChatGPT API

* fix: Restore dedupe command

* chore: Adjust paddings to save some space for the top nav bar

* Update web-app/src/routes/index.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* chore: keep gen icon on Android

* chore: add command to ease the mobile dev

* chore: Separate configuration for android build in release mode

* chore: Shrink the Android app size to minimal, release type

* feat: Disable zoom and setup mobile viewport

* chore: Configure iOS to use the same build mechanic to remove unnecessary plugin

* fix: Remove redundant yarn command for ios dev build

* enhancement: fit mobile layout

* chore: update chatscreen padding

* chore: update checking platform using config isntead navigation agent

* chore: update height of thread detail

* remove gen android

* Update web-app/src/index.css

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* fix: Add frontendDist to ios configuration

* feat: Experiment removing hardware permission

* fix: Android releasable build

* feat: Add dev-android to makefile

* feat: Add dev-ios to makefile for ios development

* refactor(utils): add helper to remove extensions from file paths

* chore: fix Encoded logging

* refactor: safely strip prefix and extensions from filename

* chore: add logging for TauriDialog Service

* Update handbook content with Nextra callout and content improvements

- Convert blockquote to Nextra callout in open-superintelligence.mdx
- Add Edison link and improve content flow
- Refine language for better clarity

* docs: enhance overview page with improved structure and internal linking

- Restructured main content with cleaner formatting
- Added comprehensive internal linking for better navigation
- Improved visual hierarchy and readability
- Enhanced acknowledgements section with better organization
- Updated product suite section with consistent formatting

* Update handbook navigation structure and meta.json files

- Updated handbook/_meta.json to properly organize navigation
- Fixed duplicate entries by removing files that belong in subfolders
- Updated why folder title to 'Why does Jan exist?'
- Cleaned up why/_meta.json with proper titles for Open Superintelligence and Open-Source sections

* docs: fix broken internal links and remove privacy page

- Fix broken links in troubleshooting.mdx pointing to install pages
- Remove privacy.mdx page and update _meta.json navigation
- Update various documentation links for consistency
- Ensure all internal links use proper absolute paths

* Optimize installation pages SEO meta titles and descriptions

 SEO Improvements:
- Mac: 'Run AI models locally on your Mac - Jan'
- Linux: 'Run AI models locally on Linux - Jan'
- Windows: 'Run AI models locally on Windows - Jan'

🎯 Meta descriptions now include:
- Target keywords (local AI, LLM, offline, ChatGPT-like)
- Platform-specific details (Apple Silicon, Ubuntu/Debian, Windows 10/11)
- Key benefits (GPU acceleration, privacy, no internet required)

📍 Sidebar navigation titles unchanged - only SEO meta data optimized

* Clean up installation page titles and descriptions

- Revert titles to clean sidebar navigation (Mac, Linux, Windows)
- Improve meta descriptions to be concise but SEO-friendly
- Keep key terms: local AI, offline, GPU acceleration, platform details

* Update README.md

* Update README.md

* trigger PR banner

* docs: update missing redirect links

* enhancement: social media navbar and update menu footer

* Update docs/src/components/Navbar.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update docs/src/components/Navbar.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* fix: Apply model name change correctly

# Conflicts:
#	web-app/src/lib/utils.ts

* feat: Disable text selection on Toaster

Disable the option to select text on the Toaster to consist the swiping action on the toast in order to dismiss it

* fix: scroll issue padding not re render correctly (#6639)

* trigger PR banner

* Improve FAQ section and content updates for offline ChatGPT alternative post

* Add SEO-optimized Twitter meta titles for installation pages

- Add Twitter meta tags to Windows, Linux, and Mac installation pages
- Optimize meta titles: 'Jan on [Platform]' for better SEO
- Maintain consistent meta descriptions across all platforms
- Keep original page titles unchanged for user experience

* Update content files

- Update tabby server example
- Update troubleshooting documentation
- Update NVIDIA TensorRT-LLM benchmarking post

* Add ChatGPT alternative blog post and update installation docs

* Update ChatGPT alternative blog post

* Rename blog post from chatgpt-alternative-jan.mdx to chatgpt-alternatives.mdx

* feat: add real-time ChatGPT status checker blog post

- Add new blog post: 'is-chatgpt-down-use-jan'
- Create OpenAIStatusChecker React component with real-time data
- Use CORS proxy to fetch live OpenAI status from status.openai.com
- Include SEO-optimized status indicators and error messages
- Add ChatGPT downtime promotion for Jan alternative
- Component features: auto-refresh, fallback handling, dark mode support

* chore: fix typo

* chore: fix failed build

* refactor: deprecate Vulkan external binaries (#6638)

* refactor: deprecate vulkan binary

refactor: clean up vulkan lib

chore: cleanup

chore: clean up

chore: clean up

fix: build

* fix: skip binaries download env

* Update src-tauri/utils/src/system.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src-tauri/utils/src/system.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* feat: Add tests for the model displayName modification

* fix: Fix linter error

* fix: Fix nvidia and vulkan after upgrade to be compatible with mobile compiling too

* Fix OG image paths and move images to general folder

- Move OG images from _assets/ to public/assets/images/general/
- Update all blog post references to use correct paths
- Remove duplicate images from _assets/ folder
- Fix image paths in content to use /assets/images/general/ format
- Update Twitter image references to match OG image paths

Files updated:
- chatgpt-alternatives.mdx
- deepresearch.mdx
- deepseek-r1-locally.mdx
- how-we-benchmark-kernels.mdx
- is-chatgpt-down-use-jan.mdx
- offline-chatgpt-alternative.mdx
- qwen3-settings.mdx
- run-ai-models-locally.mdx
- run-gpt-oss-locally.mdx

* fix: remove Jan prefix from blog post titles for better SEO

- Blog posts now use only frontmatter title without 'Jan -' prefix
- Other pages maintain existing branding (Jan Desktop, Jan Server, Jan)
- Improves SEO for blog content while preserving site branding

* update blog post content

* Feat: web temporary chat (#6650)

* temporray chat stage1

* temporary page in root

* temporary chat

* handle redirection properly
`

* temporary chat header

* Update extensions-web/src/conversational-web/extension.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* update routetree

* better error handling

* fix strecthed assitant on desktop

* update yarn link to workspace for better link consistency

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Add Guides category to blog navigation

- Add 'guides' category to staticCategories array in Blog component
- Update plopfile.js to include guides in category choices
- Add guides category entry to _meta.json
- Position guides category after research in navigation

* docs: update redirect links

* Update AI for Law blog post with images and content improvements

- Add hero image for AI for Law blog post
- Add images to assistant creation and contract review sections
- Improve content structure and readability
- Add proper image assets for legal AI use cases
- Update ogImage and twitter image references

* fix: revert the modification of vulkan

* Add AI for Teachers blog post with images and video

- Create comprehensive AI for Teachers blog post
- Add hero image and assistant creation interface images
- Include video demonstration of Jan for teachers
- Add proper ogImage and twitter image references
- Cover lesson planning, grading, parent communication, and classroom resources
- Focus on privacy and offline AI for educational use

* fix: Fix linter and tests

* fix: Restore default permission on desktop build

Restore desktop capabilities
Restore linter correctness
Restore different capabilities on each platform

* fix: Fix cargo test

* feat: web add search button for extension (#6671)

* add search button for web extension

* change button color and behavior

* Update extensions-web/src/mcp-web/components/WebSearchButton.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* add eof new line missing (#6673)

* fix lint issue

* fix: mcp bin path (#6667)

* fix: mcp bin path

* chore: clean up unused structs

* fix: bin name

* fix: tests

* remove test conflict

* add missing closing test

* fix tauri test

* feat: disable all web mcp by default (new users) (#6677)

* fix: chat completion usage - token speed (#6675)

* resolve TypeScript and Rust warnings (#6612)

* chore: fix warnings

* fix: add missing scrollContainerRef dependencies to React hooks

* fix: typo

* fix: remove unsupported fetch option and enable AsyncIterable types

- Removed `connectTimeout` from fetch init (not supported in RequestInit)
- Updated tsconfig to target ES2018

* chore: refactor rename

* fix(hooks): update dependency arrays for useThreadScrolling effects

* Add type.d.ts to extend requestinit with connectionTimeout

* remove commentd unused import

* fix: Fix editing model without saving should restore original name

* fix: thread item overfetching (#6699)

* fix: thread item overfetching

* chore: cleanup left over import

* feat: improve projects (#6698)

* decouple successfully

* only show movable projects for project items

* handle delete covnersations when projects is removed

* fix leftpanel assignemtn

* fix lint

* fix gg tag (#6702)

* refactor: resolve rust analyzer warnings and improve code quality (#6696)

- Update string formatting to use modern interpolation syntax
- Simplify expressions and remove unnecessary intermediate variables
- Improve logging statements for better readability
- Clean up code across core modules (app, downloads, mcp, server, etc.)

* docs: add Jan v0.7.0 changelog

* docs: update Jan v0.7.0 changelog content

* docs: rename changelog file to remove trailing dash

* feat: use sql for mobile storage

* feat: organize code for proper import

Move platform checker for db access to helper
Add test for to threads controller

* feat: better structure for MobileCoreService

MobileCoreService should inherit TauriCoreService to match Tauri architecture patterns

* fix: Extract model capabilities correctly for various providers on various platforms

* fix: yarn lint

* ci: remove upload msi

* fix: extensions missing on Unix dev (#6724)

* fix: extensions missing on Unix dev

* re add bun uv for mcp

* fix: Local API Server - disable settings on run (#6707)

* fix: Fix tests in threads with proper mock folder properly

* changelog: release 0.7.1

* chore: wrong version in detail changelog

* fix: update detail changelog 0.7.1

* fix(ui): restore missing border on model selector (#6692)

* fix: Fix openssl issue on mobile after merging

* fix: Remove yarn.lock changes

* chore(ui): refine className for dropdown menu with animation states

* chore: Reposition 'Remove project' option for better usability

* feat: add project search and scrollable thread lists

- Add search bar to filter projects by name in real-time
- Implement scrollable thread container with max 4 visible threads
- Add empty state for no search results
- Add clear button (X) to reset search query

* (chore): rename translation keys to collapseProject/expandProject

* Fix Translation changes across locales

* (chore): remove duplicate keys from de-DE/common.json

* Add SearchProjects to missing locales

* fix: theme native system and check os support blur

* fix: new window theme

* fix: open new window theme

* fix: test use case appearance

* chore: fix window type theme service

* chore: update permission windows

* chore: fix desktop capabilities

* chore: check support blur using hardware api

* chore: check support blur on FE

* chore: fix new chat with update last selected model dropdown

* fix: tittle recent when no result found

---------

Co-authored-by: Vanalite <dhnghia0604@gmail.com>
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
Co-authored-by: Faisal Amir <urmauur@gmail.com>
Co-authored-by: Roushan Singh <github.rtron18@gmail.com>
Co-authored-by: eckartal <emre@jan.ai>
Co-authored-by: Emre Can Kartal <159995642+eckartal@users.noreply.github.com>
Co-authored-by: Roushan Kumar Singh <158602016+github-roushan@users.noreply.github.com>
Co-authored-by: Nguyen Ngoc Minh <91668012+Minh141120@users.noreply.github.com>
Co-authored-by: Minh141120 <minh.itptit@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Dinh Long Nguyen <dinhlongviolin1@gmail.com>
2025-10-06 21:43:24 +07:00
Louis
fe2c2a8687 Merge branch 'dev' into release/v0.7.0
# Conflicts:
#	web-app/src/containers/DropdownModelProvider.tsx
#	web-app/src/containers/ThreadList.tsx
#	web-app/src/containers/__tests__/DropdownModelProvider.displayName.test.tsx
#	web-app/src/hooks/__tests__/useModelProvider.test.ts
#	web-app/src/hooks/useChat.ts
#	web-app/src/lib/utils.ts
2025-10-06 20:42:05 +07:00
Vanalite
b23aa68254 feat: Hide projects for mobile version 2025-10-06 18:14:03 +07:00
Faisal Amir
0588cb34c6
Merge pull request #6713 from menloresearch/fix/theme-system
fix: theme system cross platform
2025-10-06 16:58:53 +07:00
Faisal Amir
b32e3ebd60
Merge pull request #6742 from menloresearch/fix/last-used-model
fix: new chat with update last selected model dropdown
2025-10-06 15:03:00 +07:00
Faisal Amir
cc77ae3430
Merge pull request #6744 from menloresearch/fix/no-result-found
fix: title recent when no result found
2025-10-06 15:01:58 +07:00
Faisal Amir
ac6eda063a fix: tittle recent when no result found 2025-10-06 11:35:27 +07:00
Faisal Amir
f160d83ca9 chore: make drodpwon sub menu assisgn project scroll able 2025-10-06 11:16:02 +07:00
Faisal Amir
13c7ad707e chore: fix new chat with update last selected model dropdown 2025-10-06 11:06:15 +07:00
Faisal Amir
17dced03c0 chore: check support blur on FE 2025-10-06 10:55:17 +07:00
Faisal Amir
39b1ba4691 chore: check support blur using hardware api 2025-10-06 10:55:17 +07:00
Faisal Amir
8c7ad408a9 chore: fix desktop capabilities 2025-10-06 10:55:17 +07:00
Faisal Amir
f0c4784b7b chore: update permission windows 2025-10-06 10:55:17 +07:00
Faisal Amir
83fc68e27d chore: fix window type theme service 2025-10-06 10:55:17 +07:00
Faisal Amir
be9a6c0254 fix: test use case appearance 2025-10-06 10:55:17 +07:00
Faisal Amir
1acdb77ad1 fix: open new window theme 2025-10-06 10:55:17 +07:00
Faisal Amir
51e7a08118 fix: new window theme 2025-10-06 10:55:17 +07:00
Faisal Amir
aa0c4b0d1b fix: theme native system and check os support blur 2025-10-06 10:55:17 +07:00
Faisal Amir
80ee8fd2b2
Merge pull request #6726 from github-roushan/dropdown-ui
UI enhancement for projects
2025-10-06 10:54:57 +07:00
Roushan Singh
291482cc16 Add SearchProjects to missing locales 2025-10-06 10:46:18 +07:00
Roushan Singh
154bc17778 (chore): remove duplicate keys from de-DE/common.json 2025-10-06 10:46:18 +07:00
Roushan Singh
cc5130c1af Fix Translation changes across locales 2025-10-06 10:46:18 +07:00
Roushan Singh
2d9f20ffb6 (chore): rename translation keys to collapseProject/expandProject 2025-10-06 10:46:18 +07:00
Roushan Singh
3e332eceae feat: add project search and scrollable thread lists
- Add search bar to filter projects by name in real-time
- Implement scrollable thread container with max 4 visible threads
- Add empty state for no search results
- Add clear button (X) to reset search query
2025-10-06 10:46:18 +07:00
Roushan Singh
73b241c16f chore: Reposition 'Remove project' option for better usability 2025-10-06 10:46:18 +07:00
Roushan Singh
8ed68d9c19 chore(ui): refine className for dropdown menu with animation states 2025-10-06 10:46:18 +07:00
Nghia Doan
b5e57a429a
Merge pull request #6714 from menloresearch/mobile/persistence_store
Feat: Jan mobile has persistence store
2025-10-06 10:02:53 +07:00
Vanalite
62fa0ffa57 fix: Remove yarn.lock changes 2025-10-06 09:43:45 +07:00
Faisal Amir
481e9c1130
Merge pull request #6736 from github-roushan/border-fix
fix(ui): restore missing border on model selector (#6692)
2025-10-06 09:39:10 +07:00
Roushan Kumar Singh
93652ce884
Merge branch 'dev' into border-fix 2025-10-05 17:29:40 +05:30
Vanalite
fa61163350 fix: Fix openssl issue on mobile after merging 2025-10-05 14:40:39 +07:00
Roushan Singh
cb9eb6d238 fix(ui): restore missing border on model selector (#6692) 2025-10-04 22:21:02 +05:30
Vanalite
41a93690a1 Merge remote-tracking branch 'origin/dev' into mobile/persistence_store 2025-10-04 12:28:11 +07:00
Faisal Amir
b309d34274
Merge pull request #6732 from menloresearch/chore/update-changelog
fix: update detail changelog 0.7.1
2025-10-03 23:33:57 +07:00
Faisal Amir
ca485b4a35 fix: update detail changelog 0.7.1 2025-10-03 23:33:02 +07:00
Faisal Amir
252336d95c
Merge pull request #6731 from menloresearch/chore/update-change
chore: wrong version in detail changelog
2025-10-03 23:28:25 +07:00
Faisal Amir
1d620df625
Merge pull request #6730 from menloresearch/release/docs-0.7.1
changelog: release 0.7.1
2025-10-03 23:27:22 +07:00
Faisal Amir
e346b293f6 chore: wrong version in detail changelog 2025-10-03 23:23:46 +07:00
Faisal Amir
8b448d1c0b changelog: release 0.7.1 2025-10-03 23:17:54 +07:00
Vanalite
b628b3d9ab fix: Fix tests in threads with proper mock folder properly 2025-10-03 14:17:59 +07:00
Louis
cef351bfd0
fix: Local API Server - disable settings on run (#6707) 2025-10-03 14:12:16 +07:00
Dinh Long Nguyen
5adaf62975
fix: extensions missing on Unix dev (#6724)
* fix: extensions missing on Unix dev

* re add bun uv for mcp
2025-10-03 13:54:37 +07:00
Nguyen Ngoc Minh
c797283409
Merge pull request #6723 from menloresearch/ci/remove-upload-msi
ci: remove upload msi
2025-10-03 05:00:03 +00:00
Minh141120
c4af638a17 ci: remove upload msi 2025-10-03 11:56:31 +07:00
Vanalite
4da0fd1ca3 fix: yarn lint 2025-10-03 10:25:41 +07:00
Nghia Doan
bdd8549d3e
Merge pull request #6715 from menloresearch/fix/get-model-capabilities-correctly
fix: Extract model capabilities correctly for various providers on various platforms
2025-10-02 23:16:22 +07:00
Vanalite
24ff36d424 fix: Extract model capabilities correctly for various providers on various platforms 2025-10-02 21:48:07 +07:00
Vanalite
524ac11294 feat: better structure for MobileCoreService
MobileCoreService should inherit TauriCoreService to match Tauri architecture patterns
2025-10-02 21:20:07 +07:00
Vanalite
1747e0ad41 Merge remote-tracking branch 'origin/dev' into mobile/persistence_store
# Conflicts:
#	src-tauri/src/core/extensions/commands.rs
2025-10-02 20:59:34 +07:00
Vanalite
08d527366e feat: organize code for proper import
Move platform checker for db access to helper
Add test for to threads controller
2025-10-02 20:53:46 +07:00
Faisal Amir
70c6582a58
Merge pull request #6708 from menloresearch/changelog/v0.7.0
docs: add Jan v0.7.0 changelog
2025-10-02 20:19:55 +07:00
Vanalite
9720ad368e feat: use sql for mobile storage 2025-10-02 18:09:33 +07:00
eckartal
d3b4144c5b docs: rename changelog file to remove trailing dash 2025-10-02 17:38:09 +08:00
eckartal
e6f366d373 docs: update Jan v0.7.0 changelog content 2025-10-02 16:55:08 +08:00
eckartal
4fbc7873ca docs: add Jan v0.7.0 changelog 2025-10-02 16:48:07 +08:00
Nguyen Ngoc Minh
f537429d2c
Merge pull request #6706 from menloresearch/qa/v0.7.0
feat: update checklist for 0.7.0
2025-10-02 08:30:30 +00:00
Minh141120
f6f9813ef2 feat: update checklist for 0.7.0 2025-10-02 15:26:37 +07:00
Roushan Kumar Singh
eccaa282e0
refactor: resolve rust analyzer warnings and improve code quality (#6696)
- Update string formatting to use modern interpolation syntax
- Simplify expressions and remove unnecessary intermediate variables
- Improve logging statements for better readability
- Clean up code across core modules (app, downloads, mcp, server, etc.)
2025-10-02 15:01:06 +07:00
Nghia Doan
87db633b7d
Merge pull request #6700 from menloresearch/fix/edit-model-name
fix: Fix editing model without saving should restore original name
# Conflicts:
#	web-app/src/containers/__tests__/EditModel.test.tsx
2025-10-02 09:28:50 +07:00
Nghia Doan
ab2bc11465
Merge pull request #6700 from menloresearch/fix/edit-model-name
fix: Fix editing model without saving should restore original name
2025-10-02 08:58:48 +07:00
Dinh Long Nguyen
df145d63a9
fix gg tag (#6702) 2025-10-02 00:47:38 +07:00
Nguyen Ngoc Minh
8e10f27cc2
Merge pull request #6701 from menloresearch/cherry-pick/projects
cherry pick : projects + performance enhancement
2025-10-01 16:42:20 +00:00
Dinh Long Nguyen
9f72debc17 fix: thread item overfetching (#6699)
* fix: thread item overfetching

* chore: cleanup left over import
2025-10-01 22:53:53 +07:00
Dinh Long Nguyen
1b9efee52c feat: improve projects (#6698)
* decouple successfully

* only show movable projects for project items

* handle delete covnersations when projects is removed

* fix leftpanel assignemtn

* fix lint
2025-10-01 22:53:34 +07:00
Dinh Long Nguyen
d5110de67b
feat: improve projects (#6698)
* decouple successfully

* only show movable projects for project items

* handle delete covnersations when projects is removed

* fix leftpanel assignemtn

* fix lint
2025-10-01 22:47:38 +07:00
Dinh Long Nguyen
870c12af9b
fix: thread item overfetching (#6699)
* fix: thread item overfetching

* chore: cleanup left over import
2025-10-01 22:47:27 +07:00
Vanalite
fb8b61c567 fix: Fix editing model without saving should restore original name 2025-10-01 22:47:03 +07:00
Akarshan Biswas
0f0ba43b7f
feat: Adjust RAM/VRAM calculation for unified memory systems (#6687)
* feat: Adjust RAM/VRAM calculation for unified memory systems

This commit refactors the logic for calculating **total RAM** and **total VRAM** in `is_model_supported` and `plan_model_load` commands, specifically targeting systems with **unified memory** (like modern macOS devices where the GPU list may be empty).

The changes are as follows:

* **Total RAM Calculation:** If no GPUs are detected (`sys_info.gpus.is_empty()` is true), **total RAM** is now set to $0$. This avoids confusing total system memory with dedicated GPU memory when planning model placement.
* **Total VRAM Calculation:** If no GPUs are detected, **total VRAM** is still calculated as the system's **total memory (RAM)**, as this shared memory acts as VRAM on unified memory architectures.

This adjustment improves the accuracy of memory availability checks and model planning on unified memory systems.

* fix: total usable memory in case there is no system vram reported

* chore: temporarily change to self-hosted runner mac

* ci: revert back to github hosted runner macos

---------

Co-authored-by: Louis <louis@jan.ai>
Co-authored-by: Minh141120 <minh.itptit@gmail.com>
2025-10-01 18:58:14 +07:00
Nguyen Ngoc Minh
6a4aaaec87
Merge pull request #6694 from menloresearch/ci/revert-msi-installer
ci: revert upload msi to github release
2025-10-01 10:30:55 +00:00
Minh141120
a5574eaacb ci: revert upload msi to github release 2025-10-01 17:00:03 +07:00
Roushan Kumar Singh
247db95bad
resolve TypeScript and Rust warnings (#6612)
* chore: fix warnings

* fix: add missing scrollContainerRef dependencies to React hooks

* fix: typo

* fix: remove unsupported fetch option and enable AsyncIterable types

- Removed `connectTimeout` from fetch init (not supported in RequestInit)
- Updated tsconfig to target ES2018

* chore: refactor rename

* fix(hooks): update dependency arrays for useThreadScrolling effects

* Add type.d.ts to extend requestinit with connectionTimeout

* remove commentd unused import
2025-10-01 16:06:41 +07:00
Faisal Amir
771d097309
Merge pull request #6688 from menloresearch/fix/dropdown-type-assistant 2025-10-01 14:47:54 +07:00
Louis
157ecacb20
fix: chat completion usage - token speed (#6675) 2025-10-01 14:19:21 +07:00
Louis
e0ab77cb24
fix: token count error (#6680) 2025-10-01 14:07:32 +07:00
Faisal Amir
7a36ed238c
Merge pull request #6681 from menloresearch/fix/local-api-server
fix: local api server auto start first model when last used missing
2025-10-01 14:01:22 +07:00
Faisal Amir
99d1713517 fix: dropdown type assistant 2025-10-01 14:00:55 +07:00
Faisal Amir
d102165028 chore: move auto start server setting 2025-10-01 11:44:49 +07:00
Faisal Amir
199623b414 chore: clear flow loacl api server 2025-10-01 11:23:59 +07:00
Faisal Amir
2679b19e32 fix: local api server auto start first model when missing last used 2025-10-01 11:04:28 +07:00
Nghia Doan
0de5f17071
Merge pull request #6657 from menloresearch/mobile/dev
Feat: Jan has mobile MVP
2025-10-01 09:56:30 +07:00
Vanalite
262a1a9544 Merge remote-tracking branch 'origin/dev' into mobile/dev
# Conflicts:
#	src-tauri/src/core/setup.rs
#	src-tauri/src/lib.rs
#	web-app/src/hooks/useChat.ts
2025-10-01 09:52:01 +07:00
Dinh Long Nguyen
4cb3c46f89
feat: disable all web mcp by default (new users) (#6677) 2025-10-01 09:35:09 +07:00
Dinh Long Nguyen
46d55030f0
Merge pull request #6674 from menloresearch/feat/sync-release=to-dev 2025-09-30 23:18:22 +07:00
Dinh Long Nguyen
9a72a2d5d5 fix tauri test 2025-09-30 22:43:14 +07:00
Nghia Doan
c5a5968bf8
Merge pull request #6643 from menloresearch/fix/model-name-change
fix: Apply model name change correctly
2025-09-30 22:41:05 +07:00
Dinh Long Nguyen
d50226b4dd add missing closing test 2025-09-30 22:36:52 +07:00
Dinh Long Nguyen
817680565e remove test conflict 2025-09-30 22:33:51 +07:00
Dinh Long Nguyen
84f46dc997
Merge branch 'dev' into feat/sync-release=to-dev 2025-09-30 22:31:20 +07:00
Louis
3c7eb64353
fix: mcp bin path (#6667)
* fix: mcp bin path

* chore: clean up unused structs

* fix: bin name

* fix: tests
2025-09-30 22:29:15 +07:00
Dinh Long Nguyen
191e6f9714 fix lint issue 2025-09-30 22:24:31 +07:00
Dinh Long Nguyen
e6bc1182a6
Merge branch 'dev' into feat/sync-release=to-dev 2025-09-30 22:04:27 +07:00
Dinh Long Nguyen
82d29e7a7d
add eof new line missing (#6673) 2025-09-30 21:48:38 +07:00
Dinh Long Nguyen
f33c2c205a
feat: web add search button for extension (#6671)
* add search button for web extension

* change button color and behavior

* Update extensions-web/src/mcp-web/components/WebSearchButton.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-30 21:39:08 +07:00
Nguyen Ngoc Minh
7eacee26d0
Merge pull request #6670 from menloresearch/ci/upload-msi-to-release
ci: add upload msi installer for windows
2025-09-30 21:15:34 +07:00
Minh141120
631a95e018 ci: add upload msi installer for windows 2025-09-30 20:12:53 +07:00
Nguyen Ngoc Minh
f7be59e99c
Merge pull request #6668 from menloresearch/feat/add-msi-installer
feat: add msi installer
2025-09-30 17:39:32 +07:00
Vanalite
6bd623c020 fix: Fix cargo test 2025-09-30 17:19:58 +07:00
Vanalite
a62852f384 fix: Restore default permission on desktop build
Restore desktop capabilities
Restore linter correctness
Restore different capabilities on each platform
2025-09-30 17:01:09 +07:00
Minh141120
508cbe16f8 refactor: remove redundant resource 2025-09-30 15:49:14 +07:00
Minh141120
dcb511023d ci: add upload .msi artifact 2025-09-30 15:41:04 +07:00
Vanalite
4718203960 fix: Fix linter and tests 2025-09-30 15:39:45 +07:00
Faisal Amir
b3fc64049a
Merge pull request #6666 from menloresearch/content/emre
Content/emre
2025-09-30 15:35:43 +07:00
Minh141120
0b8f3e01fb feat: add msi installer for windows 2025-09-30 15:32:29 +07:00
eckartal
2a9166c9f8 Add AI for Teachers blog post with images and video
- Create comprehensive AI for Teachers blog post
- Add hero image and assistant creation interface images
- Include video demonstration of Jan for teachers
- Add proper ogImage and twitter image references
- Cover lesson planning, grading, parent communication, and classroom resources
- Focus on privacy and offline AI for educational use
2025-09-30 16:16:40 +08:00
Vanalite
43d20e2a32 fix: revert the modification of vulkan 2025-09-30 14:50:54 +07:00
eckartal
6c0fa46784 Update AI for Law blog post with images and content improvements
- Add hero image for AI for Law blog post
- Add images to assistant creation and contract review sections
- Improve content structure and readability
- Add proper image assets for legal AI use cases
- Update ogImage and twitter image references
2025-09-30 15:05:23 +08:00
Louis
de9c04474e
fix: should not allow duplicating model (#6658) 2025-09-30 13:59:17 +07:00
Faisal Amir
c3184bd233
Merge pull request #6654 from menloresearch/content/emre
Emre to improve SEO
2025-09-30 13:54:00 +07:00
Faisal Amir
334b160012
Merge pull request #6656 from menloresearch/fix/thinking-block
fix: remove thinking tag on projects list message history
2025-09-30 13:48:34 +07:00
Nguyen Ngoc Minh
04fcd788a3
Merge pull request #6659 from menloresearch/fix/6626
fix: Improve KV cache estimation robustness
2025-09-30 13:42:28 +07:00
Nguyen Ngoc Minh
a3fcd28c12
Merge pull request #6665 from menloresearch/docs/update-redirect
docs: update redirect links
2025-09-30 13:32:43 +07:00
Nguyen Ngoc Minh
cb02809ffb
docs: update redirect links 2025-09-30 13:26:54 +07:00
Akarshan
34b254e2d8
fix: Improve KV cache estimation robustness
The KV cache size calculation in estimate_kv_cache_internal now includes a fallback mechanism for models that do not explicitly define key_length and value_length in the GGUF metadata.

If these attention keys are missing, the head dimension (and thus key/value length) is calculated using the formula embedding_length / total_heads. This improves robustness and compatibility with GGUF models that don't have the proper keys in metadata.

Also adds logging of the full model metadata for easier debugging of the estimation process.
2025-09-30 11:14:18 +05:30
Nguyen Ngoc Minh
d315522c5a
Merge pull request #6618 from github-roushan/show-supported-files
Show supported files
2025-09-30 12:19:22 +07:00
eckartal
a300a46707 Add Guides category to blog navigation
- Add 'guides' category to staticCategories array in Blog component
- Update plopfile.js to include guides in category choices
- Add guides category entry to _meta.json
- Position guides category after research in navigation
2025-09-30 12:49:20 +08:00
Vanalite
c53d8c09c4 Merge remote-tracking branch 'origin/dev' into mobile/dev
# Conflicts:
#	web-app/src/containers/HeaderPage.tsx
#	web-app/src/lib/platform/const.ts
#	web-app/src/routes/index.tsx
2025-09-30 11:21:36 +07:00
Faisal Amir
1c9890649d fix: remove thinking tag on projects list message history 2025-09-30 11:08:31 +07:00
Nghia Doan
3cbf348585
Merge pull request #6642 from menloresearch/fix/toast-text-selection-disable
feat: Disable text selection on Toaster
2025-09-30 11:01:31 +07:00
Dinh Long Nguyen
2101242530
Feat: web temporary chat (#6650)
* temporray chat stage1

* temporary page in root

* temporary chat

* handle redirection properly
`

* temporary chat header

* Update extensions-web/src/conversational-web/extension.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* update routetree

* better error handling

* fix strecthed assitant on desktop

* update yarn link to workspace for better link consistency

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-30 10:42:21 +07:00
eckartal
f718b0f96b Merge branch 'dev' of https://github.com/menloresearch/jan into content/emre 2025-09-30 11:32:49 +08:00
Faisal Amir
ccf378f2c6
Merge pull request #6653 from menloresearch/fix/blog-titles-remove-jan-prefix
fix: remove Jan prefix from blog post titles for better SEO
2025-09-30 10:31:05 +07:00
eckartal
e3e809753c update blog post content 2025-09-30 11:28:36 +08:00
eckartal
8b9aca27bf fix: remove Jan prefix from blog post titles for better SEO
- Blog posts now use only frontmatter title without 'Jan -' prefix
- Other pages maintain existing branding (Jan Desktop, Jan Server, Jan)
- Improves SEO for blog content while preserving site branding
2025-09-30 11:25:45 +08:00
Faisal Amir
e6d34623b0
Merge pull request #6652 from menloresearch/emre/og-images-fix
Fix OG image paths and move images to general folder
2025-09-30 10:16:21 +07:00
eckartal
b69330ffca Fix OG image paths and move images to general folder
- Move OG images from _assets/ to public/assets/images/general/
- Update all blog post references to use correct paths
- Remove duplicate images from _assets/ folder
- Fix image paths in content to use /assets/images/general/ format
- Update Twitter image references to match OG image paths

Files updated:
- chatgpt-alternatives.mdx
- deepresearch.mdx
- deepseek-r1-locally.mdx
- how-we-benchmark-kernels.mdx
- is-chatgpt-down-use-jan.mdx
- offline-chatgpt-alternative.mdx
- qwen3-settings.mdx
- run-ai-models-locally.mdx
- run-gpt-oss-locally.mdx
2025-09-30 11:06:23 +08:00
Vanalite
549c962248 fix: Fix nvidia and vulkan after upgrade to be compatible with mobile compiling too 2025-09-30 09:44:21 +07:00
Louis
54d17c9c72
fix: migrate new mcp server config (#6651) 2025-09-30 00:07:57 +07:00
Vanalite
5e57caee43 Merge remote-tracking branch 'origin/dev' into mobile/dev
# Conflicts:
#	extensions/yarn.lock
#	package.json
#	src-tauri/plugins/tauri-plugin-hardware/src/vendor/vulkan.rs
#	src-tauri/src/lib.rs
#	yarn.lock
2025-09-29 22:22:00 +07:00
Nghia Doan
70ac13e536
Merge pull request #6643 from menloresearch/fix/model-name-change
fix: Apply model name change correctly
2025-09-29 22:15:13 +07:00
Louis
eb79642863
fix: unhandled model load error (#6648) 2025-09-29 21:52:39 +07:00
Vanalite
b062e6840a fix: Fix linter error 2025-09-29 19:59:53 +07:00
Vanalite
987063fede feat: Add tests for the model displayName modification 2025-09-29 17:59:15 +07:00
Louis
5fd249c72d
refactor: deprecate Vulkan external binaries (#6638)
* refactor: deprecate vulkan binary

refactor: clean up vulkan lib

chore: cleanup

chore: clean up

chore: clean up

fix: build

* fix: skip binaries download env

* Update src-tauri/utils/src/system.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src-tauri/utils/src/system.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-29 17:47:59 +07:00
Faisal Amir
3c4c6d1c50
Merge pull request #6633 from menloresearch/emre/content
Emre to update & create content
2025-09-29 17:32:22 +07:00
Dinh Long Nguyen
cf8ada5e8e
fix: scroll issue padding not re render correctly (#6639) (#6644) 2025-09-29 17:27:26 +07:00
Faisal Amir
e8666ee5ec chore: fix failed build 2025-09-29 17:21:53 +07:00
Faisal Amir
e065e56f5c chore: fix typo 2025-09-29 17:16:31 +07:00
eckartal
e09c1f0316 feat: add real-time ChatGPT status checker blog post
- Add new blog post: 'is-chatgpt-down-use-jan'
- Create OpenAIStatusChecker React component with real-time data
- Use CORS proxy to fetch live OpenAI status from status.openai.com
- Include SEO-optimized status indicators and error messages
- Add ChatGPT downtime promotion for Jan alternative
- Component features: auto-refresh, fallback handling, dark mode support
2025-09-29 17:15:35 +07:00
eckartal
13aa72a51f Rename blog post from chatgpt-alternative-jan.mdx to chatgpt-alternatives.mdx 2025-09-29 17:15:35 +07:00
eckartal
38ed873de0 Update ChatGPT alternative blog post 2025-09-29 17:15:35 +07:00
eckartal
a9737a1541 Add ChatGPT alternative blog post and update installation docs 2025-09-29 17:15:33 +07:00
eckartal
7f002409e3 Update content files
- Update tabby server example
- Update troubleshooting documentation
- Update NVIDIA TensorRT-LLM benchmarking post
2025-09-29 17:15:15 +07:00
eckartal
0ac667d99c Add SEO-optimized Twitter meta titles for installation pages
- Add Twitter meta tags to Windows, Linux, and Mac installation pages
- Optimize meta titles: 'Jan on [Platform]' for better SEO
- Maintain consistent meta descriptions across all platforms
- Keep original page titles unchanged for user experience
2025-09-29 17:15:15 +07:00
eckartal
4166b93e75 Improve FAQ section and content updates for offline ChatGPT alternative post 2025-09-29 17:15:15 +07:00
eckartal
dda46f30c2 trigger PR banner 2025-09-29 17:15:15 +07:00
Dinh Long Nguyen
0dbf3b1652 fix: scroll issue padding not re render correctly (#6639) 2025-09-29 17:11:08 +07:00
Nghia Doan
1504533246
Merge pull request #6642 from menloresearch/fix/toast-text-selection-disable
feat: Disable text selection on Toaster
2025-09-29 16:48:58 +07:00
Dinh Long Nguyen
f2a3861410
fix: scroll issue padding not re render correctly (#6639) 2025-09-29 16:45:40 +07:00
Vanalite
a5eb7ea894 feat: Disable text selection on Toaster
Disable the option to select text on the Toaster to consist the swiping action on the toast in order to dismiss it
2025-09-29 16:41:08 +07:00
Vanalite
03ee9c14a3 fix: Apply model name change correctly
# Conflicts:
#	web-app/src/lib/utils.ts
2025-09-29 16:39:32 +07:00
Faisal Amir
75dee86375
Merge pull request #6640 from menloresearch/enhancement/social-media-web
enhancement: social media navbar and update menu footer
2025-09-29 15:23:27 +07:00
Faisal Amir
ed661bf4a3
Update docs/src/components/Navbar.tsx
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-29 15:21:57 +07:00
Faisal Amir
103681ef98
Update docs/src/components/Navbar.tsx
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-29 15:21:51 +07:00
Faisal Amir
f73e1c4618 enhancement: social media navbar and update menu footer 2025-09-29 15:18:03 +07:00
Faisal Amir
0cf1b830cf
Merge pull request #6636 from menloresearch/chore/projects-ux 2025-09-29 15:05:28 +07:00
Faisal Amir
b4df56e0d8 chore: placement menu leftpanel, and ux create add projects 2025-09-29 13:44:56 +07:00
Nguyen Ngoc Minh
4d5cc0033a
Merge pull request #6634 from menloresearch/docs/update-missing-redirects
docs: update missing redirect links
2025-09-28 23:28:17 -07:00
Minh141120
a3153ee4cd docs: update missing redirect links 2025-09-29 13:23:48 +07:00
Nguyen Ngoc Minh
5403e58681
Merge pull request #6618 from github-roushan/show-supported-files
Show supported files
2025-09-29 03:17:39 +00:00
Louis
311b79fe13
fix: thread rerender due to thread scrolling padding subscription (#6629) 2025-09-28 22:36:05 +07:00
Roushan Kumar Singh
86c7496a70
Merge branch 'dev' into show-supported-files 2025-09-27 11:20:37 +05:30
Faisal Amir
abb0da491b
Merge pull request #6562 from menloresearch/emre/docsv2
Update handbook content with Nextra callout and content improvements
2025-09-26 22:13:28 +07:00
eckartal
97cb7c45a5 trigger PR banner 2025-09-26 21:23:20 +07:00
Emre Can Kartal
183645c637 Update README.md 2025-09-26 21:23:20 +07:00
Emre Can Kartal
12012232ac Update README.md 2025-09-26 21:23:20 +07:00
eckartal
03a53cbed3 Clean up installation page titles and descriptions
- Revert titles to clean sidebar navigation (Mac, Linux, Windows)
- Improve meta descriptions to be concise but SEO-friendly
- Keep key terms: local AI, offline, GPU acceleration, platform details
2025-09-26 21:23:20 +07:00
eckartal
bfbd198202 Optimize installation pages SEO meta titles and descriptions
 SEO Improvements:
- Mac: 'Run AI models locally on your Mac - Jan'
- Linux: 'Run AI models locally on Linux - Jan'
- Windows: 'Run AI models locally on Windows - Jan'

🎯 Meta descriptions now include:
- Target keywords (local AI, LLM, offline, ChatGPT-like)
- Platform-specific details (Apple Silicon, Ubuntu/Debian, Windows 10/11)
- Key benefits (GPU acceleration, privacy, no internet required)

📍 Sidebar navigation titles unchanged - only SEO meta data optimized
2025-09-26 21:23:20 +07:00
eckartal
ae171574e8 docs: fix broken internal links and remove privacy page
- Fix broken links in troubleshooting.mdx pointing to install pages
- Remove privacy.mdx page and update _meta.json navigation
- Update various documentation links for consistency
- Ensure all internal links use proper absolute paths
2025-09-26 21:23:17 +07:00
eckartal
da38384be2 Update handbook navigation structure and meta.json files
- Updated handbook/_meta.json to properly organize navigation
- Fixed duplicate entries by removing files that belong in subfolders
- Updated why folder title to 'Why does Jan exist?'
- Cleaned up why/_meta.json with proper titles for Open Superintelligence and Open-Source sections
2025-09-26 21:22:52 +07:00
eckartal
220cb3ae0a docs: enhance overview page with improved structure and internal linking
- Restructured main content with cleaner formatting
- Added comprehensive internal linking for better navigation
- Improved visual hierarchy and readability
- Enhanced acknowledgements section with better organization
- Updated product suite section with consistent formatting
2025-09-26 21:22:49 +07:00
eckartal
d47a3efe89 Update handbook content with Nextra callout and content improvements
- Convert blockquote to Nextra callout in open-superintelligence.mdx
- Add Edison link and improve content flow
- Refine language for better clarity
2025-09-26 21:22:35 +07:00
Roushan Singh
0c5ccea9d4 chore: add logging for TauriDialog Service 2025-09-26 16:04:34 +05:30
Roushan Singh
c091b8cd77 refactor: safely strip prefix and extensions from filename 2025-09-26 15:02:23 +05:30
Roushan Singh
7d6e0c22ac chore: fix Encoded logging 2025-09-26 15:02:23 +05:30
Roushan Singh
c6be66e595 refactor(utils): add helper to remove extensions from file paths 2025-09-26 15:02:23 +05:30
Dinh Long Nguyen
b422970369
feat: scrolling behaves like chatgpt with padding (#6598)
* scroll like chatgpt with padding

* minor refactor
2025-09-26 15:53:05 +07:00
Faisal Amir
580bdc511a
Merge pull request #6616 from menloresearch/chore/projects
chore: update project page title too long
2025-09-26 15:47:35 +07:00
Nguyen Ngoc Minh
191c0eec83
Merge pull request #6617 from menloresearch/docs/update-redirect-links
docs: update redirect links
2025-09-26 08:39:42 +00:00
Minh141120
eeaaf5ce0d chore: remove duplicate links 2025-09-26 15:29:08 +07:00
Minh141120
1dd9adf8d4 docs: update redirect links 2025-09-26 15:25:59 +07:00
Faisal Amir
b7dae19756
feat: custom downloaded model name (#6588)
* feat: add field edit model name

* fix: update model

* chore: updaet UI form with save button, and handle edit capabilities and  rename folder will need save button

* fix: relocate model

* chore: update and refresh list model provider also update test case

* chore: state loader

* fix: model path

* fix: model config update

* chore: fix remove depencies provider on edit model dialog

* chore: avoid shifted model name or id

---------

Co-authored-by: Louis <louis@jan.ai>
2025-09-26 15:25:44 +07:00
Faisal Amir
3d224f8cff chore: update project page title too long 2025-09-26 14:59:38 +07:00
Nguyen Ngoc Minh
453df559b5
Merge pull request #6615 from menloresearch/docs/update-redirect-list
docs: update redirect list
2025-09-26 07:28:56 +00:00
Minh141120
39e3a02b3e docs: update redirect list 2025-09-26 14:24:06 +07:00
Faisal Amir
ea124f7fd4
Merge pull request #6614 from menloresearch/enhancement/jan-web
enhancement: update statistic number jan web
2025-09-26 14:23:20 +07:00
Faisal Amir
d1c8cd2dc9 chore: update link target banner announcement 2025-09-26 14:11:47 +07:00
Faisal Amir
c12bef55e9 enhancement: update statistic number jan web 2025-09-26 14:00:31 +07:00
Dinh Long Nguyen
1bbea4b30f
models and cookies invalidation (#6613) 2025-09-26 13:50:10 +07:00
Faisal Amir
39aa1c4f7e
Merge pull request #6607 from menloresearch/fix/projects-left-panel-title
fix: projects title long name
2025-09-26 13:20:54 +07:00
Nguyen Ngoc Minh
32df9fda0f
Merge pull request #6611 from menloresearch/refactor/remove-mise
refactor: remove mise
2025-09-26 06:17:28 +00:00
Louis
55c42ba526
fix: lock all of the dependencies (#6561)
* fix: pin web app dependencies

* fix: pin extension versions

* fix: pin extensions-web dependencies

* fix: pin extensions lockfile

* fix: remove unnecessary semicolon
2025-09-26 13:07:29 +07:00
Minh141120
cc218b1b40 chore: revert cargo lock file 2025-09-26 12:49:26 +07:00
Minh141120
fb9bbb66b0 refactor: remove mise 2025-09-26 12:42:01 +07:00
Nghia Doan
ba3e49928d
Merge pull request #6610 from menloresearch/mobile/add-make-android
feat: Add make commands for ios and android development
2025-09-26 12:20:30 +07:00
Vanalite
e8cac2823f feat: Add dev-ios to makefile for ios development 2025-09-26 11:59:50 +07:00
Vanalite
b0ad2a6b7a feat: Add dev-android to makefile 2025-09-26 11:53:14 +07:00
Vanalite
a0aa0074f4 Merge remote-tracking branch 'origin/dev' into mobile/dev
# Conflicts:
#	web-app/src/routeTree.gen.ts
#	web-app/src/routes/index.tsx
2025-09-26 11:09:50 +07:00
Nghia Doan
c4228855b5
Merge pull request #6608 from menloresearch/mobile/remove-hardware-plugin
Feat: Split different build configuration among different platforms
2025-09-26 10:59:32 +07:00
Faisal Amir
0a82fdd784 fix: projects title long name 2025-09-26 10:06:42 +07:00
Vanalite
fdf9f40aef fix: Android releasable build 2025-09-26 09:42:00 +07:00
Nguyen Ngoc Minh
75396dbd06
Merge pull request #6600 from menloresearch/docs/update-redirects
docs: update redirects
2025-09-25 13:57:09 +00:00
Minh141120
20c8991f55 docs: update redirects 2025-09-25 20:53:43 +07:00
Faisal Amir
d806c4719e
Merge pull request #6586 from menloresearch/feat/thread-project-org
feat: thread organization folder
2025-09-25 20:21:02 +07:00
Nguyen Ngoc Minh
978565e7f0
Merge pull request #6599 from menloresearch/docs/add-redirect
docs: add redirects
2025-09-25 11:48:10 +00:00
Minh141120
9fb3171d82 docs: remove duplicate redirect url 2025-09-25 18:21:31 +07:00
Minh141120
9923c6028e docs: add redirects 2025-09-25 18:10:58 +07:00
Faisal Amir
d690e0fa87 chore: max height project list on left panel 2025-09-25 17:29:38 +07:00
Low Keng Hoong, Warren
0fb6413368
Merge pull request #6596 from menloresearch/feat/kernel-benchmarking
feat: Add kernel benchmarking blogpost
2025-09-25 18:28:54 +08:00
Faisal Amir
a8b9e1f147 chore: fix navigartion thread from project 2025-09-25 16:24:55 +07:00
DESU CLUB
374a1f9771 feat: Fix image links 2025-09-25 17:10:59 +08:00
DESU CLUB
97af43cadb feat: Fix image links 2025-09-25 17:05:40 +08:00
DESU CLUB
2aead28c9b feat: Add kernel benchmarking blogpost 2025-09-25 16:58:27 +08:00
Akarshan Biswas
11b3a60675
fix: refactor, fix and move gguf support utilities to backend (#6584)
* feat: move estimateKVCacheSize to BE

* feat: Migrate model planning to backend

This commit migrates the model load planning logic from the frontend to the Tauri backend. This refactors the `planModelLoad` and `isModelSupported` methods into the `tauri-plugin-llamacpp` plugin, making them directly callable from the Rust core.

The model planning now incorporates a more robust and accurate memory estimation, considering both VRAM and system RAM, and introduces a `batch_size` parameter to the model plan.

**Key changes:**

- **Moved `planModelLoad` to `tauri-plugin-llamacpp`:** The core logic for determining GPU layers, context length, and memory offloading is now in Rust for better performance and accuracy.
- **Moved `isModelSupported` to `tauri-plugin-llamacpp`:** The model support check is also now handled by the backend.
- **Removed `getChatClient` from `AIEngine`:** This optional method was not implemented and has been removed from the abstract class.
- **Improved KV Cache estimation:** The `estimate_kv_cache_internal` function in Rust now accounts for `attention.key_length` and `attention.value_length` if available, and considers sliding window attention for more precise estimates.
- **Introduced `batch_size` in ModelPlan:** The model plan now includes a `batch_size` property, which will be automatically adjusted based on the determined `ModelMode` (e.g., lower for CPU/Hybrid modes).
- **Updated `llamacpp-extension`:** The frontend extension now calls the new Tauri commands for model planning and support checks.
- **Removed `batch_size` from `llamacpp-extension/settings.json`:** The batch size is now dynamically determined by the planning logic and will be set as a model setting directly.
- **Updated `ModelSetting` and `useModelProvider` hooks:** These now handle the new `batch_size` property in model settings.
- **Added new Tauri commands and permissions:** `get_model_size`, `is_model_supported`, and `plan_model_load` are new commands with corresponding permissions.
- **Consolidated `ModelSupportStatus` and `KVCacheEstimate`:** These types are now defined in `src/tauri/plugins/tauri-plugin-llamacpp/src/gguf/types.rs`.

This refactoring centralizes critical model resource management logic, improving consistency and maintainability, and lays the groundwork for more sophisticated model loading strategies.

* feat: refine model planner to handle more memory scenarios

This commit introduces several improvements to the `plan_model_load` function, enhancing its ability to determine a suitable model loading strategy based on system memory constraints. Specifically, it includes:

-   **VRAM calculation improvements:**  Corrects the calculation of total VRAM by iterating over GPUs and multiplying by 1024*1024, improving accuracy.
-   **Hybrid plan optimization:**  Implements a more robust hybrid plan strategy, iterating through GPU layer configurations to find the highest possible GPU usage while remaining within VRAM limits.
-   **Minimum context length enforcement:** Enforces a minimum context length for the model, ensuring that the model can be loaded and used effectively.
-   **Fallback to CPU mode:** If a hybrid plan isn't feasible, it now correctly falls back to a CPU-only mode.
-   **Improved logging:** Enhanced logging to provide more detailed information about the memory planning process, including VRAM, RAM, and GPU layers.
-   **Batch size adjustment:** Updated batch size based on the selected mode, ensuring efficient utilization of available resources.
-   **Error handling and edge cases:**  Improved error handling and edge case management to prevent unexpected failures.
-   **Constants:** Added constants for easier maintenance and understanding.
-   **Power-of-2 adjustment:** Added power of 2 adjustment for max context length to ensure correct sizing for the LLM.

These changes improve the reliability and robustness of the model planning process, allowing it to handle a wider range of hardware configurations and model sizes.

* Add log for raw GPU info from tauri-plugin-hardware

* chore: update linux runner for tauri build

* feat: Improve GPU memory calculation for unified memory

This commit improves the logic for calculating usable VRAM, particularly for systems with **unified memory** like Apple Silicon. Previously, the application would report 0 total VRAM if no dedicated GPUs were found, leading to incorrect calculations and failed model loads.

This change modifies the VRAM calculation to fall back to the total system RAM if no discrete GPUs are detected. This is a common and correct approach for unified memory architectures, where the CPU and GPU share the same memory pool.

Additionally, this commit refactors the logic for calculating usable VRAM and RAM to prevent potential underflow by checking if the total memory is greater than the reserved bytes before subtracting. This ensures the calculation remains safe and correct.

* chore: fix update migration version

* fix: enable unified memory support on model support indicator

* Use total_system_memory in bytes

---------

Co-authored-by: Minh141120 <minh.itptit@gmail.com>
Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-09-25 12:17:57 +05:30
Faisal Amir
ba768d46e6 chore: update dialog test case 2025-09-25 13:24:06 +07:00
Louis
7fe58d6bee
fix: allow users cancel backend download (#6582)
* fix: allow users cancel backend download

* fix: should not redownload on cancel
2025-09-25 13:19:14 +07:00
Faisal Amir
8479b7c105 chore: update rename and delete thread from dynamic project screen 2025-09-25 13:12:33 +07:00
Nguyen Ngoc Minh
d994bc8f6a
Merge pull request #6589 from menloresearch/ci/update-package-version-tauri-plugin
ci: update package version for tauri plugin
2025-09-25 12:46:01 +07:00
Minh141120
45590e3188 ci: fix path for tauri plugins 2025-09-25 12:10:51 +07:00
Faisal Amir
e0781677ad
Merge pull request #6590 from menloresearch/enhancement/responsive-footer-web
enhancement: update responsive footer and copy hero section
2025-09-25 11:35:57 +07:00
Faisal Amir
1b120712d4 enhancement: update responsive footer and copy hero section 2025-09-25 11:26:15 +07:00
Minh141120
8205c33176 ci: update package version for tauri plugin 2025-09-25 10:55:10 +07:00
Faisal Amir
b0bca2ac1f
Update web-app/src/routes/project/index.tsx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-09-25 10:19:18 +07:00
Faisal Amir
d0f62fa634 chore: fix missing classname 2025-09-25 10:18:21 +07:00
Faisal Amir
e7a1a06395 feat: thread organization folder 2025-09-25 10:12:08 +07:00
Vanalite
814024982e feat: Experiment removing hardware permission 2025-09-25 00:49:14 +07:00
Nguyen Ngoc Minh
3dcf522224
Merge pull request #6583 from menloresearch/chore/separate-windows-install-script
chore: separate windows install script
2025-09-24 20:12:13 +07:00
Minh141120
23f14ebbb7 fix: window dependencies not downloaded during tests 2025-09-24 19:02:18 +07:00
Minh141120
e322e46e4b chore: separate windows install script 2025-09-24 18:29:03 +07:00
Louis
57110d2bd7
fix: allow users to download the same model from different authors (#6577)
* fix: allow users to download the same model from different authors

* fix: importing models should have author name in the ID

* fix: incorrect model id show

* fix: tests

* fix: default to mmproj f16 instead of bf16

* fix: type

* fix: build error
2025-09-24 17:57:10 +07:00
Nguyen Ngoc Minh
fe05478336
Merge pull request #6578 from menloresearch/feat/windows-installer-cleanup
feat: add cleanup logic for windows installer
2025-09-24 16:12:26 +07:00
Vanalite
b2c5063e0b Merge remote-tracking branch 'origin/dev' into mobile/dev
# Conflicts:
#	src-tauri/src/core/server/proxy.rs
#	src-tauri/tauri.conf.json
#	web-app/src/containers/LeftPanel.tsx
#	web-app/src/containers/__tests__/ChatInput.test.tsx
#	web-app/src/lib/platform/const.ts
#	yarn.lock
2025-09-24 16:01:33 +07:00
Minh141120
9568ff12e8 feat: add cleanup logic for windows installer 2025-09-24 15:47:46 +07:00
Nghia Doan
7780fb3edd
Merge pull request #6549 from menloresearch/enhancement/layout-mobile
enhancement: base layout mobile
2025-09-24 15:08:14 +07:00
Vanalite
6747a0e9e2 Merge branch 'mobile/dev' into enhancement/layout-mobile
# Conflicts:
#	package.json
2025-09-24 15:07:49 +07:00
Vanalite
b8da32c14e fix: Add frontendDist to ios configuration 2025-09-24 14:31:13 +07:00
Nguyen Ngoc Minh
4f7236d72a
Merge pull request #6576 from menloresearch/docs/clean-output-dir
docs: add clean output dir step
2025-09-24 12:16:47 +07:00
Minh141120
91e30d3c19 docs: add clean output dir step 2025-09-24 12:12:41 +07:00
hiento09
4dc55fc43b
chore: fix docs (#6575) 2025-09-24 10:56:01 +07:00
Nguyen Ngoc Minh
0cf2ffd32d
Merge pull request #6574 from menloresearch/docs/add-cache-control
docs: add cache control
2025-09-24 10:40:31 +07:00
Minh141120
db35d045b8 docs: add cache control 2025-09-24 10:35:10 +07:00
Faisal Amir
a8dee4a95d
Merge pull request #6572 from menloresearch/fix/missing-url-in-article
fix: missing url on article
2025-09-24 09:52:46 +07:00
Faisal Amir
5b59c7a18a
Merge pull request #6560 from menloresearch/fix/layout-downlod-management
fix: download management ui and double refresh model
2025-09-24 09:48:42 +07:00
Faisal Amir
78fc5a8184 chore: fix double desktop 2025-09-24 09:48:08 +07:00
Faisal Amir
dc097eaef9 fix: missing url on article 2025-09-24 09:45:27 +07:00
Nguyen Ngoc Minh
4d43841ae3
Merge pull request #6571 from menloresearch/docs/update-redirect-page
docs: update redirect page
2025-09-24 09:01:11 +07:00
Minh141120
8102ca24e5 chore: wipe out _redirects page 2025-09-24 08:56:06 +07:00
Akarshan Biswas
38ad8deae2
feat: normalize LaTeX fragments in markdown rendering (#6488)
* feat: normalize LaTeX fragments in markdown rendering

Added a preprocessing step that converts LaTeX delimiters `\[…\]` to `$$…$$` and `\(...\)` to `$…$` before rendering. The function skips code blocks, inline code, and HTML tags to avoid unintended transformations. This improves authoring experience by supporting common LaTeX syntax without requiring explicit `$` delimiters.

* fix: correct inline LaTeX normalization replacement

The replacement function for inline math (`\(...\)`) incorrectly accepted a fourth
parameter (`post`) and appended it to the result, which could introduce stray
characters or `undefined` into the rendered output. Updated the function to
use only the captured prefix and inner content and removed the extraneous
`${post}` interpolation, ensuring clean LaTeX conversion.

* feat: optimize markdown rendering with LaTeX caching and memoized code blocks

- Added cache to normalizeLatex to avoid reprocessing repeated content
- Introduced CodeComponent with stable IDs and memoization to reduce re-renders
- Replaced per-render code block ID mapping with hash-based IDs
- Memoized copy handler and normalized markdown content
- Simplified plugin/component setup with stable references
- Added custom comparison for RenderMarkdown memoization to prevent unnecessary updates

* refactor: memoize content only

---------

Co-authored-by: Louis <louis@jan.ai>
2025-09-24 07:19:32 +05:30
Minh141120
1c1993fbd7 docs: update redirect page 2025-09-24 08:44:37 +07:00
Nguyen Ngoc Minh
c46e13b8b1
Merge pull request #6545 from menloresearch/chore/standardize-build-windows
chore: use default nsis template
2025-09-23 22:23:17 +07:00
Minh141120
8ba0342337 chore: update download folder to libDir 2025-09-23 21:14:49 +07:00
Dinh Long Nguyen
b322c7649b
Merge pull request #6563 from menloresearch/feat/web-minor-ui-tweak-login
feat: tweak login UI
2025-09-23 21:09:58 +07:00
Minh141120
f1d97ac834 chore: install vc_redist.x64 from script 2025-09-23 20:42:34 +07:00
Faisal Amir
3a5580c725 chore: update test case 2025-09-23 20:25:05 +07:00
Faisal Amir
d3fff154d4 fix: download management ui and double refresh model 2025-09-23 20:17:51 +07:00
Roushan Kumar Singh
3f51c35229
feat: support .zip archives for manual backend install (#6534)
* feat(llamacpp): support .zip archives for manual backend install

* Update Lock Files
2025-09-23 18:02:06 +05:30
Minh141120
2a905c6c02 ci: standardize nightly external build on windows 2025-09-23 19:00:39 +07:00
Minh141120
7a15c2646d ci: update signCommand for tauri config windows 2025-09-23 19:00:39 +07:00
Minh141120
6c83580283 ci: fix syntax error in windows build workflow 2025-09-23 19:00:39 +07:00
Minh141120
6dc38f18cf chore: standardize build process on windows 2025-09-23 19:00:39 +07:00
Minh141120
50b66eff74 chore: update hooks to install vcredist.exe and update path for dll and license file 2025-09-23 19:00:39 +07:00
Minh141120
7257eb4ae6 chore: add LICENSE and vulkan-1.dll at instdir 2025-09-23 19:00:39 +07:00
Minh141120
8951123557 chore: add libvulkan for windows 2025-09-23 19:00:39 +07:00
Minh141120
0151274659 chore: update installerIcon on nsis config 2025-09-23 19:00:39 +07:00
Minh141120
53707a5083 chore: use default nsis template 2025-09-23 19:00:39 +07:00
Louis
7f09c36a92
fix: LocalAPI server trusted host should accept asterisk (#6551) 2025-09-23 17:45:37 +07:00
Nghia Doan
6f827872fb
fix: Catch local API server various errors (#6548)
* fix: Catch local API server various errors

* chore: Add tests to cover error catches
2025-09-23 17:40:16 +07:00
Faisal Amir
9741bf15b5
Merge pull request #6535 from menloresearch/docs/new-docs
 feat: Re-arrange docs as needed
2025-09-23 17:27:20 +07:00
Faisal Amir
8153287520
Merge pull request #6552 from menloresearch/docs/v2-landing
enhancement: migrate handbook and janv2
2025-09-23 17:26:45 +07:00
Faisal Amir
a6a2f0c191 chore: update missing install 2025-09-23 17:26:19 +07:00
Faisal Amir
3ec41e080f chore: fix meta data json 2025-09-23 17:17:35 +07:00
eckartal
26ed125693 Update handbook: restructure content and add new sections
- Add betting-on-open-source.mdx and open-superintelligence.mdx
- Update handbook index with new structure
- Remove outdated handbook sections (growth, happy, history, money, talent, teams, users, why)
- Update handbook _meta.json to reflect new structure
2025-09-23 18:10:59 +08:00
Faisal Amir
3bbce97329
Merge pull request #6559 from menloresearch/fix/layout-ability-model
fix: layout ability model
2025-09-23 16:13:33 +07:00
Louis
8a51cc1656
feat: add azure as first class provider (#6555)
* feat: add azure as first class provider

* fix: deployment url
2025-09-23 16:09:06 +07:00
Faisal Amir
3133d40081 fix: layout ability model 2025-09-23 15:27:41 +07:00
Dinh Long Nguyen
df61546942
feat: web remote conversation (#6554)
* feat: implement conversation endpoint

* use conversation aware endpoint

* fetch message correctly

* preserve first message

* fix logout

* fix broadcast issue locally + auth not refreshing profile on other tabs+ clean up and sync messages

* add is dev tag
2025-09-23 15:09:45 +07:00
Faisal Amir
2f85f214ea chore: update feedback #1 2025-09-23 13:29:28 +07:00
Faisal Amir
3c004819ca
Update docs/src/pages/_meta.json
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-09-23 12:49:55 +07:00
Faisal Amir
9a936ef826
Update docs/src/components/ui/dropdown-button.tsx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-09-23 12:49:39 +07:00
Faisal Amir
d2c86801b4 enhancement: migrate handbook and janv2 2025-09-23 12:45:57 +07:00
Louis
292941e1d0
fix: prevent relocation to root directories (#6547)
* fix: prevent relocation to root directories

* Update web-app/src/locales/zh-TW/settings.json

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-09-23 10:16:11 +07:00
Alexey Haidamaka
5adc0d9d46
add full-width model names (#6350) 2025-09-23 10:14:21 +07:00
Louis
568ee857d5
fix: custom fetch for all providers (#6538)
* fix: custom fetch for all providers

* fix: run in development should use built-in fetch
2025-09-23 09:55:36 +07:00
Akarshan Biswas
885da29f28
feat: add getTokensCount method to compute token usage (#6467)
* feat: add getTokensCount method to compute token usage

Implemented a new async `getTokensCount` function in the LLaMA.cpp extension.
The method validates the model session, checks process health, applies the request template, and tokenizes the resulting prompt to return the token count. Includes detailed error handling for crashed models and API failures, enabling callers to assess token usage before sending completions.

* Fix: typos

* chore: update ui token usage

* chore: remove unused code

* feat: add image token handling for multimodal LlamaCPP models

Implemented support for counting image tokens when using vision-enabled models:
- Extended `SessionInfo` with optional `mmprojPath` to store the multimodal project file.
- Propagated `mmproj_path` from the Tauri plugin into the session info.
- Added import of `chatCompletionRequestMessage` and enhanced token calculation logic in the LlamaCPP extension:
- Detects image content in messages.
- Reads GGUF metadata from `mmprojPath` to compute accurate image token counts.
- Provides a fallback estimation if metadata reading fails.
- Returns the sum of text and image tokens.
- Introduced helper methods `calculateImageTokens` and `estimateImageTokensFallback`.
- Minor clean‑ups such as comment capitalization and debug logging.

* chore: update FE send params message include content type image_url

* fix mmproj path from session info and num tokens calculation

* fix: Correct image token estimation calculation in llamacpp extension

This commit addresses an inaccurate token count for images in the llama.cpp extension.

The previous logic incorrectly calculated the token count based on image patch size and dimensions. This has been replaced with a more precise method that uses the clip.vision.projection_dim value from the model metadata.

Additionally, unnecessary debug logging was removed, and a new log was added to show the mmproj metadata for improved visibility.

* fix per image calc

* fix: crash due to force unwrap

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
Co-authored-by: Louis <louis@jan.ai>
2025-09-23 07:52:19 +05:30
hiento09
05e58cffe8
chore: add ci for web stag (#6550) 2025-09-23 01:58:48 +07:00
Akarshan Biswas
bf7f176741
feat: Prompt progress when streaming (#6503)
* feat: Prompt progress when streaming

- BE changes:
    - Add a `return_progress` flag to `chatCompletionRequest` and a corresponding `prompt_progress` payload in `chatCompletionChunk`. Introduce `chatCompletionPromptProgress` interface to capture cache, processed, time, and total token counts.
    - Update the Llamacpp extension to always request progress data when streaming, enabling UI components to display real‑time generation progress and leverage llama.cpp’s built‑in progress reporting.

* Make return_progress optional

* chore: update ui prompt progress before streaming content

* chore: remove log

* chore: remove progress when percentage >= 100

* chore: set timeout prompt progress

* chore: move prompt progress outside streaming content

* fix: tests

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
Co-authored-by: Louis <louis@jan.ai>
2025-09-22 20:37:27 +05:30
Faisal Amir
e1294cdc30
Merge pull request #6529 from menloresearch/enhancement/toaster-delete-mcp
enhancement: toaster delete mcp server
2025-09-22 21:12:02 +07:00
Faisal Amir
6373625206
Update web-app/src/index.css
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-09-22 21:04:24 +07:00
Faisal Amir
47b7509d2e remove gen android 2025-09-22 20:59:35 +07:00
Faisal Amir
04e81ba20e chore: update height of thread detail 2025-09-22 20:55:33 +07:00
Faisal Amir
5c4ce729f7 chore: update checking platform using config isntead navigation agent 2025-09-22 20:32:09 +07:00
Louis
0d2c99a413
fix: prevent consecutive messages with same role (#6544)
* fix: prevent consecutive messages with same role

* fix: tests

* fix: first message should not be assistant

* fix: tests
2025-09-22 19:27:45 +07:00
nngostuds
c327622a6c Add server docs
Add server docs
2025-09-22 17:29:02 +07:00
LazyYuuki
ccce3b24e1 🔧 chore: re-arrange the folder structure 2025-09-22 17:23:29 +08:00
Faisal Amir
e3c29277f3 chore: update chatscreen padding 2025-09-22 15:55:07 +07:00
Faisal Amir
f639ec70d4 enhancement: fit mobile layout 2025-09-22 15:06:11 +07:00
Louis
b0b84b7eda
Merge pull request #6475 from menloresearch/feat/bump-tokenjs
feat: fix remote provider vision capability
2025-09-22 14:37:26 +07:00
Nghia Doan
a418574841
Merge pull request #6540 from menloresearch/mobile/thinning_app
feat: Configure iOS to use frontDist to independently build
2025-09-22 11:49:13 +07:00
Vanalite
6d131f8cbb fix: Remove redundant yarn command for ios dev build 2025-09-22 11:35:19 +07:00
Nguyen Ngoc Minh
8cdb021b3d
Merge pull request #6518 from menloresearch/chore/update-build-tauri
chore: update build tauri commands
2025-09-22 11:32:01 +07:00
Vanalite
8e1654961a chore: Configure iOS to use the same build mechanic to remove unnecessary plugin 2025-09-22 11:28:01 +07:00
Vanalite
003598204e Merge remote-tracking branch 'origin/dev' into mobile/dev
# Conflicts:
#	src-tauri/.cargo/config.toml
#	src-tauri/Cargo.toml
#	src-tauri/src/lib.rs
#	web-app/src/containers/__tests__/ChatInput.test.tsx
#	web-app/src/routeTree.gen.ts
#	web-app/src/routes/index.tsx
#	web-app/src/routes/threads/$threadId.tsx
#	yarn.lock
2025-09-22 11:24:20 +07:00
LazyYuuki
48ddc20026 feat: Re-arrange docs as needed 2025-09-21 19:24:48 +08:00
Bui Quang Huy
361c9eeff4
Merge pull request #6524 from menloresearch/docs/update-changelog
docs: update changelog for v0.6.10
2025-09-19 18:08:47 -07:00
Bui Quang Huy
b6169a48e6
Update 2025-09-18-auto-optimize-vision-imports.mdx 2025-09-20 09:04:11 +08:00
Faisal Amir
29862435ab
Merge pull request #6526 from github-roushan/fix-number-input
fix(number-input): preserve '0.0x' format when typing (#6520)
2025-09-19 23:25:22 +07:00
Faisal Amir
ec425163d3 enhancement: toaster delete mcp server 2025-09-19 23:25:01 +07:00
Akarshan Biswas
991bbec53a
fix: Typo in openapi JSON (#6528) 2025-09-19 12:53:39 +05:30
Nguyen Ngoc Minh
e1fa60be99
Merge pull request #6527 from menloresearch/docs/update-url-for-gif-and-videos
docs: update url for gifs and videos
2025-09-19 14:22:12 +07:00
Minh141120
465544cc2c chore: update url for jan-v1 docs 2025-09-19 14:17:23 +07:00
Minh141120
4694ab8350 docs: update url for gifs and videos 2025-09-19 14:10:59 +07:00
Roushan Singh
ae2532d40d fix(number-input): preserve '0.0x' format when typing (#6520) 2025-09-19 11:36:06 +05:30
Bui Quang Huy
2c251d0cef
Merge branch 'dev' into docs/update-changelog 2025-09-18 22:00:27 -07:00
Louis
6bd64409e8
fix: thread rerender issue (#6515)
* fix: thread rerender issue

* chore: clean up console log

* chore: uncomment irrelevant fix

* fix: linter

* chore: remove duplicated block

* fix: tests

* fix: reduce unnessary rerender due to current thread retrieval

* fix: reduce app layout rerender due to router state update

* fix: avoid the entire app layout re render on route change

* clean: unused import

* fix: should not rerender thread message components when typing

* fix re render issue

* direct tokenspeed access

* chore: sync latest

* fix: tests

* fix: linter

* fix: build

---------

Co-authored-by: Dinh Long Nguyen <dinhlongviolin1@gmail.com>
2025-09-19 11:50:46 +07:00
Minh141120
162e0ef378 docs: update changelog for v0.6.10 2025-09-19 11:47:01 +07:00
Louis
0f349f4b8c
fix: build 2025-09-19 11:13:39 +07:00
Louis
1ec9c29df6
fix: linter 2025-09-19 11:08:37 +07:00
Louis
3d8cfbf99a
fix: tests 2025-09-19 10:56:25 +07:00
Akarshan Biswas
d1a8bdc4e3
feat: Add Jan API server Swagger UI (#6502)
* feat: Add Jan API server Swagger UI

- Serve OpenAPI spec (`static/openapi.json`) directly from the proxy server.
- Implement Swagger UI assets (`swagger-ui.css`, `swagger-ui-bundle.js`, `favicon.ico`) and a simple HTML wrapper under `/docs`.
- Extend the proxy whitelist to include Swagger UI routes.
- Add routing logic for `/openapi.json`, `/docs`, and Swagger UI static files.
- Update whitelisted paths and integrate CORS handling for the new endpoints.

* feat: serve Swagger UI at root path

The Swagger UI endpoint previously lived under `/docs`. The route handling and
exclusion list have been updated so the UI is now served directly at `/`.
This simplifies access, aligns with the expected root URL in the Tauri
frontend, and removes the now‑unused `/docs` path handling.

* feat: add model loading state and translations for local API server

Implemented a loading indicator for model startup, updated the start/stop button to reflect model loading and server starting states, and disabled interactions while pending. Added new translation keys (`loadingModel`, `startingServer`) across all supported locales (en, de, id, pl, vn, zh-CN, zh-TW) and integrated them into the UI. Included a small delay after model start to ensure backend state consistency. This improves user feedback and prevents race conditions during server initialization.
2025-09-19 09:11:55 +05:30
Louis
c9d165e65c
Merge branch 'dev' into fix/thread-rerender-issue 2025-09-19 10:34:08 +07:00
Louis
ebb6837437 chore: sync latest 2025-09-19 10:30:03 +07:00
Dinh Long Nguyen
4cfc88ae95 direct tokenspeed access 2025-09-18 23:28:05 +07:00
Dinh Long Nguyen
c5c39f22e6 Merge branch 'fix/thread-rerender-issue' of https://github.com/menloresearch/jan into fix/thread-rerender-issue 2025-09-18 23:21:28 +07:00
Dinh Long Nguyen
a39c38e1fd fix re render issue 2025-09-18 23:11:50 +07:00
Louis
508879e3ae fix: should not rerender thread message components when typing 2025-09-18 22:44:03 +07:00
Minh141120
7c5633c9a1 chore: remove unused task 2025-09-18 21:56:09 +07:00
Minh141120
b8a3699497 chore: update build tauri commands 2025-09-18 21:53:28 +07:00
Dinh Long Nguyen
359dd8f41e
Merge pull request #6514 from menloresearch/feat/web-gtag
feat: Add GA Measurement and change keyboard bindings on web
2025-09-18 20:45:41 +07:00
Dinh Long Nguyen
645548e931
Merge pull request #6516 from menloresearch/release/v0.6.10 2025-09-18 19:15:54 +07:00
Louis
f237936b0c
clean: unused import 2025-09-18 18:49:12 +07:00
Louis
5f6a68d844
fix: avoid the entire app layout re render on route change 2025-09-18 18:44:21 +07:00
Louis
be83395f69 fix: reduce app layout rerender due to router state update 2025-09-18 18:26:03 +07:00
Louis
6342956cd6 fix: reduce unnessary rerender due to current thread retrieval 2025-09-18 17:55:07 +07:00
Louis
86a92ead85
Merge pull request #6469 from menloresearch/fix/deeplink-not-work-on-windows
fix: deeplink issue on Windows
2025-09-18 17:47:00 +07:00
Louis
2a2bc40dfe
fix: tests 2025-09-18 17:21:59 +07:00
Louis
707fdac2ce chore: remove duplicated block 2025-09-18 16:45:37 +07:00
Louis
e64607eb43 fix: linter 2025-09-18 16:44:16 +07:00
Louis
da69f3acec chore: uncomment irrelevant fix 2025-09-18 16:35:56 +07:00
Louis
f271e8fe9c chore: clean up console log 2025-09-18 16:31:19 +07:00
Nghia Doan
f90398e29a
Merge pull request #6512 from menloresearch/mobile/thinning_app
Feat: Mobile App Optimization and Backend Integration
2025-09-18 16:30:30 +07:00
Louis
241a90492e fix: thread rerender issue 2025-09-18 16:24:42 +07:00
Vanalite
f76387ac6a feat: Disable zoom and setup mobile viewport 2025-09-18 15:42:22 +07:00
Vanalite
15d56e8e7e chore: Shrink the Android app size to minimal, release type 2025-09-18 13:35:50 +07:00
Vanalite
21d0943aa4 chore: Separate configuration for android build in release mode 2025-09-18 11:32:52 +07:00
Dinh Long Nguyen
0f85fce6ef
feat: add auth + google auth provider for web (#6505)
* handle google auth

* fix lint

* fix auto login button type

* update i18 language + userprofilemenu position

* minor api rename for consistency
2025-09-18 11:11:14 +07:00
Vanalite
4205b2a479 chore: add command to ease the mobile dev 2025-09-18 09:51:32 +07:00
Vanalite
1cddc4be25 chore: keep gen icon on Android 2025-09-18 09:50:54 +07:00
Akarshan Biswas
b9f658f2ae
fix: correct memory suitability checks in llamacpp extension (#6504)
The previous implementation mixed model size and VRAM checks, leading to inaccurate status reporting (e.g., false RED results).
- Simplified import statement for `readGgufMetadata`.
- Fixed RAM/VRAM comparison by removing unnecessary parentheses.
- Replaced ambiguous `modelSize > usableTotalMemory` check with a clear `totalRequired > usableTotalMemory` hard‑limit condition.
- Refactored the status logic to explicitly handle the CPU‑GPU hybrid scenario, returning **YELLOW** when the total requirement fits combined memory but exceeds VRAM.
- Updated comments for better readability and maintenance.
2025-09-17 20:09:33 +05:30
Louis
973f77cdc6
feat: system tray icon build flag (#6500)
* feat: system tray icon build flag

* fix: missing tray feature for testing

* fix: failed tests

* fix: left click should not show menu

* ci: add system dependencies for appindicator lib on Linux

---------

Co-authored-by: Minh141120 <minh.itptit@gmail.com>
2025-09-17 21:04:43 +07:00
Minh141120
d9a0a8e09d ci: add system dependencies for appindicator lib on Linux 2025-09-17 20:34:44 +07:00
Louis
0ab6417caa
fix: left click should not show menu 2025-09-17 19:58:59 +07:00
Louis
4a4423ed6b
fix: failed tests 2025-09-17 19:55:57 +07:00
Louis
a85ffa270e
fix: missing tray feature for testing 2025-09-17 19:48:30 +07:00
Louis
15164fc0be
feat: system tray icon build flag 2025-09-17 15:54:20 +07:00
Nguyen Ngoc Minh
cac6253d87
Merge pull request #6498 from menloresearch/chore/fix-redirect
chore: fix redirect
2025-09-16 22:56:18 -07:00
Hien To
37b2cf4e13 chore: fix redirect 2025-09-17 12:51:06 +07:00
Nguyen Ngoc Minh
1e72e474ec
Merge pull request #6497 from menloresearch/chore/add-redirect
chore: add redirect
2025-09-16 22:20:15 -07:00
Hien To
f3f5998e23 chore: add redirect 2025-09-17 12:00:08 +07:00
Vanalite
adfcb35ca6 Merge remote-tracking branch 'origin/dev' into mobile/init-mobile-app 2025-09-17 11:22:57 +07:00
Faisal Amir
066c70fca5
Merge pull request #6496 from menloresearch/fix/wipe-out-docs-website
fix: remove website folder
2025-09-17 10:44:18 +07:00
Faisal Amir
3d2d25cba5 fix: remove website folder 2025-09-17 10:35:41 +07:00
Nguyen Ngoc Minh
630463257b
Merge pull request #6495 from menloresearch/qa/v0.6.10
feat: add qa checklist v0.6.10
2025-09-16 20:22:38 -07:00
Faisal Amir
b4fd7c300a
Merge pull request #6493 from menloresearch/fix/edit-dialog
chore: prevent click outside for edit dialog
2025-09-17 10:22:23 +07:00
Minh141120
eaa0bee9d4 chore: correct typo in checklist 2025-09-17 10:20:09 +07:00
Minh141120
dc808765aa chore: remove old checklist 2025-09-17 09:42:14 +07:00
Minh141120
c825ba4e4b feat: add qa checklist 2025-09-17 09:40:14 +07:00
Faisal Amir
6f2a01990f chore: prevent click outside for edit dialog 2025-09-17 09:35:36 +07:00
Faisal Amir
7fc3afd0ef
Merge pull request #6478 from menloresearch/fix/mcp-json-validation
fix: mcp json  validation structure and serverName
2025-09-17 09:01:01 +07:00
Nghia Doan
aae1936620
Update web-app/src/routes/index.tsx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-09-17 08:18:52 +07:00
Faisal Amir
a3c2c1aa3b fix: validat type mcp json 2025-09-16 22:35:51 +07:00
Vanalite
8fa79aa394 chore: Adjust paddings to save some space for the top nav bar 2025-09-16 21:35:50 +07:00
Vanalite
a49d488ae1 fix: Restore dedupe command 2025-09-16 20:38:56 +07:00
Vanalite
224bee5c66 feat: Adjust UI for mobile res
Feature:
- Adjust homecreen and chatscreen for mobile device
- Fix tests for both FE and BE
Self-test:
- Confirm runnable on both Android and iOS
- Confirm runnable on desktop app
- All test suites passed
- Working with ChatGPT API
2025-09-16 20:38:56 +07:00
Vanalite
fd046a2d08 fix: Fix parsing datatype inconsistent across platforms 2025-09-16 20:38:56 +07:00
Vanalite
633a6ac032 fix: Reconfigure and add toolchain to wake up Android app 2025-09-16 20:38:56 +07:00
Vanalite
854cc69414 feat: Add android target 2025-09-16 20:38:56 +07:00
Vanalite
e5dccf741a fix: Fix tests 2025-09-16 20:38:56 +07:00
Vanalite
fa0ed11258 feat: Init mobile app from current Tauri v2 framework
Feat:
- Using Tauri v2 by default
- Add new configuration to initiate mobile app
- Add dependencies needed for mobile build
Test:
- Confirm to be built successfully
- Confirm to keep settings for desktop and build successfully
- Reuse most of components from desktop version
2025-09-16 20:38:50 +07:00
Nguyen Ngoc Minh
e579eed2f4
Merge pull request #6482 from menloresearch/chore/embed-webview2-bootstrapper
chore: embed webview2 bootstrapper in tauri windows
2025-09-16 05:20:46 -07:00
Minh141120
022048f577 chore: embed webview2 bootstrapper in tauri windows 2025-09-16 18:43:32 +07:00
Louis
5fa0826ee8
fix: new extension settings aren't populated properly (#6476) 2025-09-16 18:10:00 +07:00
Faisal Amir
703b44558c chore: update locale mcp json 2025-09-16 17:24:32 +07:00
Faisal Amir
bb39cb1e99 fix/mcp-json-validation 2025-09-16 17:20:14 +07:00
Faisal Amir
93807745cd
Merge pull request #6477 from menloresearch/fix/valdidate-mmproj
fix: validate mmproj from general basename
2025-09-16 17:18:55 +07:00
Faisal Amir
0945eaedcd fix: loader when importing 2025-09-16 16:53:47 +07:00
Faisal Amir
272ef9f8b8 fix/revalidate-model-gguf 2025-09-16 15:59:59 +07:00
Faisal Amir
ea354ce621 fix/validate-mmproj-from-general-basename 2025-09-16 15:44:58 +07:00
Faisal Amir
fd052149fe
Merge pull request #6474 from menloresearch/fix/model-selection
fix: immediate update value model selection
2025-09-16 13:54:37 +07:00
Faisal Amir
0e972646e8
Merge pull request #6465 from menloresearch/fix/attachment-edit-message
fix: attachment edit message
2025-09-16 11:17:17 +07:00
Faisal Amir
4ef64ce18c fix: linter 2025-09-16 11:16:53 +07:00
Faisal Amir
9fe517dbf8 fix: immediate dropdown value update 2025-09-16 11:16:35 +07:00
Louis
6dde7e0ba1
Merge pull request #6473 from theishangoswami/exa-mcp-addition
Added Exa MCP
2025-09-16 10:28:44 +07:00
Faisal Amir
da2f790f25
Merge pull request #6464 from menloresearch/fix/pathname-install-be
fix: pathname file install BE
2025-09-16 10:14:02 +07:00
theishangoswami
c02d8200ac added exa mcp 2025-09-16 04:38:03 +05:30
Dinh Long Nguyen
491012fa87
remove assistant from web (#6468) 2025-09-15 23:53:59 +07:00
Faisal Amir
52fe8e8c0e fix: type imageurl 2025-09-15 21:58:24 +07:00
Faisal Amir
7b9b9666cb fix: imporove edit message with attachment image 2025-09-15 21:48:19 +07:00
Faisal Amir
3b22f0b7c0 fix: imporove edit message with attachment image 2025-09-15 21:48:01 +07:00
Louis
cf87313f28
Merge pull request #6384 from maxx-ukoo/mk_add_configurable_timeout_to_local_api_server
Add model response timeout for local api server as configurable value
2025-09-15 21:26:07 +07:00
Faisal Amir
e02be47aae fix: remove log 2025-09-15 21:09:08 +07:00
Faisal Amir
5736d7b110 fix: auto update should not block popup 2025-09-15 20:51:27 +07:00
Akarshan Biswas
9e3a77a559
fix: set default memory mode and clean up unused import (#6463)
Use fallback value 'high' for memory_util config and remove unused GgufMetadata import.
2025-09-15 19:00:46 +05:30
Louis
e78e4e5cca
Merge pull request #6278 from lugnicca/feat/model-selector
feat: add model selector (fetch from v1/models) when user adds a provider model
2025-09-15 20:23:22 +07:00
Dinh Long Nguyen
311a451005
Always allow MCP for web (#6462)
* mcp and extension setting disabled + always allow mcp tools on web

* fix tests
2025-09-15 20:13:46 +07:00
Maksym Krasovakyi
71e2e24112 Add model response timeout for local api server as configurable value via UI 2025-09-15 14:25:09 +03:00
Faisal Amir
18114c0a15 fix: pathname file install BE 2025-09-15 18:05:11 +07:00
Bui Quang Huy
59b2755810
Merge pull request #6461 from menloresearch/docs/missing-url
chore: missing local api server
2025-09-15 18:16:37 +08:00
Trang Le
1aa39392ab
set bullet list style to be circle (#6437) 2025-09-15 17:13:07 +07:00
Faisal Amir
7921bb21c7 chore: missing local api server 2025-09-15 15:40:46 +07:00
Faisal Amir
d73a932773
Merge pull request #6460 from menloresearch/revert/old-docs
chore: revert back old docs
2025-09-15 15:28:14 +07:00
Faisal Amir
1ca765476e chore: revert back old docs 2025-09-15 15:22:00 +07:00
Akarshan Biswas
e80a865def
fix: detect allocation failures as out-of-memory errors (#6459)
The Llama.cpp backend can emit the phrase “failed to allocate” when it runs out of memory.
Adding this check ensures such messages are correctly classified as out‑of‑memory errors,
providing more accurate error handling CPU backends.
2025-09-15 12:35:24 +05:30
Bui Quang Huy
32ff0df6c9
Merge pull request #6451 from menloresearch/LazyYuuki-patch-1
Update 4-goal.md
2025-09-15 13:07:32 +08:00
Bui Quang Huy
f02f001266
Merge branch 'dev' into LazyYuuki-patch-1 2025-09-15 13:07:11 +08:00
Nguyen Ngoc Minh
55edc7129e
Merge pull request #6457 from menloresearch/chore/makefile-rust-targets
chore: makefile rust targets macos
2025-09-15 12:03:17 +07:00
Louis
43431c26e7
Merge branch 'dev' into feat/model-selector 2025-09-15 12:02:25 +07:00
Akarshan Biswas
489c5a3d9c
fix: KVCache size calculation and refactor (#6438)
- Removed the unused `getKVCachePerToken` helper and replaced it with a unified `estimateKVCache` that returns both total size and per‑token size.
- Fixed the KV cache size calculation to account for all layers, correcting previous under‑estimation.
- Added proper clamping of user‑requested context lengths to the model’s maximum.
- Refactored VRAM budgeting: introduced explicit reserves, fixed engine overhead, and separate multipliers for VRAM and system RAM based on memory mode.
- Implemented a more robust planning flow with clear GPU, Hybrid, and CPU pathways, including fallback configurations when resources are insufficient.
- Updated default context length handling and safety buffers to prevent OOM situations.
- Adjusted usable memory percentage to 90 % and refined logging for easier debugging.
2025-09-15 10:16:13 +05:30
Minh141120
1db67ea9a2 chore: simplify macos workflow 2025-09-15 11:24:11 +07:00
Faisal Amir
7a2782e6fd
Merge pull request #6456 from menloresearch/enhancement/copy-mcp-permission
enhancement: copy MCP permission
2025-09-15 11:01:09 +07:00
Faisal Amir
a4483b7eb7
Update web-app/src/locales/en/tool-approval.json
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-09-15 10:38:36 +07:00
Faisal Amir
a26445e557 chore: make action mutton capitalize 2025-09-15 10:34:27 +07:00
Faisal Amir
44893bc3c3 enhancement: copy MCP permission 2025-09-15 10:33:05 +07:00
Louis
1d36a4ad6e
refactor: clean up empty folders (#6454) 2025-09-15 10:27:07 +07:00
Minh141120
4fa78fa892 fix: make install-rust-targets a dependency 2025-09-15 09:44:21 +07:00
Minh141120
6959329fd6 chore: add install-rust-targets step for macOS universal builds 2025-09-15 09:32:51 +07:00
Dinh Long Nguyen
0771b998a5
Fix: Web Services Improvement
Fix: Web Services Improvement
2025-09-15 09:08:30 +07:00
Bui Quang Huy
78d816b435
Update 4-goal.md 2025-09-14 22:26:57 +08:00
Akarshan Biswas
654e566dcb
fix: correct context shift flag handling in LlamaCPP extension (#6404) (#6431)
* fix: correct context shift flag handling in LlamaCPP extension

The previous implementation added the `--no-context-shift` flag when `cfg.ctx_shift` was disabled, which conflicted with the llama.cpp CLI where the presence of `--context-shift` enables the feature.
The logic is updated to push `--context-shift` only when `cfg.ctx_shift` is true, ensuring the extension passes the correct argument and behaves as expected.

* feat: detect model out of context during generation

---------

Co-authored-by: Dinh Long Nguyen <dinhlongviolin1@gmail.com>
2025-09-12 13:43:31 +05:30
Nguyen Ngoc Minh
596930174f
Merge pull request #6433 from menloresearch/ci/jan-web
ci: fix typo in branch name for jan web
2025-09-12 14:16:29 +07:00
Nguyen Ngoc Minh
b8ca6f5d76
ci: fix typo in branch name for jan web 2025-09-12 14:15:27 +07:00
Nguyen Ngoc Minh
91e17dc4ee
Merge pull request #6430 from menloresearch/ci/remove-path-for-jan-web
ci: remove paths triggered for jan server
2025-09-12 13:44:27 +07:00
Minh141120
6c935132a9 ci: remove paths triggered for jan server 2025-09-12 13:41:48 +07:00
Piotr Orzechowski
129c64a9a4
fix: Polish translation (#6421) 2025-09-12 12:53:58 +07:00
Faisal Amir
ad428f587b
Merge pull request #6426 from menloresearch/fix/error-validate-nested-dom
fix: avoid error validate nested DOM
2025-09-12 12:28:46 +07:00
Dinh Long Nguyen
b5b6e1dc19
add mcp for web (#6411)
* add mcp for web

* update /jan/v1 endpoint to /v1

* update mise and makefile

* update yarn lock

* use mcp oauth properly
2025-09-12 12:14:10 +07:00
Nguyen Ngoc Minh
72128117a9
Merge pull request #6427 from menloresearch/ci/separate-jan-web-build-and-deploy
ci: separate jan web build and deploy
2025-09-12 11:20:09 +07:00
Minh141120
32440a9510 ci: separate jan web build and deploy 2025-09-12 11:10:28 +07:00
Faisal Amir
4293fe7edc fix: avoid error validate nested dom 2025-09-12 10:58:34 +07:00
Dinh Long Nguyen
ea72c1ae0f
exclude jan extension web from desktop build (#6419) 2025-09-11 19:51:49 +07:00
Dinh Long Nguyen
db52057030
fix ollama error (#6418) 2025-09-11 18:38:06 +07:00
Faisal Amir
e709d200aa
Merge pull request #6416 from menloresearch/enhancement/experimental-label
enhancement: add label experimental for optimize setting
2025-09-11 16:12:35 +07:00
Dinh Long Nguyen
4856cfbfc4
bug: Deleted model file from imported models blocking model loading (#6317) (#6417) 2025-09-11 15:56:19 +07:00
Faisal Amir
19aa15ffcd chore: update return value 2025-09-11 15:51:21 +07:00
Akarshan
7c41408a1a
feat: add relative path support for model loading
Implemented `isAbsolutePath` helper to correctly identify POSIX, Windows drive‑letter, and UNC absolute paths. Updated `planModelLoad` to automatically resolve relative model and mmproj paths against the Jan data folder, enhancing usability for users supplying non‑absolute paths. Also refined minor formatting for readability.
2025-09-11 13:45:29 +05:30
Akarshan
8f67f29317
feat: add support for mmproj offload setting
Expose the new `mmproj_offload` option in the model settings UI and include it in the `ModelPlan` type. The component now collects the offload flag (`result.offloadMmproj`) and queues it with other setting updates to ensure a single atomic change, preventing race conditions when toggling this feature. This enables users to control MMProj offloading directly from the app.
2025-09-11 13:08:01 +05:30
Faisal Amir
14c7fc0450 chore: update argument 2025-09-11 14:23:56 +07:00
Akarshan
abd0cbe599
refactor: rename noOffloadMmproj flag to offloadMmproj and reorder args
The flag `noOffloadMmproj` was misleading – it actually indicates when the mmproj file **is** offloaded to VRAM. Renaming it to `offloadMmproj` clarifies its purpose and aligns the naming with the surrounding code.

Additionally, the `planModelLoad` signature has been reordered to place `mmprojPath` before `requestedCtx`, improving readability and making the optional parameters more intuitive. All related logic, calculations, and log messages have been updated to use the new flag name.
2025-09-11 12:29:53 +05:30
Faisal Amir
198955285e
Merge pull request #6412 from menloresearch/fix/render-new-line
fix: render new line for user message
2025-09-11 13:29:18 +07:00
Faisal Amir
bc29046c06 enhancement: send params mmptoj_path for optimize setting 2025-09-11 13:23:25 +07:00
Louis
7fea6e1ab0
fix: clean up unused packages (#6414) 2025-09-11 13:16:26 +07:00
Faisal Amir
791563e6ba enhancement: add label experimental for optimize setting 2025-09-11 13:11:37 +07:00
Akarshan Biswas
5ff7935d91
fix: include lm_head and embedding layers in totalLayers count (#6415)
The original calculation used only the `block_count` from the model metadata, which excludes the final LM head and the embedding layer. This caused an underestimation of the total number of layers and consequently an incorrect `layerSize` value. Adding `+2` accounts for these two missing layers, ensuring accurate model size metrics.
2025-09-11 11:40:39 +05:30
Nguyen Ngoc Minh
d856651380
Merge pull request #6413 from menloresearch/ci/add-nightly-external-contrib
ci: add nightly build for external contributors
2025-09-11 13:03:30 +07:00
Minh141120
65a515a9db chore: add upload artifact steps for 3 platforms 2025-09-11 12:21:56 +07:00
Minh141120
773b252555 ci: add nightly build for external contributors 2025-09-11 11:30:43 +07:00
Akarshan Biswas
7a94e74d6b
Merge pull request #6360 from menloresearch/feat/llamacpp_backend
feat: enhance llamacpp backend management and installation
2025-09-11 09:57:16 +05:30
Akarshan
13806a3f06
Fixup sorting in determineBestBackend 2025-09-11 09:56:46 +05:30
Akarshan Biswas
3cd099ee87
Update extensions/llamacpp-extension/src/index.ts
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-09-11 09:55:57 +05:30
Akarshan
42411b5f33
feat: prioritize Vulkan backend only when GPU has ≥6 GB VRAM
Added a GPU memory check using `getSystemInfo` to ensure Vulkan is selected only on systems with at least 6 GB of VRAM.
* Made `determineBestBackend` asynchronous and updated all callers to `await` it.
* Adjusted backend priority list to include or demote Vulkan based on the memory check.
* Updated Vulkan support detection in `backend.ts` to rely solely on API version (memory check moved to selection logic).
* Imported `getSystemInfo` and refined file‑existence validation.

These changes prevent sub‑optimal Vulkan usage on low‑memory GPUs and improve backend selection reliability.
2025-09-11 09:55:55 +05:30
Akarshan
84874c6039
fix file condition 2025-09-11 09:55:08 +05:30
Akarshan
0eff1bfaa9
Throw error when invalid file 2025-09-11 09:55:08 +05:30
Akarshan
5ef9d8dfc3
Add debug logs and refactor 2025-09-11 09:55:06 +05:30
dinhlongviolin1
e2e572ccab
refactor: moved get_short_path to utils and use it in decompress 2025-09-11 09:52:10 +05:30
Faisal Amir
6067ffe107
chore: fix conflict 2025-09-11 09:52:09 +05:30
Faisal Amir
cbd2651a63
chore: update copy and refresh list when import from local machine 2025-09-11 09:52:09 +05:30
Akarshan
2e350ab607
Refresh list of backends by calling configureBackends() and some refactoring in installBackend 2025-09-11 09:52:09 +05:30
Faisal Amir
ba4dc6d1eb
enhancement: update ui dialog update llamacpp backend 2025-09-11 09:52:09 +05:30
Akarshan
a6e4f28830
Add guard before checking locally installed backends 2025-09-11 09:52:09 +05:30
Akarshan
4e37c361c4
feat: expose new updateBackend function for manually updating backend 2025-09-11 09:52:09 +05:30
Akarshan
7ac927ff02
feat: enhance llamacpp backend management and installation
- Add `src-tauri/resources/` to `.gitignore`.
- Introduced utilities to read locally installed backends (`getLocalInstalledBackends`) and fetch remote supported backends (`fetchRemoteSupportedBackends`).
- Refactored `listSupportedBackends` to merge remote and local entries with deduplication and proper sorting.
- Exported `getBackendDir` and integrated it into the extension.
- Added helper `parseBackendVersion` and new method `checkBackendForUpdates` to detect newer backend versions.
- Implemented `installBackend` for manual backend archive installation, including platform‑specific binary path handling.
- Updated command‑line argument logic for `--flash-attn` to respect version‑specific defaults.
- Modified Tauri filesystem `decompress` command to remove overly strict path validation.
2025-09-11 09:52:09 +05:30
Akarshan Biswas
7a174e621a
feat: Smart model management (#6390)
* feat: Smart model management

* **New UI option** – `memory_util` added to `settings.json` with a dropdown (high / medium / low) to let users control how aggressively the engine uses system memory.
* **Configuration updates** – `LlamacppConfig` now includes `memory_util`; the extension class stores it in a new `memoryMode` property and handles updates through `updateConfig`.
* **System memory handling**
  * Introduced `SystemMemory` interface and `getTotalSystemMemory()` to report combined VRAM + RAM.
  * Added helper methods `getKVCachePerToken`, `getLayerSize`, and a new `ModelPlan` type.
* **Smart model‑load planner** – `planModelLoad()` computes:
  * Number of GPU layers that can fit in usable VRAM.
  * Maximum context length based on KV‑cache size and the selected memory utilization mode (high/medium/low).
  * Whether KV‑cache must be off‑loaded to CPU and the overall loading mode (GPU, Hybrid, CPU, Unsupported).
  * Detailed logging of the planning decision.
* **Improved support check** – `isModelSupported()` now:
  * Uses the combined VRAM/RAM totals from `getTotalSystemMemory()`.
  * Applies an 80% usable‑memory heuristic.
  * Returns **GREEN** only when both weights and KV‑cache fit in VRAM, **YELLOW** when they fit only in total memory or require CPU off‑load, and **RED** when the model cannot fit at all.
* **Cleanup** – Removed unused `GgufMetadata` import; updated imports and type definitions accordingly.
* **Documentation/comments** – Added explanatory JSDoc comments for the new methods and clarified the return semantics of `isModelSupported`.

* chore: migrate no_kv_offload from llamacpp setting to model setting

* chore: add UI auto optimize model setting

* feat: improve model loading planner with mmproj support and smarter memory budgeting

* Extend `ModelPlan` with optional `noOffloadMmproj` flag to indicate when a multimodal projector can stay in VRAM.
* Add `mmprojPath` parameter to `planModelLoad` and calculate its size, attempting to keep it on GPU when possible.
* Refactor system memory detection:
  * Use `used_memory` (actual free RAM) instead of total RAM for budgeting.
  * Introduced `usableRAM` placeholder for future use.
* Rewrite KV‑cache size calculation:
  * Properly handle GQA models via `attention.head_count_kv`.
  * Compute bytes per token as `nHeadKV * headDim * 2 * 2 * nLayer`.
* Replace the old 70 % VRAM heuristic with a more flexible budget:
  * Reserve a fixed VRAM amount and apply an overhead factor.
  * Derive usable system RAM from total memory minus VRAM.
* Implement a robust allocation algorithm:
  * Prioritize placing the mmproj in VRAM.
  * Search for the best balance of GPU layers and context length.
  * Fallback strategies for hybrid and pure‑CPU modes with detailed safety checks.
* Add extensive validation of model size, KV‑cache size, layer size, and memory mode.
* Improve logging throughout the planning process for easier debugging.
* Adjust final plan return shape to include the new `noOffloadMmproj` field.

* remove unused variable

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-09-11 09:48:03 +05:30
Faisal Amir
9e592b2aca fix: render new line for user message 2025-09-11 10:29:34 +07:00
Faisal Amir
3158722a63
Merge pull request #6409 from menloresearch/enhancement/edit-model-capabilities
enhancement: rollback edit capabilities for local model
2025-09-10 22:46:23 +07:00
Faisal Amir
86dcfc10cf enhancement: rollback edit capabilities for local model 2025-09-10 19:43:44 +07:00
Nguyen Ngoc Minh
eea76802d4
Merge pull request #6408 from menloresearch/ci/claude-issue-dedup
ci: add claude issue dedup
2025-09-10 17:20:48 +07:00
Minh141120
0edf9635a1 ci: add claude issue dedup 2025-09-10 17:16:21 +07:00
Ramon Perez
18351e3850
Merge pull request #6406 from menloresearch/rp/api-ref-fix
removed cloud api spec update
2025-09-10 13:51:59 +10:00
Ramon Perez
aef0538adc updated openapi spec for jan server 2025-09-10 13:37:03 +10:00
Ramon Perez
9ec87614b2 removed cloud api spec update 2025-09-10 13:32:06 +10:00
hiento09
97eebd1c97
fix: jan server api base url for prod (#6403) 2025-09-09 20:51:04 +07:00
Dinh Long Nguyen
5cd81bc6e8
feat: improve testing (#6395)
* add more test rust test

* fix servicehub test

* fix tauri failing on windows
2025-09-09 12:16:25 +07:00
hiento09
dbaf563e88
chore: add cicd for jan web prod (#6396) 2025-09-09 12:13:37 +07:00
Faisal Amir
5e30e10bf4
Merge pull request #6388 from menloresearch/feat/import-vision-model
feat: allow user import model include mmproj file
2025-09-09 09:41:58 +07:00
Faisal Amir
a5b0ced9a9 chore: update logic turn on / off mmproj 2025-09-09 00:01:56 +07:00
lugnicca
dbcc1db0b9 Merge branch 'dev' into feat/model-selector 2025-09-08 17:51:03 +02:00
lugnicca
2db9af94fa fix: use serviceHub to fetch models and fix error message on app 2025-09-08 17:45:35 +02:00
Faisal Amir
94dc298181 chore: update validation logic 2025-09-08 22:37:55 +07:00
Faisal Amir
cd85ae062e
Merge pull request #6381 from menloresearch/enhancement/dialog-modal-responsive
enhancement: responsive dialog modals
2025-09-08 22:24:47 +07:00
Faisal Amir
f2594134c7 chore: update UI 2025-09-08 21:20:21 +07:00
Faisal Amir
be851ebcf1 chore: validate gguf file base metadata architecture 2025-09-08 20:16:20 +07:00
Faisal Amir
9b13b140d5 chore: update mcp delete dialog 2025-09-08 19:43:38 +07:00
Nguyen Ngoc Minh
fcd285ca0f
Merge pull request #6392 from menloresearch/ci/update-jan-server-web
ci: remove unnecessary folder paths and on Dockerfile
2025-09-08 16:49:22 +07:00
Minh141120
0e7c12f340 ci: remove unnecessary folder paths and on Dockerfile 2025-09-08 16:37:26 +07:00
Faisal Amir
836990b7d9 chore: update fn check mmproj file 2025-09-08 11:10:00 +07:00
Faisal Amir
4141910ee2 chore: remove validate ext file 2025-09-08 00:07:20 +07:00
Faisal Amir
1b035fd2f1 feat: allow user import model include mmproj file 2025-09-08 00:00:46 +07:00
lugnicca
9fcd9503e7 fix: error on message with "fetch" 2025-09-06 17:42:54 +02:00
Faisal Amir
a49008e02d enhancement: responsive dialog modals 2025-09-06 21:48:09 +07:00
lugnicca
66af5c7386 fix: use webprovider services to fetch models 2025-09-05 19:56:28 +02:00
lugnicca
045778406f Merge branch 'dev' into feat/model-selector 2025-09-05 19:51:17 +02:00
Ramon Perez
88fb1acc0a
Merge pull request #6372 from menloresearch/rp/api-docs
docs: add first‑class API Reference to Jan docs (Local + Server)
2025-09-05 21:44:07 +10:00
Ramon Perez
afcaf531ed separated scripts inside config file and fixed nav bar 2025-09-05 21:39:33 +10:00
Ramon Perez
aea474bf57 separated scripts inside config file and fixed nav bar 2025-09-05 21:33:59 +10:00
Nguyen Ngoc Minh
0e44d9340c
Merge pull request #6378 from menloresearch/chore/update-nginx-conf-jan-web
chore: update Dockerfile to use custom nginx.conf
2025-09-05 17:45:54 +07:00
Minh141120
153a8c635d chore: update Dockerfile to use custom nginx.conf 2025-09-05 17:26:22 +07:00
Nguyen Ngoc Minh
49ca18ca6b
Merge pull request #6377 from menloresearch/ci/update-paths-jan-server-web
ci: add paths for jan server web
2025-09-05 17:19:41 +07:00
Ramon Perez
9e8dc9f84a smol fix to nav bar 2025-09-05 20:13:04 +10:00
Ramon Perez
17da6d4ada small updates to readme, index, local-server 2025-09-05 20:05:44 +10:00
Minh141120
354cda8c35 refactor: install deps step 2025-09-05 16:51:43 +07:00
Minh141120
82206954e9 chore: edit preview url on pr comments 2025-09-05 16:48:52 +07:00
Minh141120
58cdb61ad7 chore: update paths 2025-09-05 16:41:10 +07:00
Minh141120
f11899ddb5 chore: remove pre-install folders from paths 2025-09-05 16:39:31 +07:00
Minh141120
c3a44dd54e chore: update missing paths 2025-09-05 16:38:52 +07:00
Minh141120
4d7bf5271d ci: add paths for jan server web 2025-09-05 16:31:50 +07:00
Ramon Perez
c5ea4cb8f9
Merge branch 'dev' into rp/api-docs 2025-09-05 19:20:29 +10:00
Dinh Long Nguyen
d490174544
feat: Web use jan model (#6374)
* call jan api

* fix lint

* ci: add jan server web

* chore: add Dockerfile

* clean up ui ux and support for reasoning fields, make app spa

* add logo

* chore: update tag for preview image

* chore: update k8s service name

* chore: update image tag and image name

* fixed test

---------

Co-authored-by: Minh141120 <minh.itptit@gmail.com>
Co-authored-by: Nguyen Ngoc Minh <91668012+Minh141120@users.noreply.github.com>
2025-09-05 16:18:30 +07:00
Ramon Perez
13e05809a9 changed favicon 2025-09-05 19:13:47 +10:00
Ramon Perez
3a0e114715 docs: add first‑class API Reference to Jan docs (Local + Server) 2025-09-05 18:57:27 +10:00
Ramon Perez
1e6cf8d771 docs: add first‑class API Reference to Jan docs (Local + Server) 2025-09-05 11:21:43 +10:00
Dinh Long Nguyen
a30eb7f968
feat: Jan Web (reusing Jan Desktop UI) (#6298)
* add platform guards

* add service management

* fix types

* move to zustand for servicehub

* update App Updater

* update tauri missing move

* update app updater

* refactor: move PlatformFeatures to separate const file

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

* change tauri fetch name

* update implementation

* update extension fetch

* make web version run properly

* disabled unused web settings

* fix all tests

* fix lint

* fix tests

* add mock for extension

* fix build

* update make and mise

* fix tsconfig for web-extensions

* fix loader type

* cleanup

* fix test

* update error handling + mcp should be working

* Update mcp init

* use separate is_web_app build property

* Remove fixed model catalog url

* fix additional tests

* fix download issue (event emitter not implemented correctly)

* Update Title html

* fix app logs

* update root tsx render timing

---------

Co-authored-by: Claude <noreply@anthropic.com>
2025-09-05 01:47:46 +07:00
hiento09
1b74772d07
feat: download llamacpp backend fail back to cdn (#6361)
* feat: download llamacpp backend fail back to cdn incase github api encounters errors
2025-09-04 09:39:16 +07:00
Faisal Amir
b2c4e89402
Merge pull request #6364 from menloresearch/feat/local-api-server
feat: allow see Apikey when server local status running
2025-09-03 20:05:57 +07:00
Faisal Amir
f886434c59
Merge pull request #6366 from menloresearch/fix/search-model-hub
fix: search hgf repo and downloaded filter
2025-09-03 20:05:50 +07:00
Faisal Amir
38629afc89 chore: avoid duplicated fn 2025-09-03 18:37:49 +07:00
Faisal Amir
5f9f766965 fix: search hgf repo and downloaded filter 2025-09-03 18:31:07 +07:00
Faisal Amir
2801fde181
Merge pull request #6363 from menloresearch/fix/timestamp-issue
fix: remove timezone specific from utils
2025-09-03 18:04:51 +07:00
Faisal Amir
cb4641e4ad feat: allow see apikey when server local status running 2025-09-03 17:55:52 +07:00
Faisal Amir
0ea9da95c8 fix: remove timezone specific from utils 2025-09-03 17:12:47 +07:00
Faisal Amir
08e756f27b
Merge pull request #6359 from menloresearch/docs/update-web-font
chore: update docs font
2025-09-03 13:22:54 +07:00
Faisal Amir
8db764c426 chore: update docs font 2025-09-03 10:13:08 +07:00
lugnicca
3d0ce15fe8 fix: prevent stale provider model requests from polluting UI state 2025-09-02 18:19:12 +02:00
lugnicca
70bf257e75 fix: put refresh button directly in input instead of in dropdown 2025-09-02 18:18:05 +02:00
Faisal Amir
8c4a88a182
Merge pull request #6346 from menloresearch/fix/btn-copy-codeblock
chore: fix id code-block for avoid duplicate same state
2025-09-02 15:28:05 +07:00
Nguyen Ngoc Minh
9a4e703d6a
Merge pull request #6344 from theproductiveprogrammer/dev
fix: mise build failing on mac
2025-09-02 12:17:05 +07:00
Charles L
17ccc9dca9 feat: install rustup requirements for MacOS universal builds 2025-09-02 14:49:02 +10:00
Faisal Amir
1544aac663 chore: change useMemo to useEffect to avoid side effect 2025-09-02 09:40:29 +07:00
Faisal Amir
12118192ef chore: fix id codeblock for avoid duplicate same state 2025-09-01 13:02:53 +07:00
Charles L
d9e6199835 fix: mise build failing 2025-09-01 14:02:31 +10:00
Ramon Perez
c19a0df16e
Merge pull request #6335 from menloresearch/rp/docs-v0.6.9-2
hotfix: changed website theme
2025-08-29 18:38:22 +10:00
Ramon Perez
77877ec15f removed unnecessary packages 2025-08-29 18:35:12 +10:00
Ramon Perez
0d51a13cc7 changed website theme 2025-08-29 18:09:11 +10:00
Dinh Long Nguyen
88decc95aa
Merge pull request #6333 from menloresearch/release/v0.6.9 2025-08-29 11:08:26 +07:00
Ramon Perez
f14d23d719
Merge pull request #6324 from menloresearch/rp/docs-v0.6.9-1
hotfix: fixed home page hyperlink and extension gif
2025-08-28 22:59:35 +10:00
Ramon Perez
9665e6e765 fixed home page hyperlink and extension gif 2025-08-28 22:52:37 +10:00
Ramon Perez
5ec612d74f fixed home page hyperlink and extension gif 2025-08-28 22:48:23 +10:00
Ramon Perez
478902633f
Merge pull request #6323 from menloresearch/rp/docs-v0.6.9
docs: Major restructure and consolidation
2025-08-28 22:30:21 +10:00
Ramon Perez
e36928e2e1 extension mbs reduced 2025-08-28 22:25:04 +10:00
Ramon Perez
71c00cae2c fixed path issue 2025-08-28 21:57:45 +10:00
Ramon Perez
5048593337
Update website/src/content/docs/jan/mcp-examples/search/serper.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-28 21:57:07 +10:00
Ramon Perez
db6a3105be fixed path issue 2025-08-28 21:54:01 +10:00
Ramon Perez
786f5f801f fixed path issue 2025-08-28 21:51:53 +10:00
Ramon Perez
798cae28a9 Merge branch 'dev' into rp/docs-v0.6.9 2025-08-28 21:47:25 +10:00
Ramon Perez
d3edc0dc96 all images 2025-08-28 21:46:36 +10:00
Ramon Perez
605322c917 images for new tutorials 2025-08-28 21:45:23 +10:00
Ramon Perez
cd41e9f140 astro config and new images 2025-08-28 21:43:19 +10:00
Ramon Perez
0793ce47e2 reorganised content and new sections 2025-08-28 21:42:28 +10:00
Ramon Perez
94ca9ba902 changelog added 2025-08-28 21:41:42 +10:00
Ramon Perez
eaec02bf6b gifs with browser extension and image support 2025-08-28 21:40:13 +10:00
Akarshan Biswas
5fae954ac5
fix: Use 80% total memory for compatibility check (#6321)
* fix: Use 80% total memory for compatibility check

* refactor: extract usable memory percentage to named constant

Extract the hardcoded 0.8 multiplier into a named constant
USABLE_MEMORY_PERCENTAGE for better readability and maintainability.
2025-08-28 14:50:00 +05:30
Dinh Long Nguyen
2c6430313c
Bring back QA changes 0.6.9 (#6320)
* fix: check for env value before setting (#6266)

* fix: check for env value before setting

* Use empty instead of none

* fix: update linux build script to be consistent with CI (#6269)

The local build script for Linux was failing due to a bundling error. This commit updates the `build:tauri:linux` script in `package.json` to be consistent with the CI build pipeline, which resolves the issue.

The updated script now includes:
- **`NO_STRIP=1`**: This environment variable prevents the `linuxdeploy` utility from stripping debugging symbols, which was a potential cause of the bundling failure.
- **`--verbose`**: This flag provides more detailed output during the build, which can be useful for debugging similar issues in the future.

* fix: compatibility imported model

* fix: update copy mmproj setting desc

* fix: toggle vision for remote model

* chore: add tooltip visions

* chore: show model setting only for local provider

* fix/update-ui-info

* chore: update filter hub while searching

* fix: system monitor window permission

* chore: update credit description

* chore: bundle license to app

* chore: bundle license to resource mac

* chore: bundle license to linux dist

* chore: relocate LICENSE to resources folder

* fix: handle paste image on linux

* fix: handle copy image from browser in linux

* feat: add regression checklist

* fix: mcp cleanup dropodown tool availabel and sort list

* fix: sort list when add server

* fix: mcp sort list

* fix: handle conditional UI regenerate resp

* fix: code generation more than 300 line

* fix: handle checking compatible gated model

* chore: update test

* chore: remove log

* chore: fix status

* chore: fix status model id

* make validation message infinite (#6318)

---------

Co-authored-by: Akarshan Biswas <akarshan.biswas@gmail.com>
Co-authored-by: Faisal Amir <urmauur@gmail.com>
Co-authored-by: Minh141120 <minh.itptit@gmail.com>
Co-authored-by: Nguyen Ngoc Minh <91668012+Minh141120@users.noreply.github.com>
2025-08-28 14:27:08 +07:00
Dinh Long Nguyen
bf15036ef8
Merge branch 'dev' into release/v0.6.9 2025-08-28 14:13:08 +07:00
Faisal Amir
7a657477de
Merge pull request #6316 from menloresearch/fix/handle-checking-model-gated
fix: handle checking model gated
2025-08-28 13:58:24 +07:00
Dinh Long Nguyen
eab4b277a2
make validation message infinite (#6318) 2025-08-28 13:47:46 +07:00
Faisal Amir
328d680f73 chore: fix status model id 2025-08-28 13:15:58 +07:00
Faisal Amir
5257a24181 chore: fix status 2025-08-28 13:10:08 +07:00
Faisal Amir
11a7bf7331 chore: remove log 2025-08-28 13:04:13 +07:00
Faisal Amir
85b614f44a chore: update test 2025-08-28 12:58:12 +07:00
Faisal Amir
6bb66b2b93 fix: handle checking compatible gated model 2025-08-28 12:57:11 +07:00
Faisal Amir
8166f3a32f
Merge pull request #6312 from menloresearch/fix/code-generation
fix: code generation more than 300 line
2025-08-28 00:38:19 +07:00
Faisal Amir
ca20828532 fix: code generation more than 300 line 2025-08-28 00:17:43 +07:00
Faisal Amir
95d2f0f86f
Merge pull request #6309 from menloresearch/fix/handle-regenerate-resp
fix: handle conditional UI regenerate resp
2025-08-28 00:02:18 +07:00
Faisal Amir
5fcf36ed8e fix: handle conditional UI regenerate resp 2025-08-27 23:23:36 +07:00
Faisal Amir
a7a5a5ab67
Merge pull request #6305 from menloresearch/fix/mcp-edit-and-sort
fix: mcp cleanup dropodown tool availabel and sort list
2025-08-27 20:33:05 +07:00
Faisal Amir
d922d7454d fix: mcp sort list 2025-08-27 18:25:13 +07:00
Faisal Amir
742f9c1a70 fix: sort list when add server 2025-08-27 18:17:55 +07:00
Faisal Amir
75d189900c fix: mcp cleanup dropodown tool availabel and sort list 2025-08-27 18:08:23 +07:00
Nguyen Ngoc Minh
1fa288f11b
Merge pull request #6302 from menloresearch/feat/add-regresson-checklist
feat: add regression checklist
2025-08-27 17:14:14 +07:00
Minh141120
b095d7150c feat: add regression checklist 2025-08-27 17:12:49 +07:00
Faisal Amir
861590b9ac
Merge pull request #6299 from menloresearch/fix/handle-paste-linux
fix: handle paste image on linux
2025-08-26 22:30:18 +07:00
Faisal Amir
b93f77a9f5 fix: handle copy image from browser in linux 2025-08-26 21:37:32 +07:00
Faisal Amir
b915f1f674 fix: handle paste image on linux 2025-08-26 20:44:23 +07:00
Nguyen Ngoc Minh
a7ed4fe1dc
Merge pull request #6294 from menloresearch/chore/bundle-license-to-app
chore: bundle license to app
2025-08-26 08:42:58 +00:00
Dinh Long Nguyen
02f7b88dab
Bring QA (0.6.9) changes to dev (#6296)
* fix: check for env value before setting (#6266)

* fix: check for env value before setting

* Use empty instead of none

* fix: update linux build script to be consistent with CI (#6269)

The local build script for Linux was failing due to a bundling error. This commit updates the `build:tauri:linux` script in `package.json` to be consistent with the CI build pipeline, which resolves the issue.

The updated script now includes:
- **`NO_STRIP=1`**: This environment variable prevents the `linuxdeploy` utility from stripping debugging symbols, which was a potential cause of the bundling failure.
- **`--verbose`**: This flag provides more detailed output during the build, which can be useful for debugging similar issues in the future.

* fix: compatibility imported model

* fix: update copy mmproj setting desc

* fix: toggle vision for remote model

* chore: add tooltip visions

* chore: show model setting only for local provider

* fix/update-ui-info

* chore: update filter hub while searching

* fix: system monitor window permission

* chore: update credit description

---------

Co-authored-by: Akarshan Biswas <akarshan.biswas@gmail.com>
Co-authored-by: Faisal Amir <urmauur@gmail.com>
Co-authored-by: Minh141120 <minh.itptit@gmail.com>
Co-authored-by: Nguyen Ngoc Minh <91668012+Minh141120@users.noreply.github.com>
2025-08-26 15:35:56 +07:00
Minh141120
0efdf54819 chore: relocate LICENSE to resources folder 2025-08-26 14:18:35 +07:00
Minh141120
8cdb9e943d chore: bundle license to linux dist 2025-08-26 13:57:45 +07:00
Minh141120
e2adb3037a chore: bundle license to resource mac 2025-08-26 12:30:23 +07:00
Minh141120
87f3b168c9 chore: bundle license to app 2025-08-26 11:17:59 +07:00
Nguyen Ngoc Minh
cad5b5642c
Merge pull request #6288 from menloresearch/chore/update-credit-desc
chore: update credit description
2025-08-25 20:46:38 -07:00
Minh141120
f76e337d38 chore: update credit description 2025-08-26 10:08:54 +07:00
Faisal Amir
a92aa4e3f1
Merge pull request #6283 from menloresearch/fix/ui-feedback
fix: update ui info
2025-08-25 20:10:26 +07:00
Faisal Amir
128ea578bd
Merge pull request #6285 from menloresearch/fix/permission-system-monitor
fix: system monitor window permission
2025-08-25 20:10:15 +07:00
Ramon Perez
b5fbba6c81
Merge pull request #6273 from menloresearch/rp/v2-docs-improvements
removed orphan pages and polished wording of main page
2025-08-25 22:01:37 +10:00
Ramon Perez
8cba22937e
Update docs/src/pages/docs/index.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-25 21:56:28 +10:00
Ramon Perez
2a5cffd64c Merge branch 'dev' into rp/v2-docs-improvements 2025-08-25 21:55:16 +10:00
Ramon Perez
31364dd9f8 main pages revamped and new docs updated 2025-08-25 21:53:04 +10:00
Faisal Amir
4137821e53 fix: system monitor window permission 2025-08-25 17:38:30 +07:00
Faisal Amir
e376314315 chore: update filter hub while searching 2025-08-25 16:51:30 +07:00
Faisal Amir
e73a710c06 fix/update-ui-info 2025-08-25 16:45:59 +07:00
Faisal Amir
2472cc949a
Merge pull request #6281 from menloresearch/fix/handle-vision-remote-model
fix: handle manual toggle vision for remote model
2025-08-25 13:36:27 +07:00
Faisal Amir
62eb422934 chore: show model setting only for local provider 2025-08-25 11:26:56 +07:00
Faisal Amir
9ff46757bb
Merge pull request #6282 from menloresearch/fix/blog-og-image
fix: jan research blog `ogimage`
2025-08-25 11:04:50 +07:00
Faisal Amir
91eb37c240 fix/blog-og-image 2025-08-25 10:59:49 +07:00
Faisal Amir
8d06c3addf chore: add tooltip visions 2025-08-25 10:47:18 +07:00
Faisal Amir
45ba949d96 fix: toggle vision for remote model 2025-08-25 10:28:18 +07:00
lugnicca
1a6a37c003 fix: escape key was closing modal instead of only combobox and remove arrow left/righ closing combobox 2025-08-24 00:40:02 +02:00
lugnicca
6c0e6dce06 fix: remove unused keyRepeatTimeoutRef 2025-08-23 18:32:12 +02:00
lugnicca
639bd5fb27 fix: set Escape in keyboard navigation 2025-08-23 18:08:29 +02:00
lugnicca
aa568e6290 fix: remove ModelProvider type 2025-08-23 15:07:42 +02:00
lugnicca
1bf5802a68 refactor: update MockModelProvider type to use ModelProvider and clean up test setup 2025-08-23 02:37:15 +02:00
lugnicca
4e8dd9281f refactor: simplify event handling and fix test setup in ModelCombobox 2025-08-23 02:37:14 +02:00
lugnicca
9a68631d39 refactor: more modular error handling in fetchModelsFromProvider function 2025-08-23 02:37:14 +02:00
lugnicca
f35e6cdae8 refactor: clean model selector and add more tests 2025-08-23 02:37:14 +02:00
lugnicca
3339629747 test: add unit tests for ModelCombobox, useProviderModels and providers 2025-08-23 02:37:14 +02:00
lugnicca
5d9c3ab462 feat: add model selector with fetching from /v1/models endpoints when adding models 2025-08-23 02:36:38 +02:00
Emre Can Kartal
8548e0fb12
Merge pull request #6274 from menloresearch/fix/og-image-date-update
docs: fix OG image URL and update publication date
2025-08-22 15:52:25 +03:00
Emre Can Kartal
82eb18bc00
Merge branch 'dev' into fix/og-image-date-update 2025-08-22 15:41:01 +03:00
eckartal
e331e8fb76 docs: fix OG image URL and update publication date
- Fix OG image URL to full https://jan.ai/post/_assets/jan-research.jpeg for Twitter preview
- Update publication date to 2025-08-22
- Ensure social media platforms can properly display the image
2025-08-22 15:33:58 +03:00
Emre Can Kartal
61ae8eb88b
Merge pull request #6197 from menloresearch/blog/jan-v1-research
docs: add blog for jan v1 research
2025-08-22 15:00:07 +03:00
eckartal
37110ea262 docs: update Jan v1 research blog with professional styling and OG image
- Updated title to 'Jan v1 for Deep Research'
- Added professional cookbook-style formatting inspired by OpenAI guide
- Added performance summary with benchmark results (91.1% vs 83.2%)
- Added new OG image (jan-research.jpeg)
- Improved content structure and readability
2025-08-22 14:35:17 +03:00
Faisal Amir
63acb3a275
Merge pull request #6272 from menloresearch/fix/copy-mmproj-setting
fix: update copy offload_mmproj setting desc
2025-08-22 17:06:09 +07:00
Ramon Perez
51086f39ca removed orphan pages and polished wording of main page 2025-08-22 18:59:22 +10:00
Faisal Amir
7801f9c330 fix: update copy mmproj setting desc 2025-08-22 15:27:07 +07:00
Faisal Amir
f7e2c49154
Merge pull request #6271 from menloresearch/fix/compatibility-imported-model
fix: compatibility imported model
2025-08-22 14:06:05 +07:00
Faisal Amir
f6e4d55f5e fix: compatibility imported model 2025-08-22 13:20:57 +07:00
Akarshan Biswas
39e8d3b80c
fix: update linux build script to be consistent with CI (#6269)
The local build script for Linux was failing due to a bundling error. This commit updates the `build:tauri:linux` script in `package.json` to be consistent with the CI build pipeline, which resolves the issue.

The updated script now includes:
- **`NO_STRIP=1`**: This environment variable prevents the `linuxdeploy` utility from stripping debugging symbols, which was a potential cause of the bundling failure.
- **`--verbose`**: This flag provides more detailed output during the build, which can be useful for debugging similar issues in the future.
2025-08-22 09:22:22 +05:30
new5558
9d15453b66 docs: update jan v1 research blog title and keywords 3 2025-08-22 09:39:34 +07:00
Akarshan Biswas
64a608039b
fix: check for env value before setting (#6266)
* fix: check for env value before setting

* Use empty instead of none
2025-08-21 22:55:49 +05:30
Nguyen Ngoc Minh
2cf6464780
Merge pull request #6264 from menloresearch/ci/add-trigger-condition-assign-milestone
ci: add job condition for auto assign milestone
2025-08-21 14:35:47 +00:00
Minh141120
2000fc31b5 ci: add job condition for auto assign milestone 2025-08-21 21:25:08 +07:00
new5558
1180f3e42b docs: update jan v1 research blog title and keywords 2 2025-08-21 18:25:02 +07:00
new5558
404695f1d8 docs: update jan v1 research blog title and keywords 2025-08-21 18:19:25 +07:00
Piotr Orzechowski
ef90f07db8
fix: add missing Polish translations (#6262) 2025-08-21 17:46:48 +07:00
Akarshan Biswas
510c70bdf7
feat: Add model compatibility check and memory estimation (#6243)
* feat: Add model compatibility check and memory estimation

This commit introduces a new feature to check if a given model is supported based on available device memory.

The change includes:
- A new `estimateKVCache` method that calculates the required memory for the model's KV cache. It uses GGUF metadata such as `block_count`, `head_count`, `key_length`, and `value_length` to perform the calculation.
- An `isModelSupported` method that combines the model file size and the estimated KV cache size to determine the total memory required. It then checks if any available device has sufficient free memory to load the model.
- An updated error message for the `version_backend` check to be more user-friendly, suggesting a stable internet connection as a potential solution for backend setup failures.

This functionality helps prevent the application from attempting to load models that would exceed the device's memory capacity, leading to more stable and predictable behavior.

fixes: #5505

* Update extensions/llamacpp-extension/src/index.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Update extensions/llamacpp-extension/src/index.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Extend this to available system RAM if GGML device is not available

* fix: Improve model metadata and memory checks

This commit refactors the logic for checking if a model is supported by a system's available memory.

**Key changes:**
- **Remote model support**: The `read_gguf_metadata` function can now fetch metadata from a remote URL by reading the file in chunks.
- **Improved KV cache size calculation**: The KV cache size is now estimated more accurately by using `attention.key_length` and `attention.value_length` from the GGUF metadata, with a fallback to `embedding_length`.
- **Granular memory check statuses**: The `isModelSupported` function now returns a more specific status (`'RED'`, `'YELLOW'`, `'GREEN'`) to indicate whether the model weights or the KV cache are too large for the available memory.
- **Consolidated logic**: The logic for checking local and remote models has been consolidated into a single `isModelSupported` function, improving code clarity and maintainability.

These changes provide more robust and informative model compatibility checks, especially for models hosted on remote servers.

* Update extensions/llamacpp-extension/src/index.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Make ctx_size optional and use sum free memory across ggml devices

* feat: hub and dropdown model selection handle model compatibility

* feat: update bage model info color

* chore: enable detail page to get compatibility model

* chore: update copy

* chore: update shrink indicator UI

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-08-21 16:13:50 +05:30
Akarshan Biswas
9c25480c7b
fix: Update placeholder text and error message (#6263)
This commit improves the clarity of the llama.cpp extension.

- Corrected a placeholder example from `GGML_VK_VISIBLE_DEVICES='0,1'` to `GGML_VK_VISIBLE_DEVICES=0,1` for better accuracy.
- Changed an ambiguous error message from `"Failed to load llama-server: ${error}"` to the more specific `"Failed to load llamacpp backend"`.
2025-08-21 16:01:31 +05:30
Akarshan Biswas
5c3a6fec32
feat: Add support for custom environmental variables to llama.cpp (#6256)
This commit adds a new setting `llamacpp_env` to the llama.cpp extension, allowing users to specify custom environment variables. These variables are passed to the backend process when it starts.

A new function `parseEnvFromString` is introduced to handle the parsing of the semicolon-separated key-value pairs from the user input. The environment variables are then used in the `load` function and when listing available devices. This enables more flexible configuration of the llama.cpp backend, such as specifying visible GPUs for Vulkan.

This change also updates the Tauri command `get_devices` to accept environment variables, ensuring that device discovery respects the user's settings.
2025-08-21 15:50:37 +05:30
Louis
5c4deff215
Merge pull request #6260 from menloresearch/fix/bring-back-manual-model-capability-edit
fix: bring back manual model capability edit modal
2025-08-21 16:31:17 +07:00
Dinh Long Nguyen
32a2ca95b6
feat: gguf file size + hash validation (#5266) (#6259)
* feat: gguf file size + hash validation

* fix tests fe

* update cargo tests

* handle asyn download for both models and mmproj

* move progress tracker to models

* handle file download cancelled

* add cancellation mid hash run
2025-08-21 16:17:58 +07:00
Nguyen Ngoc Minh
41b4cc3bb3
Merge pull request #6261 from menloresearch/ci/add-autoqa-migration-workflow
ci: add autoqa migration workflow
2025-08-21 09:15:42 +00:00
Nguyen Ngoc Minh
e096c3114f
Create autoqa-migration.yml 2025-08-21 16:14:13 +07:00
Louis
8d3fcf1680
Merge pull request #6257 from menloresearch/fix/enable-back-app-language-setting
fix: enable back app language setting
2025-08-21 13:15:31 +07:00
Louis
9bc243c3f7
Merge branch 'dev' into fix/enable-back-app-language-setting 2025-08-21 12:53:21 +07:00
Louis
8e7378b70f
Merge pull request #6255 from menloresearch/fix/remove-experimental-toggle
fix: remove experimental toggle
2025-08-21 12:51:25 +07:00
Faisal Amir
7b9e752301
Merge pull request #6250 from menloresearch/feat/local-api-server
feat: run on startup setting for local api server
2025-08-21 12:43:13 +07:00
Louis
65cb473d25
fix: enable back app language setting 2025-08-21 12:30:30 +07:00
Louis
ec1a695e06
Merge pull request #5874 from 0rzech/polish-translation
feat: add Polish translation
2025-08-21 12:27:00 +07:00
Louis
6c44ec558d
Merge pull request #6211 from cmppoon/dev
fix: emoji picker remains stuck in the open state in AddEditAssistant component
2025-08-21 12:16:09 +07:00
Louis
8de5c1709b
fix: test 2025-08-21 12:01:45 +07:00
Louis
cfbc6b9150
fix: remove experimental toggle 2025-08-21 11:54:34 +07:00
Louis
6b55812739
Merge pull request #6249 from menloresearch/feat/detect-cpu-arch-run-time
feat: detect cpu arch in runtime
2025-08-21 11:51:13 +07:00
Louis
cd5b8b3e6f
Merge pull request #6205 from kamal/current-date-instruction
feat: support inserting current date into assistant prompt
2025-08-21 11:41:38 +07:00
Louis
e6587844d0
Merge branch 'dev' into current-date-instruction 2025-08-21 11:41:30 +07:00
Louis
51a9021994
fix: test 2025-08-21 11:30:48 +07:00
cmuangs
7076a69e3a
Merge branch 'dev' into dev 2025-08-21 12:28:12 +08:00
Louis
3a36353b02
fix: backend variant selection 2025-08-21 10:54:35 +07:00
Louis
973a8dd8cc
fix: simplify cpu arch detection 2025-08-21 10:47:39 +07:00
Louis
bf3e9c5b1e
Merge pull request #6252 from menloresearch/feat/mcp-error-handling
feat: MCP server error handling
2025-08-21 09:32:41 +07:00
Piotr Orzechowski
83620e127e feat: add Polish translation 2025-08-21 00:18:23 +02:00
Louis
6850dda108
feat: MCP server error handling 2025-08-20 23:42:12 +07:00
Faisal Amir
f4829f7e72
Merge pull request #6251 from menloresearch/enhancement/vision-icon-hub
enhancement: vision icon hub model list
2025-08-20 22:45:24 +07:00
Faisal Amir
39df7b22b9 chore: rename key runOnStartup from hooks useLocalApiServer 2025-08-20 22:37:45 +07:00
Louis
2398c0ab33
Update src-tauri/plugins/tauri-plugin-hardware/src/tests.rs
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-20 22:22:25 +07:00
Faisal Amir
68f8c2d3f8 enhancement: change icon vision 2025-08-20 22:21:42 +07:00
Faisal Amir
cfa68c5500 feat: run on startup settin for local api server 2025-08-20 21:56:53 +07:00
Louis
ebae86f3e6
feat: detect cpu arch in runtime 2025-08-20 21:37:34 +07:00
Faisal Amir
c2cdb48ff3 enhancement: vision icon on model hub 2025-08-20 21:01:38 +07:00
Nguyen Ngoc Minh
f7df8d2a38
Merge pull request #6248 from menloresearch/ci/add-autoqa-reliability
ci: add autoqa reliability workflow for windows
2025-08-20 11:10:37 +00:00
Minh141120
76dfe027ab chore: remove local artifact inputs 2025-08-20 18:08:38 +07:00
Minh141120
4059d7a7ec ci: add autoqa reliability workflow for windows 2025-08-20 18:03:27 +07:00
Louis
b6cf19a33f
Merge pull request #6241 from menloresearch/feat/allow-user-to-set-limit-assistant-tool-steps
feat: allow user to set max_attempt for MCP to avoid looping
2025-08-20 14:49:11 +07:00
Akarshan Biswas
906b87022d
chore: re enable reasoning_content in backend (#6228)
* chore: re enable reasoning_content in backend

* chore: handle reasoning_content

* chore: refactor get reasoning content

* chore: update PR review

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-08-20 13:06:21 +05:30
Faisal Amir
43ab6dfc65
Merge pull request #6246 from menloresearch/fix/sort-filter-hub
fix: hidden sort filter when searching model
2025-08-20 14:36:15 +07:00
Faisal Amir
1ad29077e3 fix: hiden sort filter when searching model 2025-08-20 14:16:45 +07:00
Dinh Long Nguyen
6519327244
fix: local api server log (#6244) 2025-08-20 14:13:27 +07:00
Nguyen Ngoc Minh
263960752e
Merge pull request #6245 from menloresearch/chore/update-astro-docs-domain
chore: update new domain for jan docs
2025-08-20 07:00:56 +00:00
Minh141120
df4491e568 chỏe: update new domain for jan docs 2025-08-20 13:57:52 +07:00
Faisal Amir
ee0b29d9f0
Merge pull request #6242 from menloresearch/enhancement/remove-validate-extension
enhancement: remove validate file extension from select file when import gguf
2025-08-20 13:30:59 +07:00
Louis
c3b043eafa
Merge pull request #6203 from Louis454545/fix/scroll-jump-during-streaming-5939
fix: prevent scroll position jump when AI completes response while user reading
2025-08-20 13:06:32 +07:00
Faisal Amir
8f0999cc37 chore: update layout setting assistant 2025-08-20 13:00:59 +07:00
Faisal Amir
f96ff52506 enhancement: remove validate file extension from select file 2025-08-20 12:54:08 +07:00
Louis
48422e0a4b
chore: add min to the call steps 2025-08-20 12:52:01 +07:00
Louis
c018713676
feat: allow user to set max_attempt for MCP to avoid looping 2025-08-20 12:42:54 +07:00
Akarshan Biswas
0fc3dc6841
Fix: Validate GGUF files before loading (#6238)
This commit adds a GGUF validation check for both the main model file and the `mmproj` file (if present) before they are loaded. This prevents the extension from crashing if an invalid GGUF file is provided.

The `GgufMetadata` interface and `loadMetadata` function were removed as the `readGgufMetadata` is now invoked directly. The code has also been refactored to be more readable, with clearer variable names and more descriptive comments.
2025-08-20 10:31:19 +05:30
Louis
ecc9020452 fix: prevent scroll position jump when AI completes response while user reading
- Add userIntendedPositionRef to track user's deliberate scroll position during streaming
- Add wasStreamingRef to detect when streaming finishes
- Preserve user's reading position when they scroll away from bottom during AI response
- Restore intended position with smooth scroll when streaming completes
- Reset position tracking on thread changes and component initialization

Fixes #5939

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-08-20 10:24:37 +07:00
Dinh Long Nguyen
b0eec07a01
Add contributing section for jan (#6231) (#6232)
* Add contributing section for jan

* Update CONTRIBUTING.md

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-20 10:18:35 +07:00
Faisal Amir
a6e5273c7a
Merge pull request #6198 from Louis454545/fix/issue-6025-default-color-selection
fix: resolve issue #6025 - default color selection in appearance page
2025-08-20 10:12:49 +07:00
Faisal Amir
5481ee9e35
Merge pull request #6134 from menloresearch/feat/attachment-ui
feat: attachment UI
2025-08-20 10:04:32 +07:00
Faisal Amir
87af59b65d chore: update icon image instead paperclip 2025-08-20 09:46:57 +07:00
Louis
6efdd66bbd
Merge pull request #6236 from menloresearch/feat/add-tool-call-cancellation 2025-08-20 09:04:53 +07:00
Faisal Amir
6203a93325
Merge pull request #6233 from menloresearch/fix/import-model
fix: improve ux import model
2025-08-20 09:03:33 +07:00
Faisal Amir
109b6e8c3d
Merge pull request #6234 from menloresearch/fix/download-model
fix: downloaded model should from variant level instead of the model level
2025-08-20 09:02:50 +07:00
Kamal Fariz Mahyuddin
df27def9cb
Merge branch 'dev' into current-date-instruction 2025-08-19 14:40:08 -07:00
Louis
91f05b8f32
feat: add tool call cancellation 2025-08-19 23:27:12 +07:00
Faisal Amir
5155f19c9b chore: update data test id chat input 2025-08-19 22:56:16 +07:00
Faisal Amir
07b1101736 chore: enable attachment icon for remote provider 2025-08-19 22:46:45 +07:00
Faisal Amir
80dc491f9d chore: conditianal attachment and drag file to chat input 2025-08-19 22:46:45 +07:00
Faisal Amir
e3eb8e909b chore: attachment icon conditional 2025-08-19 22:46:45 +07:00
Akarshan Biswas
e761c439d7
feat: Pass API key via environment variable instead of command line argument (#6225)
This change modifies how the API key is passed to the llama-server process. Previously, it was sent as a command line argument (--api-key). This approach has been updated to pass the key via an environment variable (LLAMA_API_KEY).

This improves security by preventing the API key from being visible in the process list (ps aux on Linux, Task Manager on Windows, etc.), where it could potentially be exposed to other users or processes on the same system.

The commit also updates the Rust backend to read the API key from the environment variable instead of parsing it from the command line arguments.
2025-08-19 20:57:06 +05:30
Louis
df41bad465
fix: import 2025-08-19 22:16:24 +07:00
Faisal Amir
b828d3f84f chore: handle toaster failed import model 2025-08-19 22:07:30 +07:00
Louis
a210e2f13a
fix: timeout for completion request 2025-08-19 22:06:26 +07:00
Faisal Amir
6c612d8eba chore: seperate function handle import model 2025-08-19 22:01:14 +07:00
Faisal Amir
9e3237da38 fix: downloaded model hub screen should from variant level instead of the model level 2025-08-19 21:55:57 +07:00
Faisal Amir
6ee044d106 fix: validation import model 2025-08-19 21:29:18 +07:00
Faisal Amir
067f8b5447 chore: update attachment icon alignment 2025-08-19 20:00:47 +07:00
Akarshan
cffbe1a77b Increase timeout for fetch in llamacpp 2025-08-19 20:00:10 +07:00
Faisal Amir
fdc8e07f86 chore: update model setting include offload-mmproj 2025-08-19 20:00:08 +07:00
Faisal Amir
00674ec0d5 chore: update test case model service 2025-08-19 19:51:33 +07:00
Faisal Amir
9f39f0cdb8 fix: paste image chat input 2025-08-19 19:51:32 +07:00
Faisal Amir
050d38c0ab fix: convert search hgf repo include mmproj models 2025-08-19 19:51:32 +07:00
Akarshan
9afeb5e514 feat: Add offload_mmproj option and validation
This commit introduces a new configuration option offload_mmproj to the llamacpp extension.

The offload_mmproj setting allows users to control whether the multimodal projector model is offloaded to the GPU. By default, it's offloaded for better performance. If set to false, the projector model will remain on the CPU, which can be useful in low GPU memory scenarios, though image processing might take longer.

Additionally, this commit adds validate_mmproj_path to ensure the provided --mmproj path is valid and accessible, preventing issues during model loading.

This change also refactors some invoke calls for improved readability.
2025-08-19 19:51:29 +07:00
Faisal Amir
e04bb86171 chore: prevent drag image to replace the window, and enable shortcut copy and paste image 2025-08-19 19:51:02 +07:00
Faisal Amir
f70449fd98 chore: remove pdf attachement 2025-08-19 19:51:02 +07:00
Faisal Amir
ec9925ed5a chore: update copy validation format type 2025-08-19 19:51:01 +07:00
Faisal Amir
f95e17c047 chore: disable pdf for local model 2025-08-19 19:51:01 +07:00
Faisal Amir
cef3e122ff chore: send attachment file when send message 2025-08-19 19:51:01 +07:00
Faisal Amir
e9bd0f0bec chore: update alignment 2025-08-19 19:51:01 +07:00
Faisal Amir
5f1cb67ffc feat: enable attachment UI 2025-08-19 19:51:01 +07:00
Faisal Amir
926f3ab99a
Merge pull request #6226 from menloresearch/enhancement/offload-model-provider-disabled
enhancement: offload model when provider not active
2025-08-19 16:33:49 +07:00
Faisal Amir
f26d78dfe4
Merge pull request #6229 from menloresearch/fix/hide-model-provider-disabled
fix: Auto select model only for active provider
2025-08-19 16:33:45 +07:00
Louis
b32c8b372e
Merge pull request #6224 from menloresearch/fix/use-tauri-fetch-for-custom-providers
fix: should use custom fetch provided by app
2025-08-19 15:17:27 +07:00
Faisal Amir
cedf42d683 fix: Auto select model only for active provider 2025-08-19 14:47:02 +07:00
Dinh Long Nguyen
9ea9b7d87d
handle abort properly + finally clause to resolve (#6227) 2025-08-19 14:45:57 +07:00
Faisal Amir
872284b770 enhancement: offload model when provider not active 2025-08-19 14:18:39 +07:00
Louis
55390de070
Merge pull request #6222 from menloresearch/feat/model-tool-use-detection
feat: #5917 - model tool use capability should be auto detected
2025-08-19 13:55:08 +07:00
Louis
65f23fb387
fix: tokenjs should use custom fetch provided by app 2025-08-19 13:46:21 +07:00
Louis
d7cf258a40
fix: tool indicator in hub 2025-08-19 10:40:11 +07:00
Louis
0dc0a9a4a3
fix: tests 2025-08-19 09:57:10 +07:00
Louis
bfe671d7b4
feat: #5917 - model tool use capability should be auto detected 2025-08-19 09:51:36 +07:00
Louis
e43454d518
Merge pull request #6219 from menloresearch/fix/remove-retired-models-from-providers 2025-08-19 09:03:26 +07:00
Louis
3e6757300c
fix: update token.js to remove retired models 2025-08-18 22:33:20 +07:00
Dinh Long Nguyen
2d486d7b3a
feat: add support for reasoning fields (OpenRouter) (#6206)
* add support for reasoning fields (OpenRouter)

* reformat

* fix linter

* Update web-app/src/utils/reasoning.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-18 21:59:14 +07:00
Akarshan Biswas
5ad3d282af
fix: re-enable Vulkan backend in integrated GPUs with enough memory (#6215) 2025-08-18 17:31:01 +05:30
Faisal Amir
8f2f3ca352
Merge pull request #6214 from menloresearch/enhancement/disabled-form
enhancement: mcp disable save button when server name still empty
2025-08-18 14:12:52 +07:00
Faisal Amir
1eb1bb91ce chore: update placeholder 2025-08-18 12:17:24 +07:00
Faisal Amir
d2cc9cc13b enhancement: mcp disable save button when server name still empty 2025-08-18 12:13:55 +07:00
Louis
362324cb87
Merge pull request #6188 from menloresearch/feat/mcp-enhancement
feat: mcp enhancement
2025-08-18 09:55:44 +07:00
Chaiyapruek Muangsiri
9024e2d382 fix: emoji picker stuck in open state 2025-08-18 10:39:13 +08:00
Louis
2492d6f9d0
fix: http mcp with headers 2025-08-18 09:29:46 +07:00
Faisal Amir
b1b2ca1987
Merge pull request #6006 from menloresearch/feat/fav-model
🚀feat: allow user mark model as favorite
2025-08-17 23:14:26 +07:00
Louis
716d516a60
Merge pull request #6039 from menloresearch/blog/add-deepresearch-piece
blog: Add Deep Research Piece
2025-08-17 23:03:33 +07:00
Kamal Fariz Mahyuddin
b77c8932a6 feat: support inserting current date into assistant prompt 2025-08-17 00:24:00 -07:00
Louis
83b53210ee
Merge pull request #6092 from cmppoon/fix-default-predefine-color-palette
fix: default color not selected in appearance color palette
2025-08-16 20:17:25 +07:00
Louis
34fe0e1fa4
Merge pull request #6200 from Jasper-256/fix-issue-6199-jan-ui-bottlenecks-token-rendering-speed
Fix Issue #6199
2025-08-16 20:13:43 +07:00
Jasper Morgal
4ba56f1377 Fix Issue #6199
Fix Issue: Jan UI Bottlenecks Token Rendering Speed to ~300 TPS Despite Faster Cerebras API Output
2025-08-15 15:00:29 -07:00
Louis
38b0202365 fix: resolve issue #6025 - default color selection in appearance page
- Fix default color selection logic in all color picker components
- Use existing helper functions (isDefaultColor, isDefaultColorPrimary, etc.)
- Ensure default colors are properly highlighted when active
- Apply fix to all color pickers: primary, accent, destructive, main view, and background

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-08-15 19:00:13 +02:00
Ramon Perez
56fa4f9677
Merge pull request #6196 from menloresearch/rp/docs-v0.6.8
Docs reorg + new content for v0.6.8.

## What’s Changed
- Moved “MCP Examples” to “Tutorials” under Getting Started
- Added tutorials:
  - Linear MCP (issues, projects, comments, cycles)
  - Todoist MCP (create/list/update/complete/delete tasks)
- New model pages: Lucy (1.7B) and Jan‑v1 (4B)
- Added v0.6.8 changelog (engine fixes, docs updates, tutorials)
- Updated Overview page copy (ecosystem: Models, Applications, Tools)

## Notes
- No directory moves; nav only
- Quickstart stays minimal; Serper setup moved to tutorial
2025-08-15 22:18:51 +10:00
Ramon Perez
f58e425b35 removed files that were not needed anymore 2025-08-15 22:14:10 +10:00
Ramon Perez
d95f104e03 removed files that were not needed anymore 2025-08-15 22:10:24 +10:00
Ramon Perez
3f9f10d479 removed files that were not needed anymore 2025-08-15 22:05:50 +10:00
Ramon Perez
e96c5b2416 optimised large gifs 2025-08-15 22:01:43 +10:00
new5558
ee2e7487e7 docs: add jan-v1 research prompt blog 2025-08-15 18:57:37 +07:00
Ramon Perez
a3c7604374 removed unnecessary files causing ci to break 2025-08-15 21:51:50 +10:00
Ramon Perez
1444104418 removed unnecessary files causing ci to break 2025-08-15 21:47:33 +10:00
Ramon Perez
bf86512916 docs: preserve docs and website changes from rp/docs-v0.6.8 with latest dev base 2025-08-15 21:34:45 +10:00
Nguyen Ngoc Minh
8d1ad031fa
Merge pull request #6193 from menloresearch/chore/update-flatpak-manifest
chore: replace md5 with sha256 for CUDA
2025-08-15 16:39:15 +07:00
Nguyen Ngoc Minh
c38f8a90a6
chore: replace md5 with sha256 for CUDA 2025-08-15 16:37:05 +07:00
Ramon Perez
fd3acc39d9
Merge branch 'dev' into blog/add-deepresearch-piece 2025-08-15 17:03:57 +10:00
Louis
54e0f9b595
feat: add connection timeout setting 2025-08-15 12:45:02 +07:00
Louis
c8d9592ab8
chore: mcp group server, action and import json 2025-08-15 11:37:21 +07:00
Louis
25043dda7b
feat: MCP streamable http and sse transports 2025-08-15 10:12:41 +07:00
Louis
13a1969150
feat: MCP - State update 2025-08-15 10:02:06 +07:00
Dinh Long Nguyen
e1c8d98bf2
Backend Architecture Refactoring (#6094) (#6162)
* add llamacpp plugin

* Refactor llamacpp plugin

* add utils plugin

* remove utils folder

* add hardware implementation

* add utils folder + move utils function

* organize cargo files

* refactor utils src

* refactor util

* apply fmt

* fmt

* Update gguf + reformat

* add permission for gguf commands

* fix cargo test windows

* revert yarn lock

* remove cargo.lock for hardware plugin

* ignore cargo.lock file

* Fix hardware invoke + refactor hardware + refactor tests, constants

* use api wrapper in extension to invoke hardware call + api wrapper build integration

* add newline at EOF (per Akarshan)

* add vi mock for getSystemInfo
2025-08-15 08:59:01 +07:00
Nguyen Ngoc Minh
9732a9b8b9
Merge pull request #6182 from menloresearch/refactor/flathub-submission
refactor: flathub submission
2025-08-15 00:08:47 +07:00
Minh141120
9e7de65990 refactor: flathub submission 2025-08-15 00:04:20 +07:00
Akarshan Biswas
1d4a6a72ed
Feat: Add flatpak manifest (#4732)
* Chore: Add flatpak manifest

* Update flatpak to new release

* update

* Update to 0.6.7

* re-enable cuda toolkit

* add uv to manifest and remove unused yml file

* fixup python3-uv

* fix uv installation

* Update template to 0.6.8

* chore: update sha256 for .deb

---------

Co-authored-by: Nguyen Ngoc Minh <91668012+Minh141120@users.noreply.github.com>
2025-08-14 19:20:32 +05:30
Nguyen Ngoc Minh
298f408d3f
Merge pull request #6177 from menloresearch/feat/ci-flatpak
feat: add flatpak ci
2025-08-14 17:09:33 +07:00
Minh141120
aa97159837 Merge branch 'dev' into feat/ci-flatpak 2025-08-14 16:46:16 +07:00
Nguyen Ngoc Minh
b9d6aec0e3
Merge pull request #6175 from menloresearch/fix/feature-toggle-auto-updater
fix: feature toggle auto updater
2025-08-14 15:27:07 +07:00
Minh141120
16652e7bf9 feat: add flatpak ci 2025-08-14 15:04:49 +07:00
Louis
dcb46174ff
fix: test 2025-08-14 14:30:43 +07:00
Minh141120
aa8fb0464c Merge branch 'dev' into fix/feature-toggle-auto-updater 2025-08-14 13:42:27 +07:00
Minh141120
388959a1fe chore: gate check auto updater 2025-08-14 12:39:48 +07:00
Faisal Amir
a66d83c598
Merge pull request #6172 from menloresearch/fix/model-id-special-char
fix: handle modelId special char
2025-08-14 12:33:58 +07:00
Faisal Amir
6acdf22e41 chore: reorder error 2025-08-14 12:02:47 +07:00
Faisal Amir
10f3f7cea5 chore: handle copy error object message 2025-08-14 11:57:28 +07:00
Louis
16bfd6eafb
fix: full url search 2025-08-14 11:33:03 +07:00
Louis
83bb765bcc
Apply suggestion from @ellipsis-dev[bot]
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-14 10:55:49 +07:00
Louis
8c28f9b6a6
fix: should normalize model ID from source instead of frontend 2025-08-14 10:54:40 +07:00
Louis
526e532e2d
fix: normalize model id from source preparation 2025-08-14 10:50:50 +07:00
Faisal Amir
5657b6d917 chore: fix sanitaize 2025-08-14 10:28:11 +07:00
Faisal Amir
dd5b9e23f5 chore: update progress bar variant model 2025-08-14 10:22:57 +07:00
Louis
da08becd93
fix: duplicate HF search results 2025-08-14 10:15:33 +07:00
Louis
4350d4c9a0
fix: feature toggle for auto updater 2025-08-14 09:58:46 +07:00
Faisal Amir
ace8214d4d chore: make utils sanitize modelId 2025-08-14 09:42:47 +07:00
Faisal Amir
1f0e79e934 chore: update handle download variant 2025-08-14 09:26:54 +07:00
Faisal Amir
b338849952 fix: handle modelId special char 2025-08-14 09:18:03 +07:00
Akarshan Biswas
f4661912b0
feat: Add GGUF metadata reading functionality (#6120)
* feat: Add GGUF metadata reading functionality

This commit introduces a new Tauri command and a corresponding function to read metadata from GGUF model files.

The new read_gguf_metadata command in the Rust backend uses the byteorder crate to parse the GGUF file format and extract key metadata. This information, including the file's version, tensor count, and a key-value map of other metadata, is then made available to the TypeScript frontend.

This functionality is a foundational step toward providing users with more detailed information about their loaded models directly within the application.

This will be refactored later.

fixes: #6001

* loadMetadata() should return

* Properly throw eror to FE

* Use BufReader to improve performance
2025-08-13 22:54:20 +05:30
Faisal Amir
985a8f31ae
fix: migrations model setting (#6165) 2025-08-13 18:21:48 +07:00
Nguyen Ngoc Minh
da31675f64
Merge pull request #6161 from menloresearch/ci/fix-tauri-linux-build
ci: fix tauri build nightly for linux
2025-08-13 10:35:54 +07:00
Minh141120
156bf8230a ci: fix tauri build nightly for linux 2025-08-13 10:26:29 +07:00
Faisal Amir
5266583e5b
enhancement: Add support for mmproj models (#6150) 2025-08-13 10:05:25 +07:00
Nguyen Ngoc Minh
186e6c5bc9
Merge pull request #6159 from menloresearch/ci/add-disable-updater-input
add disable auto updater input for nightly build
2025-08-13 10:04:57 +07:00
Minh141120
c708dce033 add disable auto updater input for nightly build 2025-08-13 09:33:05 +07:00
Akarshan Biswas
02ded9b545
fix: Improve error message for invalid version/backend format (#6149)
* fix: Improve error message for invalid version/backend format

This commit changes the error message displayed when the `version_backend` configuration is invalid. The new message is more user-friendly and suggests a simple solution, such as restarting the application, which is more helpful to the user than the previous technical error message.

* fix typo
2025-08-12 21:38:22 +05:30
Nguyen Ngoc Minh
87e542af65
Merge pull request #6143 from menloresearch/ci/add-flag-disable-auto-updater
ci: add disable auto update flag
2025-08-12 15:39:19 +07:00
Louis
55d998ea99
Merge branch 'dev' into release/v0.6.8 2025-08-12 14:52:21 +07:00
Minh141120
d2389badef Merge branch 'ci/add-flag-disable-auto-updater' of https://github.com/menloresearch/jan into ci/add-flag-disable-auto-updater 2025-08-12 14:50:16 +07:00
Minh141120
6bec267ef5 ci: add disable auto update flag 2025-08-12 14:50:05 +07:00
Louis
8e22b8959a
Merge pull request #6141 from menloresearch/fix/detail-HF-and-readme-visualization-private-repo
fix: visualize readme content for private repo with HF token
2025-08-12 14:08:59 +07:00
Minh141120
2e6d1f6f8d ci: add disable auto update flag 2025-08-12 13:05:13 +07:00
Louis
34b97e41d9
Merge pull request #6140 from menloresearch/fix/factory-reset-got-blocked
fix: factory reset process got blocked
2025-08-12 12:57:17 +07:00
Louis
7b2d0432e6
fix: weird HF readme accessibility 2025-08-12 12:46:57 +07:00
Louis
1a72a592b9
fix: visualize readme content for private repo with HF token 2025-08-12 12:07:25 +07:00
Louis
7c25d1dbfd
fix: HF token is not used while searching repositories (#6137)
* fix: HF token is not used while searching repositories

* chore: whitelist jan model with tool use support by default

* fix: tests

* fix: duplicate model while searching

* fix: deprecate addSource tests since the function was removed
2025-08-12 11:48:06 +07:00
Louis
8e5fac83fd
fix: deprecate addSource tests since the function was removed 2025-08-12 11:25:47 +07:00
Louis
736790473e
fix: duplicate model while searching 2025-08-12 11:17:00 +07:00
Louis
276a286853
fix: tests 2025-08-12 10:37:00 +07:00
Louis
25a0c14be8
chore: whitelist jan model with tool use support by default 2025-08-12 10:33:41 +07:00
Nguyen Ngoc Minh
a75b9c5027
Merge pull request #6130 from menloresearch/ci/add-path-tauri-nightly-build
ci: add path for tauri nightly build
2025-08-11 07:01:16 -07:00
Louis
9ed98614fe fix: factory reset process got blocked 2025-08-11 19:42:59 +07:00
Minh141120
d5ca195059 ci: add path for tauri nightly build 2025-08-11 17:10:51 +07:00
Bui Quang Huy
f26b7ada50
Merge pull request #6125 from menloresearch/freelerobot-patch-1-1
docs: Update 4-goal.md
2025-08-11 17:56:33 +08:00
Nicole Zhu
503c3011e1
Merge pull request #6124 from menloresearch/freelerobot-patch-1
docs: Update 3-epic.md
2025-08-11 17:53:31 +08:00
Nicole Zhu
376873b5ee
docs: Update 4-goal.md 2025-08-11 17:40:35 +08:00
Nicole Zhu
15ba8d217f
docs: Update 3-epic.md 2025-08-11 17:39:37 +08:00
Louis
c355649759
fix: HF token is not used while searching repositories 2025-08-11 15:29:50 +07:00
Nguyen Ngoc Minh
4afabd4c55
Merge pull request #6121 from menloresearch/ci/update-generate-release-note
ci: update generate release note and jan docs release
2025-08-11 01:13:59 -07:00
Louis
0bc1bf9f3d
Merge pull request #6119 from menloresearch/fix/bring-back-gpu-detection
fix: bring back gpu detection - app data relocate issue
2025-08-11 15:04:41 +07:00
Minh141120
1563a41864 ci: update jan docs publish pages condition 2025-08-11 14:48:53 +07:00
Minh141120
963d0a6c9d ci: update generate release note 2025-08-11 14:44:02 +07:00
Louis
f3dd26e499
fix: uvx and npx dirs should be not be relocated 2025-08-11 14:33:58 +07:00
Louis
b924156a15
fix: bring back GPU detection 2025-08-11 13:52:20 +07:00
Ramon Perez
4d3c84f1c6
Merge pull request #6118 from menloresearch/rp/jan-docs-v2-blog
adding handbook, blog, and changelog to jan docs v2
2025-08-11 15:49:01 +10:00
Ramon Perez
7e3db2f1ff
Update website/src/content/changelog/2023-12-21-faster-inference-across-platform.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:47:07 +10:00
Ramon Perez
4135d8b1e6
Update website/src/content/changelog/2024-11-22-jan-bugs.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:45:43 +10:00
Ramon Perez
dc730412de
Update website/src/content/blog/rag-is-not-enough.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:45:19 +10:00
Ramon Perez
882996a875
Update website/src/content/blog/rag-is-not-enough.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:45:01 +10:00
Ramon Perez
fc56c418d6
Update website/src/content/blog/data-is-moat.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:44:43 +10:00
Ramon Perez
654920b3b4
Update website/src/pages/blog.astro
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:44:22 +10:00
Ramon Perez
c3d4d957cd
Update website/src/content/blog/data-is-moat.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:43:44 +10:00
Ramon Perez
2eeb0b15e8 removed duplicate handbook 2025-08-11 15:40:32 +10:00
Ramon Perez
f97d4d9355 fixed blog 2025-08-11 15:19:54 +10:00
Ramon Perez
f3d0cbb03d
Update website/src/content/changelog/2024-11.14-jan-supports-qwen-coder.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:18:51 +10:00
Ramon Perez
6905eab2b1
Update handbook/why/icp.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:18:03 +10:00
Ramon Perez
c91ddae6ed
Update website/src/pages/changelog/[slug].astro
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:17:03 +10:00
Ramon Perez
a7ab08fa4c
Update website/src/content/changelog/2025-02-18-advanced-llama.cpp-settings.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:16:34 +10:00
Ramon Perez
516c2e5e1d
Update website/src/content/changelog/2024-12-30-jan-new-privacy.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:16:24 +10:00
Ramon Perez
269918c09c
Update website/src/content/docs/handbook/hr/travel.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:16:10 +10:00
Ramon Perez
46c285aa41
Update handbook/team/index.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:16:01 +10:00
Ramon Perez
a93a13b172
Update handbook/sell/marketing.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:15:43 +10:00
Ramon Perez
ba58b8c8d9
Update handbook/index.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:11:27 +10:00
Ramon Perez
3473924a29
Update website/src/content/docs/handbook/comp/index.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 15:09:50 +10:00
Ramon Perez
6e39ed7404 route old website to correct docs 2025-08-11 15:07:16 +10:00
Ramon Perez
e3bc6c0818 Merge branch 'dev' into rp/jan-docs-v2-blog 2025-08-11 14:57:21 +10:00
Ramon Perez
be659111a9 polished handbook 2025-08-11 14:50:04 +10:00
Louis
3fc85c59e0
Merge pull request #6109 from B0sh/fix/ime-fix
fix: Prevent accidental message submitting on ChatInput for IME users
2025-08-11 11:40:41 +07:00
Ramon Perez
72588db776 Merge dev branch while preserving website directory
🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-08-11 13:19:17 +10:00
Ramon Perez
c0de25a817
Merge pull request #6116 from menloresearch/rp/docs-v0.6.7
added v0.6.7 changelog and jupyter mcp tutorial
2025-08-11 11:58:11 +10:00
Ramon Perez
ddd417598e
Update docs/src/pages/docs/mcp-examples/data-analysis/jupyter.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 11:53:00 +10:00
Ramon Perez
7d1541c9ad
Update docs/src/pages/changelog/2025-08-07-gpt-oss.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-11 11:52:54 +10:00
Ramon Perez
0b2d2439c1 added v0.6.7 changelog and jupyter mcp tutorial 2025-08-11 11:41:24 +10:00
Louis
4f5d9b8222
Merge pull request #6089 from menloresearch/fix/clean-up-unused-apis
refactor: clean up unused hardware apis
2025-08-11 00:02:31 +07:00
Louis
59afafba0e fix: test command 2025-08-10 23:36:14 +07:00
Louis
f0a9080ef7 fix: cargo test on windows 2025-08-10 22:46:44 +07:00
Ramon Perez
86c5204772 added handbook, and updated the changelog and blog to astro site 2025-08-10 23:18:06 +10:00
B0sh
9b8fb62790 fix: Prevent accidental message submitting on ChatInput for users with IME input languages 2025-08-09 11:28:58 -05:00
Daniel Ching
700af88bf7 Added links for individual deep research pieces 2025-08-08 20:57:24 +08:00
Daniel Ching
b423d7291e changed url 2025-08-08 19:30:28 +08:00
Daniel Ching
ae97668280
Update docs/src/pages/post/deepresearch.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-08 16:55:06 +08:00
Daniel Ching
9f74194f73
Update docs/src/pages/post/deepresearch.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-08 16:54:58 +08:00
Daniel Ching
7154d1081f Added edits to deepresearch place 2025-08-08 16:51:14 +08:00
Daniel Ching
b29ad205df
Merge branch 'dev' into blog/add-deepresearch-piece 2025-08-08 09:16:20 +08:00
Chaiyapruek Muangsiri
b2b0c64c48 fix: default color not selected in appearance color palette 2025-08-08 09:03:46 +08:00
Akarshan Biswas
0cfc745954
feat: Introduce structured error handling for llamacpp extension (#6087)
* feat: Introduce structured error handling for llamacpp extension

This commit introduces a structured error handling system for the `llamacpp` extension. Instead of returning simple string errors, we now use a custom `LlamacppError` struct with a specific `ErrorCode` enum. This allows the frontend to display more user-friendly and actionable error messages based on the code, rather than raw debug logs.

The changes include:
- A new `ErrorCode` enum to categorize errors (e.g., `OutOfMemory`, `ModelArchNotSupported`, `BinaryNotFound`).
- A `LlamacppError` struct to encapsulate the code, a user-facing message, and optional detailed logs.
- A static method `from_stderr` that intelligently parses llama.cpp's standard error output to identify and map common issues like Out of Memory errors to a specific error code.
- Refactored `ServerError` enum to wrap the new `LlamacppError` and provide a consistent serialization format for the Tauri frontend.
- Updated all relevant functions (`load_llama_model`, `get_devices`) to return the new structured error type, ensuring a more robust and predictable error flow.
- A reduced timeout for model loading from 300 to 180 seconds.

This work lays the groundwork for a more intuitive and helpful user experience, as the application can now provide clear guidance to users when a model fails to load.

* Update src-tauri/src/core/utils/extensions/inference_llamacpp_extension/server.rs

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Update src-tauri/src/core/utils/extensions/inference_llamacpp_extension/server.rs

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* chore: update FE handle error object from extension

* chore: fix property type

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-08-07 23:28:25 +05:30
Louis
fc7d8a7a9c
fix: test 2025-08-07 23:47:51 +07:00
Akarshan
0b7477ea56
move nix to non windows 2025-08-07 21:21:47 +05:30
Louis
9285714345
fix: tests 2025-08-07 22:38:28 +07:00
Faisal Amir
4d67418b0d
fix: update ux recemmend backend label into desc setting (#6088) 2025-08-07 22:14:23 +07:00
Akarshan
bdec0af791
fix windows test 2025-08-07 20:37:33 +05:30
Akarshan
9482c0a6b9
Revert "fix import on Windows"
This reverts commit b0e7030939a82baec5f12c44639d0eb6c3c1cf43.
2025-08-07 20:35:13 +05:30
Akarshan
b0e7030939
fix import on Windows 2025-08-07 20:29:05 +05:30
Akarshan
dc82fd6051
fix windows test for short path 2025-08-07 20:16:43 +05:30
Daniel Ching
6507159e34
Merge branch 'dev' into blog/add-deepresearch-piece 2025-08-07 22:41:36 +08:00
Louis
3366d26d65
fix: test should run with windows-latest 2025-08-07 21:25:09 +07:00
Louis
010f0091b9
refactor: remove Cargo workspace 2025-08-07 21:22:35 +07:00
Louis
cafd8741ca
fix: test step 2025-08-07 21:01:40 +07:00
Louis
b8f5fd510a
test: fix failed tests 2025-08-07 20:54:00 +07:00
Louis
25699995fc
refactor: add cargo test 2025-08-07 20:32:55 +07:00
Louis
ab44faeda3
test: fix test 2025-08-07 20:09:07 +07:00
Louis
c1668a4e4a
refactor: clean up unused hardware apis 2025-08-07 20:04:23 +07:00
Akarshan Biswas
469d787888
refactor: Use more precise terminology in API server logs (#6085)
* refactor: Use more precise terminology in API server logs and error messages

This commit refactors several log and error messages to use more accurate and consistent terminology.

-   Replaced "backend servers" and "backend model servers" with "models" or "sessions" to better reflect the service's internal structure.
-   Changed "Proxy server" to "Jan API server" to more accurately describe the server's function.
-   Removed a redundant debug log message.

These changes are cosmetic and improve the readability and consistency of the logging output.

* Update src-tauri/src/core/server.rs

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-07 17:48:33 +05:30
Faisal Amir
f58332e9b5
Merge branch 'dev' into feat/fav-model 2025-08-07 18:11:44 +07:00
Faisal Amir
d8e1fef3f0
🐛fix/onboarding-loop (#6054) 2025-08-07 18:11:22 +07:00
Daniel Ching
d646856b7c
Merge branch 'dev' into blog/add-deepresearch-piece 2025-08-07 16:34:22 +08:00
Daniel Ching
e38d653f4d Addressing comments and tidied up blog post 2025-08-07 16:25:24 +08:00
Ramon Perez
179c1f66b7 added changelog and blog to astro site 2025-08-07 18:09:51 +10:00
Akarshan Biswas
6a699d8004
refactor: move session management & port allocation to backend (#6083)
* refactor: move session management & port allocation to backend

- Remove the in‑process `activeSessions` map and its cleanup logic from the TypeScript side.
- Introduce new Tauri commands in Rust:
  - `get_random_port` – picks an unused port using a seeded RNG and checks availability.
  - `find_session_by_model` – returns the `SessionInfo` for a given model ID.
  - `get_loaded_models` – returns a list of currently loaded model IDs.
- Update the extension’s TypeScript code to use these commands via `invoke`:
  - `findSessionByModel`, `load`, `unload`, `chat`, `getLoadedModels`, and `embed` now operate asynchronously and query the backend.
  - Remove the old `is_port_available` command and the custom port‑checking loop.
  - Simplify `onUnload` – session termination is now handled by the backend.
- Drop unused helpers (`sleep`, `waitForModelLoad`) and related port‑availability code.
- Add missing Rust imports (`rand::{StdRng,Rng,SeedableRng}`, `HashSet`) and improve error handling.
- Register the new commands in `src-tauri/src/lib.rs` (replace `is_port_available` with the three new commands).

This refactor centralises session state and port allocation in the Rust backend, eliminates duplicated logic, and resolves race conditions around model loading and session cleanup.

* Use String(e) for error

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-07 13:06:21 +05:30
Akarshan Biswas
1f1605bdf9
feat: Add support for overriding tensor buffer type (#6062)
* feat: Add support for overriding tensor buffer type

This commit introduces a new configuration option, `override_tensor_buffer_t`, which allows users to specify a regex for matching tensor names to override their buffer type. This is an advanced setting primarily useful for optimizing the performance of large models, particularly Mixture of Experts (MoE) models.

By overriding the tensor buffer type, users can keep critical parts of the model, like the attention layers, on the GPU while offloading other parts, such as the expert feed-forward networks, to the CPU. This can lead to significant speed improvements for massive models.

Additionally, this change refines the error message to be more specific when a model fails to load. The previous message "Failed to load llama-server" has been updated to "Failed to load model" to be more accurate.

* chore: update FE to suppoer override-tensor

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-08-07 10:31:34 +05:30
Emre Can Kartal
c1cdc434a8
Add gpt-oss local installation blog post (#6075)
- Complete beginner guide for running OpenAI's gpt-oss locally
- Step-by-step instructions using Jan AI
- Alternative installation methods (llama.cpp, Ollama, LM Studio)
- Performance benchmarks and troubleshooting guide
- SEO-optimized with FAQ section and comparison tables
- 4 supporting screenshots showing the installation process
2025-08-07 09:48:05 +07:00
Nguyen Ngoc Minh
06941b932d
Merge pull request #6078 from menloresearch/ci/deprecate-jan-docs-new-release
ci: deprecate jan docs new release workflow in favor of jan-docs
2025-08-07 00:22:22 +07:00
Minh141120
c3cca93850 ci: deprecate jan docs new release workflow in favor of jan-docs 2025-08-07 00:04:21 +07:00
Nguyen Ngoc Minh
d55a5e695f
Merge pull request #6073 from menloresearch/chore/update-workflow-name
chore: update workflow name
2025-08-06 23:46:25 +07:00
Nguyen Ngoc Minh
397f71db6e
chore: update workflow name 2025-08-06 17:36:03 +07:00
Louis
b0785e9db0
Merge pull request #6072 from menloresearch/fix/should-not-include-reasoning-content-in-completion-request
fix: should not include reasoning text in the chat completion request
2025-08-06 17:34:16 +07:00
Louis
0b1b84dbf4
test: add tests for new change 2025-08-06 17:13:22 +07:00
Louis
fc815dc98e
fix: should not include reasoning text in the chat completion request 2025-08-06 17:07:32 +07:00
Faisal Amir
ffdb6829e1
fix: gpt-oss thinking block (#6071) 2025-08-06 16:10:24 +07:00
Ramon Perez
1739958664
Added new model provider and updated main repo readme 2025-08-06 13:14:28 +10:00
Ramon Perez
683fb34709 fixed components in troubleshooting tab 2025-08-06 12:49:01 +10:00
Ramon Perez
2306da0e84 added troubleshooting server instructions to config 2025-08-06 12:38:55 +10:00
Akarshan Biswas
fec4cce560 fix: Add conditional Vulkan support check for better GPU compatibility (#6066)
Changes:
- Introduce conditional Vulkan support check for discrete GPUs with 6GB+ VRAM

fixes: #6009
2025-08-06 12:24:21 +10:00
Louis
e74601443f chore: add deep_link register_all 2025-08-06 12:24:21 +10:00
Louis
f41a04b1a2 fix: test env 2025-08-06 12:24:21 +10:00
Louis
3bdd5f00b6 chore: able to disable updater via env flag 2025-08-06 12:24:21 +10:00
Louis
de146f363a test: add tests 2025-08-06 12:24:21 +10:00
Louis
83527a7533 fix: Jan hub repo detail and deep link 2025-08-06 12:24:21 +10:00
Faisal Amir
026b21f779 feat: jinja template customize per model instead provider level (#6053) 2025-08-06 12:24:21 +10:00
Akarshan Biswas
dcffa4fa0a Fix: Improve Llama.cpp model path handling and error handling (#6045)
* Improve Llama.cpp model path handling and validation

This commit refactors the load_llama_model function to improve how it handles and validates the model path.

Previously, the function extracted the model path but did not perform any validation. This change adds the following improvements:

It now checks for the presence of the -m flag.

It verifies that a path is provided after the -m flag.

It validates that the specified model path actually exists on the filesystem.

It ensures that the SessionInfo struct stores the canonical display path of the model, which is a more robust approach.

These changes make the model loading process more reliable and provide better error handling for invalid or missing model paths.

* Exp: Use short path on Windows

* Fix: Remove error channel and handling in llama.cpp server loading

The previous implementation used a channel to receive error messages from the llama.cpp server's stdout. However, this proved unreliable as the path names can contain 'errors strings' that we use to check even during normal operation. This commit removes the error channel and associated error handling logic.
The server readiness is still determined by checking for the "server is listening" message in stdout. Errors are now handled by relying on the process exit code and capturing the full stderr output if the process fails to start or exits unexpectedly. This approach provides a more robust and accurate error detection mechanism.

* Add else block in Windows path handling

* Add some path related tests

* Fix windows tests
2025-08-06 12:24:21 +10:00
Faisal Amir
318f6f504f feat: recommended label llamacpp setting (#6052)
* feat: recommended label llamacpp

* chore: remove log
2025-08-06 12:24:21 +10:00
Minh141120
8e4c696583 ci: disable autoqa on nightly build 2025-08-06 12:24:21 +10:00
Louis
7e52512d0e fix: should check for invalid backend to cover previous missing backend case 2025-08-06 12:24:21 +10:00
Louis
eb13189d07 fix: run dev should reinstall extensions 2025-08-06 12:24:21 +10:00
Louis
026383e92d test: add tests for new changes 2025-08-06 12:24:21 +10:00
Louis
4b6269a4f0 fix: add missing cuda backend support 2025-08-06 12:24:21 +10:00
Minh141120
3ffb30b544 chore: skip nightly build workflow for external contributor 2025-08-06 12:24:21 +10:00
Sherzod Mutalov
5f06a35f4e fix: use attributes to check the feature existence 2025-08-06 12:24:21 +10:00
Sherzod Mutalov
280ea1aa9f chore: extracted macos avx2 check code to the utility function 2025-08-06 12:23:18 +10:00
Sherzod Mutalov
ad9c4854a9 chore: added comments 2025-08-06 12:20:30 +10:00
Sherzod Mutalov
49c8334e40 chore: replaced with macros call to remove warning 2025-08-06 12:20:30 +10:00
Sherzod Mutalov
f1dd42de9e fix: use system npx on old mac's 2025-08-06 12:20:30 +10:00
Chaiyapruek Muangsiri
4e31e1d3a8 remove unnecessary try catch block 2025-08-06 12:20:30 +10:00
Chaiyapruek Muangsiri
00f686a733 fix connected servers status not in sync when edit mcp json 2025-08-06 12:20:30 +10:00
Ramon Perez
890a917dec removed nextra component in astro site 2025-08-06 12:20:30 +10:00
Akarshan Biswas
8d147c1774
fix: Add conditional Vulkan support check for better GPU compatibility (#6066)
Changes:
- Introduce conditional Vulkan support check for discrete GPUs with 6GB+ VRAM

fixes: #6009
2025-08-06 07:20:44 +05:30
Louis
c642076ec3
Merge pull request #6024 from menloresearch/fix/jan-hub-repo-data-and-deeplink
fix: Jan hub model detail and deep link
2025-08-06 08:46:07 +07:00
Louis
3b349a60f1 chore: add deep_link register_all 2025-08-05 22:32:27 +07:00
Ramon Perez
4ee6873ca5
Update docs/src/pages/docs/remote-models/huggingface.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-06 00:24:18 +10:00
Ramon Perez
fc4ecd3412
Update README.md
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-06 00:24:10 +10:00
Faisal Amir
5d001dfd5a
feat: jinja template customize per model instead provider level (#6053) 2025-08-05 21:21:41 +07:00
Ramon Perez
f95c6c4d3d updated readme 2025-08-05 23:11:05 +10:00
Ramon Perez
4c66b1f65b added huggingface page and updated readme 2025-08-05 22:57:49 +10:00
Akarshan Biswas
088b9d7f25
Fix: Improve Llama.cpp model path handling and error handling (#6045)
* Improve Llama.cpp model path handling and validation

This commit refactors the load_llama_model function to improve how it handles and validates the model path.

Previously, the function extracted the model path but did not perform any validation. This change adds the following improvements:

It now checks for the presence of the -m flag.

It verifies that a path is provided after the -m flag.

It validates that the specified model path actually exists on the filesystem.

It ensures that the SessionInfo struct stores the canonical display path of the model, which is a more robust approach.

These changes make the model loading process more reliable and provide better error handling for invalid or missing model paths.

* Exp: Use short path on Windows

* Fix: Remove error channel and handling in llama.cpp server loading

The previous implementation used a channel to receive error messages from the llama.cpp server's stdout. However, this proved unreliable as the path names can contain 'errors strings' that we use to check even during normal operation. This commit removes the error channel and associated error handling logic.
The server readiness is still determined by checking for the "server is listening" message in stdout. Errors are now handled by relying on the process exit code and capturing the full stderr output if the process fails to start or exits unexpectedly. This approach provides a more robust and accurate error detection mechanism.

* Add else block in Windows path handling

* Add some path related tests

* Fix windows tests
2025-08-05 14:17:19 +05:30
Faisal Amir
dbdea2db10 chore: fix linter 2025-08-05 14:26:12 +07:00
Faisal Amir
2a2798fa84 Update web-app/src/containers/DropdownModelProvider.tsx
Co-authored-by: Louis <louis@jan.ai>
2025-08-05 14:26:12 +07:00
Faisal Amir
fea516f98f Update web-app/src/containers/DropdownModelProvider.tsx
Co-authored-by: Louis <louis@jan.ai>
2025-08-05 14:26:12 +07:00
Faisal Amir
fb15687388 chore: update icon heart to stars 2025-08-05 14:26:12 +07:00
Faisal Amir
fcfae4127e Update web-app/src/containers/FavoriteModelAction.tsx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-05 14:26:12 +07:00
Faisal Amir
e3ba37ba15 🚀feat: allow user mark model as favorite 2025-08-05 14:26:12 +07:00
Faisal Amir
99567a1102
feat: recommended label llamacpp setting (#6052)
* feat: recommended label llamacpp

* chore: remove log
2025-08-05 13:55:33 +07:00
Louis
065a850a94 fix: test env 2025-08-05 13:44:40 +07:00
Louis
b8070f1871 chore: able to disable updater via env flag 2025-08-05 13:44:40 +07:00
Louis
90e46a2696 test: add tests 2025-08-05 13:44:40 +07:00
Louis
7f0c605651 fix: Jan hub repo detail and deep link 2025-08-05 13:44:40 +07:00
Nguyen Ngoc Minh
339a1957c8
Merge pull request #6051 from menloresearch/ci/disable-autoqa-on-nightly-build
ci: disable autoqa on nightly build
2025-08-05 12:47:31 +07:00
Louis
813c911487
Merge pull request #6046 from menloresearch/fix/support-missing-llamacpp-cuda-backends
fix: support missing llamacpp cuda backends
2025-08-05 12:37:31 +07:00
Minh141120
517e556552 ci: disable autoqa on nightly build 2025-08-05 12:14:16 +07:00
Louis
4a4bc35cce fix: should check for invalid backend to cover previous missing backend case 2025-08-05 11:41:02 +07:00
Nguyen Ngoc Minh
ac66b49eca
Merge pull request #6050 from menloresearch/chore/skip-nightly-build-for-external-contrib
chore: skip nightly build workflow for external contributor
2025-08-05 11:09:17 +07:00
Louis
80707c42e8
Merge pull request #5530 from shmutalov/feat/old-mac-support
feat: old mac support
2025-08-05 11:08:14 +07:00
Louis
48004024ee
Merge pull request #6020 from cmppoon/fix-mcp-servers-edit-json
fix connected servers status not in sync when edit mcp json
2025-08-05 11:06:05 +07:00
Minh141120
e3331dd508 chore: skip nightly build workflow for external contributor 2025-08-05 10:29:33 +07:00
Sherzod Mutalov
0a79cf79a6
Merge branch 'dev' into feat/old-mac-support 2025-08-05 08:17:55 +05:00
Ramon Perez
4c40236441 Merge branch 'rp/jan-docs-v2' into rp/docs-model-providers 2025-08-05 12:19:30 +10:00
Ramon Perez
71987a383a feat: add updated server documentation and MCP examples
- Update local-server docs with comprehensive configuration details
- Add new MCP examples: browserbase, canva, octagon
- Convert Nextra components to Starlight components
- Fix image paths to use correct relative paths
2025-08-05 12:18:42 +10:00
Daniel Ching
ad78a78339
Update docs/src/pages/post/deepresearch.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-05 09:37:54 +08:00
Daniel Ching
56a4a19163
Update docs/src/pages/post/deepresearch.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-05 09:37:45 +08:00
Daniel Ching
324ec77d98
Update docs/src/pages/post/deepresearch.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-05 09:37:31 +08:00
Faisal Amir
641df474fd
fix: Generate A Response button does not show context size error dialog (#6029)
* fix: Generate A Response button does not show context size error dialog

* chore: remove as a child button params
2025-08-05 08:34:06 +07:00
Chaiyapruek Muangsiri
da0cf10f91 remove unnecessary try catch block 2025-08-05 08:08:59 +07:00
Chaiyapruek Muangsiri
477651e5d5 fix connected servers status not in sync when edit mcp json 2025-08-05 08:08:59 +07:00
Louis
72de519430 fix: run dev should reinstall extensions 2025-08-05 00:09:12 +07:00
Louis
29ad6691d8
Merge pull request #6044 from cmppoon/error-toast-on-download-failed
fix: show error toast message on download error
2025-08-04 22:45:17 +07:00
Akarshan Biswas
5e533bdedc
feat: Improve llama.cpp argument handling and add device parsing tests (#6041)
* feat: Improve llama.cpp argument handling and add device parsing tests

This commit refactors how arguments are passed to llama.cpp,
specifically by only adding arguments when their values differ from
their defaults. This reduces the verbosity of the command and prevents
potential conflicts or errors when llama.cpp's default behavior aligns
with the desired setting.

Additionally, new tests have been added for parsing device output from
llama.cpp, ensuring the accurate extraction of GPU information (ID,
name, total memory, and free memory). This improves the robustness of
device detection.

The following changes were made:

* **Remove redundant `--ctx-size` argument:** The `--ctx-size`
    argument is now only explicitly added if `cfg.ctx_size` is greater
    than 0.
* **Conditional argument adding for default values:**
    * `--split-mode` is only added if `cfg.split_mode` is not empty
        and not 'layer'.
    * `--main-gpu` is only added if `cfg.main_gpu` is not undefined
        and not 0.
    * `--cache-type-k` is only added if `cfg.cache_type_k` is not 'f16'.
    * `--cache-type-v` is only added if `cfg.cache_type_v` is not 'f16'
        (when `flash_attn` is enabled) or not 'f32' (otherwise). This
        also corrects the `flash_attn` condition.
    * `--defrag-thold` is only added if `cfg.defrag_thold` is not 0.1.
    * `--rope-scaling` is only added if `cfg.rope_scaling` is not
        'none'.
    * `--rope-scale` is only added if `cfg.rope_scale` is not 1.
    * `--rope-freq-base` is only added if `cfg.rope_freq_base` is not 0.
    * `--rope-freq-scale` is only added if `cfg.rope_freq_scale` is
        not 1.
* **Add `parse_device_output` tests:** Comprehensive unit tests were
    added to `src-tauri/src/core/utils/extensions/inference_llamacpp_extension/server.rs`
    to validate the parsing of llama.cpp device output under various
    scenarios, including multiple devices, single devices, different
    backends (CUDA, Vulkan, SYCL), complex GPU names, and error
    conditions.

* fixup cache_type_v comparision
2025-08-04 19:47:04 +05:30
Chaiyapruek Muangsiri
38c5911460 fix: show error toast on download error 2025-08-04 20:40:17 +08:00
Ramon Perez
a8613e5d15
Merge pull request #5950 from menloresearch/rp/jan-docs-v2 2025-08-04 22:28:55 +10:00
Daniel Ching
714a9ba241 Refactoring title and added proper image 2025-08-04 18:03:16 +08:00
Louis
45c2b02842 test: add tests for new changes 2025-08-04 16:01:04 +07:00
Louis
bf9315dbbe fix: add missing cuda backend support 2025-08-04 15:54:21 +07:00
Daniel Ching
c403029d5d First commit for Deep Research piece 2025-08-04 13:36:08 +08:00
Ramon Perez
3f71428c29 Merge dev branch changes into isolated branch 2025-08-04 10:32:42 +10:00
Sherzod Mutalov
9ce7527d58 fix: use attributes to check the feature existence 2025-08-03 11:12:37 +05:00
Sherzod Mutalov
e51847830a
Merge branch 'dev' into feat/old-mac-support 2025-08-03 10:19:30 +05:00
Akarshan Biswas
b1984a452e
Fix: Llama.cpp server hangs on model load (#6030)
* Fix: Llama.cpp server hangs on model load

Resolves an issue where the llama.cpp server would hang indefinitely when loading certain models, as described in the attached ticket. The server's readiness message was not being correctly detected, causing the application to stall.

The previous implementation used a line-buffered reader (BufReader::lines()) to process the stderr stream. This method proved to be unreliable for the specific output of the llama.cpp server.

This commit refactors the stderr handling logic to use a more robust, chunk-based approach (read_until(b'\n', ...)). This ensures that the output is processed as it arrives, reliably capturing critical status messages and preventing the application from hanging during model initialization.

Fixes: #6021

* Handle error gracefully with ServerError

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Revert "Handle error gracefully with ServerError"

This reverts commit 267a8a8a3262fbe36a445a30b8b3ba9a39697643.

* Revert "Fix: Llama.cpp server hangs on model load"

This reverts commit 44e5447f82f0ae32b6db7ffb213025f130d655c4.

* Add more guards, refactor and fix error sending to FE

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-08-02 21:50:07 +05:30
Faisal Amir
787c4ee073
fix: wrong desc setting cont_batching (#6034) 2025-08-02 21:48:43 +07:00
Faisal Amir
3acb61b5ed
fix: react state loop from hooks useMediaQuery (#6031)
* fix: react state loop from hooks useMediaQuerry

* chore: update test cases hooks media query
2025-08-02 21:48:40 +07:00
Louis
ea29785a8a
Merge branch 'dev' into feat/old-mac-support 2025-08-01 10:55:55 +07:00
Nguyen Ngoc Minh
6603460c39
Merge pull request #6014 from menloresearch/ci/add-trigger-pr-dev
ci: enable PR trigger for dev branch in tauri nightly workflow
2025-07-31 09:14:23 -07:00
Minh141120
b53d5f3638 ci: enable PR trigger for dev branch in tauri nightly workflow 2025-07-31 22:22:38 +07:00
Louis
9c0d09c487
refactor: clean up cortex (#6003)
* refactor: clean up cortex

* chore: clean up

* refactor: clean up
2025-07-31 21:58:12 +07:00
Louis
9573329d06
Merge pull request #6004 from menloresearch/release/v0.6.6
Sync release/v0.6.6 into dev
2025-07-31 21:34:52 +07:00
Louis
4bcfa84d75
Merge pull request #6008 from menloresearch/hotfix/regression-issue-with-colon-in-model-name
hotfix: regression issue with colon in model name
2025-07-31 17:55:28 +07:00
Ramon Perez
76966135d3
Merge pull request #5958 from menloresearch/rp/nextra-product-section 2025-07-31 20:06:53 +10:00
Louis
8a7edbf3a7
Merge pull request #6005 from menloresearch/fix/save_my_life
Add RunEvent::Exit event to tauri to handle macos context menu exit
2025-07-31 16:05:22 +07:00
Ramon Perez
a93d4f380b updated changelog 2025-07-31 18:52:01 +10:00
Ramon Perez
23ba41fa9d docs: add MCP integration tutorials and update llama.cpp settings for v0.6.6 2025-07-31 18:52:01 +10:00
Ramon Perez
183c028e46 tutorials started 2025-07-31 18:52:01 +10:00
Ramon Perez
aa117cf917 added products section, and reorganized and improved the docs 2025-07-31 18:52:01 +10:00
Ramon Perez
b5d54e48d1 fixed docs workflow issues 2025-07-31 18:52:01 +10:00
Ramon Perez
8511e35df8 feat(docs): Migrate to dual Nextra/Astro deployment & recreate products section
This commit introduces a significant restructuring of the documentation deployment and content strategy to support a gradual migration from Nextra to Astro.

- **New Astro Workflow (`jan-astro-docs.yml`)**: Implemented a new, separate GitHub Actions workflow to build and deploy the Astro site from the `/website` directory to a new subdomain (`v2.jan.ai`). This isolates the new site from the existing one, allowing for independent development and testing.
- **Removed Combined Workflow**: Deleted the previous, more complex combined workflow (`jan-combined-docs.yml`) and its associated test scripts to simplify the deployment process and eliminate routing conflicts.
- **Astro Config Update**: Simplified the Astro configuration (`astro.config.mjs`) by removing the conditional `base` path. The Astro site is now configured to deploy to the root of its own subdomain.

- **Mirrored Content**: Recreated the entire `/products` section from the Astro site within the Nextra site at `/docs/src/pages/products`. This provides content parity and a consistent user experience on both platforms during the transition period.
- **File Structure**: Established a clear, organized structure for platforms, models, and tools within the Nextra `products` directory.
- **Nextra Sidebar Fix**: Implemented the correct `_meta.json` structure for the new products section. Created nested meta files to build a collapsible sidebar, fixing the UI bug that caused duplicated navigation items.

- **"Coming Soon" Pages**: Added clear, concise "Coming Soon" and "In Development" banners and content for upcoming products like Jan V1, Mobile, Server, and native Tools, ensuring consistent messaging across both sites.
- **.gitignore**: Updated the root `.gitignore` to properly exclude build artifacts, caches, and environment files for both the Nextra (`/docs`) and Astro (`/website`) projects.
- **Repository Cleanup**: Removed temporary and unused files related to the previous combined deployment attempt.

This new architecture provides a stable, predictable, and low-risk path for migrating our documentation to Astro while ensuring the current production site remains unaffected.
2025-07-31 18:52:00 +10:00
Ramon Perez
6c189ea961 website layout complete, next, polish wording 2025-07-31 18:52:00 +10:00
Ramon Perez
df5fac06b4 interim product page layout 2025-07-31 18:52:00 +10:00
Ramon Perez
49de36cac8 a crazy iteration 2025-07-31 18:52:00 +10:00
Ramon Perez
a4d00be62f first stab at a product page 2025-07-31 18:52:00 +10:00
Ramon Perez
48f3b5e54f mobile section updated 2025-07-31 18:52:00 +10:00
Ramon Perez
eaf5b5d59e new website 2025-07-31 18:51:59 +10:00
Akarshan
e11b4c9449
restore extras to its original state 2025-07-31 15:41:44 +07:00
Akarshan
e76d207718
Fixup: tauri::WindowEvent 2025-07-31 15:41:43 +07:00
Akarshan
b3e8201481
Add RunEvent::Exit event to tauri to handle macos context menu exit 2025-07-31 15:41:43 +07:00
Faisal Amir
59a17d4a2a
fix/remove-auto-refresh-model (#6002) 2025-07-31 14:07:31 +07:00
Louis
25fa4901c2
Merge pull request #5997 from menloresearch/release/v0.6.6
Sync Release/v0.6.6 into dev
2025-07-31 10:25:09 +07:00
cmuangs
e48b8c9792
fix assistant dropdown onClick not triggered consistently (#5991) 2025-07-31 09:05:56 +07:00
Faisal Amir
5e72d210d4
fix: missing text color responsive left panel (#5989) 2025-07-30 22:23:57 +07:00
Faisal Amir
99cc2efb90
enhancement: blurry logo model provider (#5986) 2025-07-30 21:11:46 +07:00
Louis
76bcf33f80
fix: generate response button disappear on tool call (#5988)
* fix: generate a response button should appear when an incomplete tool call message is present

* fix: wording

* fix: do not send duplicate messages on regenerating

* fix: tests
2025-07-30 21:04:12 +07:00
Faisal Amir
f58d745585
fix: title tooltip MCP edit json (#5987)
* fix/title-tooltip-mcp-json

* fix: title tooltip delete mcp
2025-07-30 21:00:55 +07:00
Faisal Amir
1e7e572d4a
fix: download progress missing when left panel scrollable (#5984) 2025-07-30 18:36:42 +07:00
cmuangs
d2f99c36f5
fix thread sorting issue (#5976) 2025-07-30 18:15:29 +07:00
Louis
7a3d9d765c
fix: failed provider models list due to broken cortex import (#5983) 2025-07-30 17:37:44 +07:00
Louis
12c552c987
Merge pull request #5973 from menloresearch/release/v0.6.6
Sync Release/v0.6.6 into dev
2025-07-30 12:49:13 +07:00
Akarshan Biswas
0aaaca05a4
fix: use direct process termination instead of console events on Windows (#5972)
* fix: remove CREATE_NEW_PROCESS_GROUP flag for proper Ctrl-C handling

CREATE_NEW_PROCESS_GROUP prevented GenerateConsoleCtrlEvent from working,
causing graceful shutdown failures. Removed to enable proper signal handling.

* Revert "fix: remove CREATE_NEW_PROCESS_GROUP flag for proper Ctrl-C handling"

This reverts commit 82ace3e72e4bf7338f422d5c79bdd6a0f8a2440e.

* fix: use direct process termination instead of console events

Simplified Windows process cleanup by removing console attachment logic
and using direct child.kill() method. More reliable for headless processes.

* Fix missing imports

* switch to tokio::time

* Don't wait while forcefully terminate process using kill API on Windows

Disabled use of windows-sys crate as graceful shutdown on Windows is unreliable in this context.

Updated cleanup.rs and server.rs to directly call child.kill().await for terminating processes on Windows.

Improved logging for process termination and error handling during kill and wait.

Removed timeout-based graceful shutdown attempt on Windows since TerminateProcess is inherently forceful and immediate.

This ensures more predictable process cleanup behavior on Windows platforms.

* final cleanups
2025-07-30 10:09:20 +05:30
Ramon Perez
fd2fc35b48 chore: remove .vscode files from git tracking
.vscode files should not be committed as they contain personal IDE settings.
These are already properly ignored in .gitignore.
2025-07-30 13:20:13 +10:00
Ramon Perez
469a0814f3 feat: sync project configuration from remote
- Updated .gitignore to remove yarn exclusion
- Added .vscode settings for Prettier formatting and Rust support
- Added .yarnrc.yml for workspace hoisting configuration
- Preserved all website directory work while syncing project improvements
2025-07-30 12:24:05 +10:00
Faisal Amir
079759939a
fix: rename thread dialog shows previous thread (#5963) 2025-07-30 09:18:43 +07:00
Ramon Perez
a2aac5a63a vision update 2025-07-30 12:00:31 +10:00
Ramon Perez
9e43f61366 vision update 2025-07-30 11:18:11 +10:00
Nguyen Ngoc Minh
ee582a8e52
chore: allow all HTTPS image sources in img-src directive (#5970) 2025-07-29 20:04:35 +07:00
Akarshan Biswas
f61ce886a0
feat: Enhance port selection with availability check (#5966)
This change improves the robustness of the llama.cpp extension's server port selection.

Previously, the `getRandomPort()` method only checked for ports already in use by active sessions, which could lead to model load failures if the chosen port was occupied by another external process.

This change introduces a new Tauri command, `is_port_available`, which performs a system-level check to ensure the randomly selected port is truly free before attempting to start the llama-server. It also adds a retry mechanism with a maximum number of attempts (20,000) to find an available port, throwing an error if no suitable port is found within the specified range after all attempts.

This enhancement prevents port conflicts and improves the reliability and user experience of the llama.cpp extension within Jan.

Closes #5965
2025-07-29 18:01:52 +05:30
Ramon Perez
04353a289c resolve: merge conflicts from CI deployment fixes
- Resolved conflict in api-server.mdx keeping enhanced content structure
- Resolved conflict in browseruse.mdx using comprehensive incoming version
- Removed deleted PRODUCTS_PAGE_README.md file
- Successfully integrated team's CI deployment improvements
2025-07-29 21:03:45 +10:00
Ramon Perez
bd7022fb58 feat: enhance docs structure and add comprehensive Products section
- Added rich Products section with detailed platform coverage
- Enhanced all documentation sections with improved formatting
- Added new images and visual content throughout
- Reorganized Local Server docs into main docs flow
- Removed .vscode settings and added api-server-ui.png asset
2025-07-29 21:01:27 +10:00
hiento09
1ff86e237f chore: create astro docs cicd 2025-07-29 17:52:13 +07:00
Nguyen Ngoc Minh
eb714776ba
fix: csp including img.shields.io and cdn-uploads.huggingface.co in img-src directive (#5967)
* fix: csp including img.shields.io in img-src directive

* fix: add huggingface upload cdn to img-src directive
2025-07-29 16:30:00 +07:00
Nguyen Ngoc Minh
210ace79d5
ci: tolerate artifact upload (#5969) 2025-07-29 15:45:32 +07:00
Ramon Perez
1836863066 removed .vscode settings 2025-07-29 15:34:53 +10:00
Ramon Perez
4b24176d2c fixed browseruse page and updated product pages 2025-07-29 15:30:47 +10:00
Faisal Amir
63cb4fbf3b
fix: assistant with last used and fix metadata (#5955)
* fix: assistant with last used and fix metadata

* chore: revert instruction and desc

* chore: fix current assistant state

* chore: updae metadata message assistant

* chore: update test case
2025-07-29 09:50:07 +07:00
Louis
160d158152
fix: search models result in hub should be sorted by weight (#5954) 2025-07-28 23:33:11 +07:00
Louis
812a8082b8
fix: factory reset fail with access denied error (#5952)
* fix: factory reset fail due to access denied error

* fix: unused import

* fix: tests
2025-07-28 23:20:45 +07:00
Akarshan Biswas
07421d7f53
fix: set autoUnload in onLoad() (#5956)
The variable was not initialized resulted in always setting true when
starting.

This change fixes it.
2025-07-28 20:54:21 +05:30
Faisal Amir
1c74bfd5ef
fix: update edge case experimental feature MCP (#5951)
* fix: update edge case experimental feature MCP

* Update web-app/src/routes/settings/mcp-servers.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-07-28 21:31:51 +07:00
Akarshan Biswas
fa896b3bf3
fix: correctly apply auto_unload setting from config (#5953)
Previously, the `autoUnload` flag was not being updated when set via config,
causing models to be auto-unloaded regardless of the intended behavior.
This patch ensures the setting is respected at runtime.
2025-07-28 19:17:29 +05:30
Ramon Perez
a48925f6bc revert: Remove Nextra product section to isolate Astro site changes
- Removed docs/src/pages/products/ directory and all contents
- Removed products entry from docs/src/pages/_meta.json
- Reverted docs/package.json, docs/bun.lock, docs/yarn.lock to dev state

This creates a cleaner separation between:
- Current branch: Astro site changes only
- rp/nextra-product-section branch: Nextra product section changes only
2025-07-28 22:13:55 +10:00
Ramon Perez
4e4c683211 fixed docs workflow issues 2025-07-28 22:03:58 +10:00
Ramon Perez
8ed5bddc02 feat(docs): Migrate to dual Nextra/Astro deployment & recreate products section
This commit introduces a significant restructuring of the documentation deployment and content strategy to support a gradual migration from Nextra to Astro.

- **New Astro Workflow (`jan-astro-docs.yml`)**: Implemented a new, separate GitHub Actions workflow to build and deploy the Astro site from the `/website` directory to a new subdomain (`v2.jan.ai`). This isolates the new site from the existing one, allowing for independent development and testing.
- **Removed Combined Workflow**: Deleted the previous, more complex combined workflow (`jan-combined-docs.yml`) and its associated test scripts to simplify the deployment process and eliminate routing conflicts.
- **Astro Config Update**: Simplified the Astro configuration (`astro.config.mjs`) by removing the conditional `base` path. The Astro site is now configured to deploy to the root of its own subdomain.

- **Mirrored Content**: Recreated the entire `/products` section from the Astro site within the Nextra site at `/docs/src/pages/products`. This provides content parity and a consistent user experience on both platforms during the transition period.
- **File Structure**: Established a clear, organized structure for platforms, models, and tools within the Nextra `products` directory.
- **Nextra Sidebar Fix**: Implemented the correct `_meta.json` structure for the new products section. Created nested meta files to build a collapsible sidebar, fixing the UI bug that caused duplicated navigation items.

- **"Coming Soon" Pages**: Added clear, concise "Coming Soon" and "In Development" banners and content for upcoming products like Jan V1, Mobile, Server, and native Tools, ensuring consistent messaging across both sites.
- **.gitignore**: Updated the root `.gitignore` to properly exclude build artifacts, caches, and environment files for both the Nextra (`/docs`) and Astro (`/website`) projects.
- **Repository Cleanup**: Removed temporary and unused files related to the previous combined deployment attempt.

This new architecture provides a stable, predictable, and low-risk path for migrating our documentation to Astro while ensuring the current production site remains unaffected.
2025-07-28 21:47:18 +10:00
Akarshan Biswas
432c942330
fix: Prevent race condition with auto-unload during rapid model loading (#5947)
This commit addresses a race condition where, with "Auto-Unload Old Models" enabled, rapidly attempting to load multiple models could result in more than one model being loaded simultaneously.

Previously, the unloading logic did not account for models that were still in the process of loading when a new load operation was initiated. This allowed new models to start loading before the previous ones had fully completed their unload cycle.

To resolve this:
- A `loadingModels` map has been introduced to track promises for models currently in the loading state.
- The `load` method now checks if a model is already being loaded and, if so, returns the existing promise, preventing duplicate load operations for the same model.
- The `performLoad` method (which encapsulates the actual loading logic) now ensures that when `autoUnload` is active, it waits for any *other* models that are concurrently loading to finish before proceeding to unload all currently loaded models. This guarantees that the auto-unload mechanism properly unloads all models, including those initiated in quick succession, thereby preventing the race condition.

This fixes the issue where clicking the start button very fast on multiple models would bypass the auto-unload functionality.
2025-07-28 12:59:48 +05:30
Nguyen Ngoc Minh
a4e5973573
chore: uninstall when upgrading windows installer (#5945) 2025-07-28 14:09:13 +07:00
Louis
fdaa3b1992
fix: openrouter unselect itself (#5943)
* fix: selected openrouter model does not work

* test: add tests to cover new change
2025-07-28 10:33:23 +07:00
Faisal Amir
08af8a49aa
fix: tool approval params scrollable (#5941) 2025-07-28 09:39:34 +07:00
Louis
1fc37a9349
fix: migrate app settings to the new version (#5936)
* fix: migrate app settings to the new version

* fix: edge cases

* fix: migrate HF import model on Windows

* fix hardware page broken after downgraded

* test: correct test

* fix: backward compatible hardware info
2025-07-27 21:13:05 +07:00
Akarshan Biswas
c9b44eec52
fix: Remove sInfo from activeSessions before unloading (#5938)
This commit addresses a potential race condition that could lead to "connection errors" when unloading a llamacpp model.

The issue arose because the `activeSessions` map still has the session info of the model during unload. This could lead to "connection errors" when the backend is taking time to unload while there is an ongoing request to the model.

The fix involves:

1. **Deleting the `pid` from `activeSessions` before calling backend's unload:** This ensures that the model is cleared from the map before we start unloading.
2. **Failure handling**: If somehow the backend fails to unload, the session info for that model is added back to prevent any race conditions.

This commit improves the robustness and reliability of the unloading process by preventing potential conflicts.
2025-07-27 14:37:34 +05:30
Faisal Amir
54d44ce741
fix: update default GPU toggle, and simplify state (#5937) 2025-07-27 14:36:08 +07:00
Nguyen Ngoc Minh
c3fa04fdd7
chore: revert back to passive mode on windows installer (#5934) 2025-07-26 22:29:58 +07:00
Faisal Amir
b89d9d090f
fix: update ui version_backend, mem usage hardware (#5932)
* fix: update ui version_backend, mem usage hardware

* chore: hidden gpu from system monitor on mac

* chore: fix gpus vram
2025-07-26 18:36:18 +07:00
Akarshan Biswas
8ec4a36826
fix: Frontend updates when llama.cpp backend auto-downloads (#5926) 2025-07-26 08:48:29 +07:00
Faisal Amir
2e870ad4d0
fix: calculation memory on hardware and system monitor (#5922) 2025-07-26 08:47:59 +07:00
Faisal Amir
7dec980630
fix: persist model capabilities refresh app (#5918) 2025-07-25 20:27:51 +07:00
Faisal Amir
6c15129ce8
fix: validate name assistant and improve area clickable (#5920) 2025-07-25 20:27:38 +07:00
Akarshan Biswas
3982ed4c6f
fix: Allow N-GPU Layers (NGL) to be set to 0 in llama.cpp (#5907)
* fix: Allow N-GPU Layers (NGL) to be set to 0 in llama.cpp

The `n_gpu_layers` (NGL) setting in the llama.cpp extension was incorrectly preventing users from disabling GPU layers by automatically defaulting to 100 when set to 0.

This was caused by a condition that only pushed `cfg.n_gpu_layers` if it was greater than 0 (`cfg.n_gpu_layers > 0`).

This commit updates the condition to `cfg.n_gpu_layers >= 0`, allowing 0 to be a valid and accepted value for NGL. This ensures that users can effectively disable GPU offloading when desired.

* fix: default ngl

---------

Co-authored-by: Louis <louis@jan.ai>
2025-07-25 16:24:53 +05:30
Louis
0c53ad0e16
fix: models hub should show latest data only (#5925)
* fix: models hub should show latest data only

* test: correct expected result
2025-07-25 17:34:14 +07:00
Ramon Perez
ceadff78aa website layout complete, next, polish wording 2025-07-25 15:45:11 +10:00
Akarshan Biswas
4d4cf896af
fix: Persist 'Auto-Unload Old Models' setting in llama.cpp (#5906)
The 'Auto-Unload Old Models' setting in the llama.cpp extension failed to persist due to a typo in its key name within `settings.json`. The key was incorrectly `auto_unload_models` instead of `auto_unload`.

This commit corrects the key name to `auto_unload`, ensuring that user-configured changes to this setting are properly saved, retrieved, and persist across application restarts.

This resolves the issue where the setting would change and remain to its previous value after being changed.
2025-07-25 11:03:15 +05:30
Sherzod Mutalov
0bc07e2de6
Merge branch 'dev' into feat/old-mac-support 2025-07-24 20:27:41 +05:00
Ramon Perez
4d446b14ee interim product page layout 2025-07-24 23:57:14 +10:00
Ramon Perez
78706a40c5 a crazy iteration 2025-07-24 23:12:59 +10:00
Akarshan Biswas
a1af70f7a9
feat: Enhance Llama.cpp backend management with persistence (#5886)
* feat: Enhance Llama.cpp backend management with persistence

This commit introduces significant improvements to how the Llama.cpp extension manages and updates its backend installations, focusing on user preference persistence and smarter auto-updates.

Key changes include:

* **Persistent Backend Type Preference:** The extension now stores the user's preferred backend type (e.g., `cuda`, `cpu`, `metal`) in `localStorage`. This ensures that even after updates or restarts, the system attempts to use the user's previously selected backend type, if available.
* **Intelligent Auto-Update:** The auto-update mechanism has been refined to prioritize updating to the **latest version of the *currently selected backend type*** rather than always defaulting to the "best available" backend (which might change). This respects user choice while keeping the chosen backend type up-to-date.
* **Improved Initial Installation/Configuration:** For fresh installations or cases where the `version_backend` setting is invalid, the system now intelligently determines and installs the best available backend, then persists its type.
* **Refined Old Backend Cleanup:** The `removeOldBackends` function has been renamed to `removeOldBackend` and modified to specifically clean up *older versions of the currently selected backend type*, preventing the accumulation of unnecessary files while preserving other backend types the user might switch to.
* **Robust Local Storage Handling:** New private methods (`getStoredBackendType`, `setStoredBackendType`, `clearStoredBackendType`) are introduced to safely interact with `localStorage`, including error handling for potential `localStorage` access issues.
* **Version Filtering Utility:** A new utility `findLatestVersionForBackend` helps in identifying the latest available version for a specific backend type from a list of supported backends.

These changes provide a more stable, user-friendly, and maintainable backend management experience for the Llama.cpp extension.

Fixes: #5883

* fix: cortex models migration should be done once

* feat: Optimize Llama.cpp backend preference storage and UI updates

This commit refines the Llama.cpp extension's backend management by:

* **Optimizing `localStorage` Writes:** The system now only writes the backend type preference to `localStorage` if the new value is different from the currently stored one. This reduces unnecessary `localStorage` operations.
* **Ensuring UI Consistency on Initial Setup:** When a fresh installation or an invalid backend configuration is detected, the UI settings are now explicitly updated to reflect the newly determined `effectiveBackendString`, ensuring the displayed setting matches the active configuration.

These changes improve performance by reducing redundant storage operations and enhance user experience by maintaining UI synchronization with the backend state.

* Revert "fix: provider settings should be refreshed on page load (#5887)"

This reverts commit ce6af62c7df4a7e7ea8c0896f307309d6bf38771.

* fix: add loader version backend llamacpp

* fix: wrong key name

* fix: model setting issues

* fix: virtual dom hub

* chore: cleanup

* chore: hide device ofload setting

---------

Co-authored-by: Louis <louis@jan.ai>
Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-07-24 18:33:35 +07:00
hiento09
d51f904826
chore: update cua mac runner (#5888) 2025-07-24 16:25:02 +07:00
Ramon Perez
077707b0a3 first stab at a product page 2025-07-24 18:18:52 +10:00
Louis
ce6af62c7d
fix: provider settings should be refreshed on page load (#5887) 2025-07-24 14:30:33 +07:00
Faisal Amir
5d00cf652a
🐛fix: get system info and system usage (#5884) 2025-07-24 12:39:10 +07:00
Faisal Amir
399671488c
fix: gpu detected from backend version (#5882)
* fix: gpu detected from backend version

* chore: remove readonly props from dynamic field
2025-07-24 10:45:48 +07:00
Louis
6599d91660
fix: bring back HF repo ID search in Hub (#5880)
* fix: bring back HF search input

* test: fix useModelSources tests for updated addSource signature
2025-07-24 09:46:13 +07:00
Ramon Perez
101b4d700f mobile section updated 2025-07-24 12:43:29 +10:00
Nguyen Ngoc Minh
d8b6b10870
chore: revert app artifact name for macos linux and windows builds (#5878) 2025-07-23 21:27:56 +07:00
Akarshan Biswas
1d0bb53f2a
feat: add support for querying available backend devices (#5877)
* feat: add support for querying available backend devices

This change introduces a new `get_devices` method to the `llamacpp_extension` engine that allows the frontend to query and display a list of available devices (e.g., Vulkan, CUDA, SYCL) from the compiled `llama-server` binary.

* Added `DeviceList` interface to represent GPU/device metadata.
* Implemented `getDevices(): Promise<DeviceList[]>` method.

  * Splits `version/backend`, ensures backend is ready.
  * Invokes the new Tauri command `get_devices`.

* Introduced a new `get_devices` Tauri command.
* Parses `llama-server --list-devices` output to extract available devices with memory info.
* Introduced `DeviceInfo` struct (`id`, `name`, `mem`, `free`) and exposed it via serialization.
* Robust parsing logic using string processing (non-regex) to locate memory stats.
* Registered the new command in the `tauri::Builder` in `lib.rs`.

* Fixed logic to correctly parse multiple devices from the llama-server output.
* Handles common failure modes: binary not found, malformed memory info, etc.

This sets the foundation for device selection, memory-aware model loading, and improved diagnostics in Jan AI engine setup flows.

* Update extensions/llamacpp-extension/src/index.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-07-23 19:20:12 +05:30
Louis
d6ad797769
fix: llama.cpp backend shows blank list sometime (#5876) 2025-07-23 20:04:38 +07:00
Nguyen Ngoc Minh
9a511fd5fa
ci: resolve nested template expression in artifact names (#5875)
* ci: update artifact name for Linux and Windows build

* ci: enhance logic for naming convention for mac, linux and windows builds

* fix: resolve nested template expression in artifact names
2025-07-23 17:48:33 +07:00
Nguyen Ngoc Minh
3a8af3c24d
ci: autoqa github artifact (#5873)
* ci: add upload recordings and logs github artifact

* chore: update version actions upload artifact
2025-07-23 14:33:48 +07:00
Louis
af116dd7dc
fix: jan should have a general assistant instruction (#5872)
* fix: default Jan assistant prompt

* test: update tests
2025-07-23 13:55:20 +07:00
Louis
3afdd0fa1d
fix: tmp download file should be removed on cancel (#5849) 2025-07-23 12:52:34 +07:00
Faisal Amir
43b7eb6e18
🐛fix: remove sampling parameters from llamacpp extension (#5871) 2025-07-23 12:13:42 +07:00
Ramon Perez
ed610dcd4e new website 2025-07-23 15:10:56 +10:00
Faisal Amir
fd26270e78
🐛fix/update vulkan active syntax (#5869) 2025-07-23 11:45:54 +07:00
Louis
3e30c61fb0
fix: app should refresh local provider models list on launch (#5868) 2025-07-23 08:36:09 +07:00
Louis
fe95031c6e
feat: migrate cortex models to llamacpp extension (#5838)
* feat: migrate cortex models to new llama.cpp extension

* test: add tests

* clean: remove duplicated import
2025-07-22 23:35:08 +07:00
Nguyen Ngoc Minh
5cbd79b525
fix: charmap encoding (#5865)
* fix: handle charmap encoding error

* enhancement: prompt template for new user flow
2025-07-22 23:33:12 +07:00
Louis
d347058d6b
fix: HuggingFace provider should be non-deletable (#5856)
* fix: HuggingFace provider should be non-deletable

* refactor: rename const folder

* test: correct test case
2025-07-22 23:32:37 +07:00
Louis
8e9cd2566b
fix: gemini tool call support (#5848) 2025-07-22 23:25:43 +07:00
Akarshan Biswas
1eaec5e4f6
Fix: engine unable to find dlls on when running on Windows (#5863)
* Fix: Windows llamacpp not picking up dlls from lib repo

* Fix lib path on Windows

* Add debug info about lib_path

* Normalize lib_path for Windows

* fix window lib path normalization

* fix: missing cuda dll files on windows

* throw backend setup errors to UI

* Fix format

* Update extensions/llamacpp-extension/src/index.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* feat: add logger to llamacpp-extension

* fix: platform check

---------

Co-authored-by: Louis <louis@jan.ai>
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-07-22 20:05:24 +05:30
Nguyen Ngoc Minh
7d3811f879
chore: update build appimage script (#5866)
* chore: update new appimage kit url

* chore: add error handling for appimagetool download
2025-07-22 21:02:25 +07:00
Faisal Amir
5553096bc4
enhancement: dialog model error trigger from provider screen and improve copy button (#5858) 2025-07-22 20:36:01 +07:00
Faisal Amir
1d443e1f7d
fix: support load model configurations (#5843)
* fix: support load model configurations

* chore: remove log

* chore: sampling params add from send completion

* chore: remove comment

* chore: remove comment on predefined file

* chore: update test model service
2025-07-22 19:52:12 +07:00
Faisal Amir
7b3b6cc8be
🐛fix: delete all should not include fav thread (#5864) 2025-07-22 19:51:59 +07:00
hiento09
1dd5b810c2
Chore: enrich autoqa log (#5862)
* chore: add app log upload to reportportal
2025-07-22 16:13:00 +07:00
Akarshan Biswas
f59739d2b0
refactor: Improve Llama.cpp backend management and auto-update (#5845)
* refactor: Improve Llama.cpp backend management and auto-update

This commit refactors the Llama.cpp extension to enhance backend management and streamline the auto-update process.

Key changes include:

Refactored configureBackends: The logic for determining the best available backend and populating settings is now more modular, preventing duplicate executions.

Dedicated Auto-update Handling: Introduced a handleAutoUpdate method to encapsulate the auto-update logic, including downloading the latest available backend and updating the internal configuration and settings.

Robust Old Backend Cleanup: The removeOldBackends method is improved to ensure only the currently used backend version and type are kept, effectively managing disk space. A delay is added for Windows to prevent file conflicts during cleanup.

Final Installation Check: A ensureFinalBackendInstallation method is added to guarantee the selected backend is installed, acting as a final safeguard after auto-update or if auto-update is disabled.

Minor Fixes:

Added console.log for save_path during decompression for better debugging.

Ensured the output directory exists before decompression in the Rust backend.

Removed extraneous console log for session info.

Updated Cargo.toml and tauri.conf.json versions.

These changes lead to a more reliable and efficient Llama.cpp backend experience within the application, particularly for users with auto-update enabled.

* fix isBackendInstalled parameters

* Address bot's comments

* Address bot comments of using try finally block
2025-07-22 14:35:34 +05:30
Nguyen Ngoc Minh
e3813ab1af
fix: autoqa prompt template (#5854) 2025-07-22 13:34:43 +07:00
Louis
e424938e02
Merge branch 'dev' into release/v0.6.6
# Conflicts:
#	.github/workflows/template-tauri-build-windows-x64.yml
#	Makefile
#	extensions/engine-management-extension/engines.mjs
2025-07-22 13:18:00 +07:00
Nguyen Ngoc Minh
fceecffed7
feat: add vcruntime for windows installer (#5852) 2025-07-22 12:38:00 +07:00
Faisal Amir
25952f293c
enhancement: auto focus always allow action from tool approval dialog and add req parameters (#5836)
* enhancement: auto focus always allow action from tool approval dialog

* chore: error handling tools parameters

* chore: update test button focus cases
2025-07-22 12:17:53 +07:00
Faisal Amir
78df0a20ec
enhancement: better error page component (#5834)
* enhancement: better error page component

* chore: typo and useless space
2025-07-22 12:17:44 +07:00
Nguyen Ngoc Minh
af892428a5
chore: sync make build with dev (#5847)
* chore: sync up make build with dev

* ci: update macOS self-hosted runner
2025-07-22 11:12:14 +07:00
Nguyen Ngoc Minh
e82e5e1da9
refactor: standardize build process and remove build-tauri target (#5846) 2025-07-22 00:01:48 +07:00
Nguyen Ngoc Minh
9ea081576b
fix: custom tauri nsis template CheckIfAppIsRunning macro (#5840)
* fix: update CheckIfAppIsRunning macro to include args
2025-07-21 20:54:06 +07:00
Nguyen Ngoc Minh
275cab7538
Merge pull request #5839 from menloresearch/fix/appimage-url-with-latest-tauri-cli
fix: update @taur-apps/cli to newest verison to fix appimage download
2025-07-21 03:41:27 -07:00
Minh141120
db962b2ba6 fix: update @taur-apps/cli to newest verison to fix appimage download issue 2025-07-21 16:32:27 +07:00
Akarshan Biswas
08de0fa42d
fix: prevent terminal window from opening on model load on WindowsOS (#5837)
On Windows, spawning the llamacpp server was causing an unwanted terminal window
to appear. This is now fixed by combining `CREATE_NO_WINDOW` with
`CREATE_NEW_PROCESS_GROUP` using `.creation_flags(...)`, ensuring that the
process runs in the background without a console window.

This change only applies to 64-bit Windows builds.
2025-07-21 13:24:31 +05:30
Louis
05b9d4e9fd
feat: add claude-4 (#5829)
* feat: add claude-4

* fix: sorting order
2025-07-21 12:30:56 +07:00
Akarshan Biswas
81d6ed3785
feat: support per-model overrides in llama.cpp load() (#5820)
* feat: support per-model overrides in llama.cpp load()

Extend the `load()` method in the llama.cpp extension to accept optional
`overrideSettings`, allowing fine-grained per-model configuration.

This enables users to override provider-level settings such as `ctx_size`,
`chat_template`, `n_gpu_layers`, etc., when loading a specific model.

Fixes: #5818 (Feature Request - Jan v0.6.6)

Use cases enabled:
- Different context sizes per model (e.g., 4K vs 32K)
- Model-specific chat templates (ChatML, Alpaca, etc.)
- Performance tuning (threads, GPU layers)
- Better memory management per deployment

Maintains full backward compatibility with existing provider config.

* swap overrideSettings and isEmbedding argument
2025-07-21 08:59:50 +05:30
Louis
bc4fe52f8d
fix: llama.cpp integration model load and chat experience (#5823)
* fix: stop generating should not stop running models

* fix: ensure backend ready before loading model

* fix: backend setting should not block onLoad
2025-07-21 09:29:26 +07:00
Louis
5241557a74
test: deprecate webdriver test in favor of auto qa using CUA (#5825) 2025-07-21 00:11:16 +07:00
Louis
c03f6fcc3a
Revert "chore(deps): update rand requirement from 0.8 to 0.9 in /src-tauri (#…" (#5824)
This reverts commit 722a6881fdca47181c2184a0b62a26ec25d014d0.
2025-07-20 23:55:45 +07:00
Louis
5696e951f2
fix: Legacy threads show on top of new threads (#5696) (#5810)
* fix: #5696 - legacy threads show on top of new threads

* fix: tests
2025-07-20 16:58:22 +07:00
Louis
19cb1c96e0
fix: llama.cpp backend download on windows (#5813)
* fix: llama.cpp backend download on windows

* test: add missing cases

* clean: linter

* fix: build
2025-07-20 16:58:09 +07:00
Louis
05a5995865
fix: dependabot should just update security patch (#5814) 2025-07-20 16:55:40 +07:00
dependabot[bot]
722a6881fd
chore(deps): update rand requirement from 0.8 to 0.9 in /src-tauri (#5399)
Updates the requirements on [rand](https://github.com/rust-random/rand) to permit the latest version.
- [Release notes](https://github.com/rust-random/rand/releases)
- [Changelog](https://github.com/rust-random/rand/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-random/rand/compare/0.8.0...rand_core-0.9.1)

---
updated-dependencies:
- dependency-name: rand
  dependency-version: 0.9.1
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-20 16:11:43 +07:00
Trang Le
04f8bf0903
Update mcp.mdx (#5771)
The original instruction doesn't tell users to enable experimental features in Jan first. Without it, the MCP Servers tab won't appear.
2025-07-20 15:20:53 +07:00
dependabot[bot]
4d0b777f9f
chore(deps): bump @radix-ui/react-hover-card from 1.1.11 to 1.1.14 (#5603)
---
updated-dependencies:
- dependency-name: "@radix-ui/react-hover-card"
  dependency-version: 1.1.14
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-20 15:20:18 +07:00
hiento09
b7b3eb9d19
fix: autoqa requirements.txt (#5812) 2025-07-19 22:47:34 +07:00
Louis
c550f6cf0d
Merge pull request #5809 from menloresearch/refactor/simplify-proxy-settings
refactor: simplify proxy settings by removing unused SSL verification options
2025-07-19 16:34:37 +07:00
Louis
5fdae1259b
Merge pull request #5808 from gary149/feat/huggingface-integration
feat: Add Hugging Face as a provider
2025-07-19 14:33:44 +07:00
Victor Muštar
18dfe2b883 chore: update model descriptions in huggingface.json to match web app mock data 2025-07-18 19:53:12 +02:00
Victor Muštar
6ce26b7b6d chore: update model descriptions for clarity and accuracy 2025-07-18 19:31:07 +02:00
Victor Muštar
178d1546fe feat: integrate Hugging Face provider into web app and engine management 2025-07-18 19:10:30 +02:00
Victor Muštar
54c1bf6950 feat: add Hugging Face engine configuration and model definitions 2025-07-18 19:10:14 +02:00
Victor Muštar
7927f4ca2b feat: add Hugging Face logo asset 2025-07-18 19:09:59 +02:00
Akarshan Biswas
8f1a36c8e3
fix: Improve stream error handling and parsing (#5807)
* fix: Enhance stream error handling and parsing

This commit improves the robustness of stream processing in the llamacpp-extension.

- Adds explicit handling for 'error:' prefixed lines in the stream, parsing the contained JSON error and throwing an appropriate JavaScript Error.
- Centralizes JSON parsing of 'data:' and 'error:' lines, ensuring consistent error propagation by re-throwing parsing exceptions.
- Ensures the async iterator terminates correctly upon encountering stream errors or malformed JSON.

* Address bot comments and cleanup
2025-07-18 18:36:33 +05:30
Akarshan
59ad2eb784
Merge branch 'dev' into release/v0.6.6 2025-07-18 18:29:20 +05:30
hiento09
4d44f4324d
feat: add autoqa (#5779)
* feat: add autoqa

* chore: add auto start computer_server

* chore: add ci autoqa windows

* chore: add ci support for both windows and linux

* chore: add ci support for macos

* chore: refactor auto qa

* chore: refactor autoqa workflow

* chore: fix upload turn
2025-07-18 15:22:31 +07:00
Louis
a56e58f69b
Merge pull request #5782 from ethanova/fix/no-more-code-line-number-selection
set line number userSelect to none so that code can be copied without line number
2025-07-18 10:08:46 +07:00
Louis
8d84c3b884
feat: add model load error handling to improve UX (#5802)
* feat: model load error handling

* chore: clean up

* test: add tests

* fix: provider name
2025-07-18 08:25:54 +05:30
Akarshan Biswas
bcb60378c0
fix: Add --reasoning-format none to support rendering of reasoning content (#5803) 2025-07-18 08:22:37 +05:30
Louis
8ca507c01c
feat: proxy support for the new downloader (#5795)
* feat: proxy support for the new downloader

* test: remove outdated test

* ci: clean up
2025-07-17 23:10:21 +07:00
Louis
32966f9259
Merge pull request #5801 from menloresearch/release/v0.6.5
Sync release/0.6.5 into dev to start new development cycle
2025-07-17 22:22:32 +07:00
Akarshan Biswas
92703bceb2
refactor: move thinking toggle to runtime settings for dynamic control (#5800)
* refactor: move thinking toggle to runtime settings for per-message control

Replaces the static `reasoning_budget` config with a dynamic `enable_thinking` flag under `chat_template_kwargs`, allowing models like Jan-nano and Qwen3 to enable/disable thinking behavior at runtime, even mid-conversation.
Requires UI update

* remove engine argument
2025-07-17 20:18:24 +05:30
Louis
4699b07ca6
Merge pull request #5797 from menloresearch/test/deprecate-webdriver-test
test: deprecate webdriver test in favor of auto qa using CUA
2025-07-17 21:28:12 +07:00
Ramon Perez
333cd3a694
Merge pull request #5799 from menloresearch/ramon/docs-v0.6.5 2025-07-17 20:26:04 +10:00
Ramon Perez
f606ba6906
Update settings.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-07-17 20:24:58 +10:00
Ramon Perez
5d87dc8d32
Update 2025-07-17-responsive-ui.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-07-17 20:24:48 +10:00
Ramon Perez
2f77c6ba9c Addedd changelog, reorganized docs, added MCP examples, and updated different pages. 2025-07-17 19:49:00 +10:00
Louis
c2839794cf
fix: bump token.js to fix gemini provider base url issue 2025-07-17 14:27:49 +07:00
Akarshan Biswas
b736d09168
fix: Prevent spamming /health endpoint and improve startup and resolve compiler warnings (#5784)
* fix: Prevent spamming /health endpoint and improve startup and resolve compiler warnings

This commit introduces a delay and improved logic to the /health endpoint checks in the llamacpp extension, preventing excessive requests during model loading.

Additionally, it addresses several Rust compiler warnings by:
- Commenting out an unused `handle_app_quit` function in `src/core/mcp.rs`.
- Explicitly declaring `target_port`, `session_api_key`, and `buffered_body` as mutable in `src/core/server.rs`.
- Commenting out unused `tokio` imports in `src/core/setup.rs`.
- Enhancing the `load_llama_model` function in `src/core/utils/extensions/inference_llamacpp_extension/server.rs` to better monitor stdout/stderr for readiness and errors, and handle timeouts.
- Commenting out an unused `std::path::Prefix` import and adjusting `normalize_path` in `src/core/utils/mod.rs`.
- Updating the application version to 0.6.904 in `tauri.conf.json`.

* fix grammar!

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* fix grammar 2

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* reimport prefix but only on Windows

* remove instead of commenting

* remove redundant check

* sync app version in cargo.toml with tauri.conf

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-07-16 18:18:11 +05:30
Louis
b17c6f4eb6
Merge pull request #5791 from menloresearch/fix/fetch-models-from-custom-endpoint-crashes-app
fix: fetch models from custom provider causes app to crash
2025-07-16 16:01:19 +07:00
Louis
3eaa3424e1
fix: fetch models from custom provider causes app to crash 2025-07-16 15:36:45 +07:00
Ramon Perez
44082846d5 new tutorials, reorganization, and pages 2025-07-16 16:04:30 +10:00
Louis
646f40d664
chore: token-js version bump 2025-07-16 11:37:40 +07:00
Ethan Garber
a3b95f01de add comment to justify style block 2025-07-15 21:14:24 -04:00
Ethan Garber
b0e66993fe set line number userSelect to none so that code can be copied without line number 2025-07-15 21:10:22 -04:00
Louis
bd3b8bff35
Merge pull request #5781 from menloresearch/test/add-missing-tests
test: add missing unit tests
2025-07-15 22:56:22 +07:00
Louis
9872a6e82a test: add missing unit tests 2025-07-15 22:29:28 +07:00
Louis
f083fafcfd
Merge pull request #5776 from menloresearch/fix/download-icon
🐛fix: download icon when left panel close
2025-07-15 11:44:29 +07:00
Louis
08fe2c27fd
fix: translations 2025-07-15 11:11:00 +07:00
Nguyen Ngoc Minh
f674c786ba
Merge pull request #5778 from menloresearch/fix/revert-windows-installation-mode
fix: revert installationmode in nsis template
2025-07-15 11:02:42 +07:00
Faisal Amir
02c049653e
🐛fix: revert back stat hover for three dots (#5777) 2025-07-15 10:34:02 +07:00
Minh141120
65bc24530f fix: change installationmode in nsis template 2025-07-15 10:23:22 +07:00
Louis
8e85c2fd06
fix: bump llama.cpp b5857 on windows 2025-07-15 10:15:03 +07:00
Faisal Amir
55b68df956 🐛fix: download icon when left panel close 2025-07-15 09:39:51 +07:00
Sam Hoang Van
9a76c94e22
update rmcp to fix issues (#5290) 2025-07-14 16:49:27 +07:00
Akarshan Biswas
dee98f41d1
Feat: Improved llamacpp Server Stability and Diagnostics (#5761)
* feat: Improve llamacpp server error reporting and model load stability

This commit introduces significant improvements to how the llamacpp server
process is managed and how its errors are reported.

Key changes:
- **Enhanced Error Reporting:** The llamacpp server's stdout and stderr
  are now piped and captured. If the llamacpp process exits prematurely
  or fails to start, its stderr output is captured and returned as a
  `LlamacppError`. This provides much more specific and actionable
  diagnostic information for users and developers.
- **Increased Model Load Timeout:** The `waitForModelLoad` timeout has
  been increased from 30 seconds to 240 seconds (4 minutes). This
  addresses issues where larger models or slower systems would
  prematurely time out during the model loading phase.
- **API Secret Update:** The internal API secret for the llamacpp
  extension has been updated from 'Jan' to 'JustAskNow'.
- **Version Bump:** The application version in `tauri.conf.json` has
  been incremented to `0.6.901`.

* fix: should not spam load requests

* test: add test to cover the fix

* refactor: clean up

* test: add more test case

---------

Co-authored-by: Louis <louis@jan.ai>
2025-07-14 11:55:44 +05:30
Akarshan Biswas
96ba42e411
feat: Add missing ctx-shift toggle (#5765)
* feat: Add missing ctx_shift

* fix typo

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* refine description

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-07-14 11:51:34 +05:30
Louis
eaf4b1b954
Merge pull request #5757 from menloresearch/test/add-tests
test: add missing unit tests
2025-07-14 09:55:53 +07:00
Sherzod Mutalov
1ff62de3b6
Merge branch 'dev' into feat/old-mac-support 2025-07-13 16:29:36 +05:00
Louis
03bcd02002
test: add missing unit tests 2025-07-12 22:46:27 +07:00
Louis
c2790d9181
test: remove route tests 2025-07-12 21:35:49 +07:00
Louis
864ad50880
test: add missing tests 2025-07-12 21:29:51 +07:00
Louis
c5fd964bf2 test: add missing tests 2025-07-12 20:15:45 +07:00
Louis
191537884e
Merge pull request #5759 from menloresearch/fix/test-coverage-upload-lcov
fix: vitest config - coverage lcov
2025-07-12 20:14:42 +07:00
Louis
09a45baa5d
fix: vitest config - coverage lcov 2025-07-12 20:09:31 +07:00
Louis
c23c34583d
Merge pull request #4965 from menloresearch/feat/inference-llamacpp-extension
feat: llama.cpp provider extension to replace cortex.cpp
2025-07-11 09:25:47 +07:00
Louis
b2ce138ea0
test: add tests 2025-07-11 09:21:11 +07:00
Louis
b8259e7794 feat: add HF token setting 2025-07-11 00:05:52 +07:00
Louis
9cea579c8e
fix: build issue 2025-07-10 22:16:31 +07:00
Louis
114f2b9092
ci: attempt to upload cov 2025-07-10 21:51:13 +07:00
Louis
963ad448f5
fix: build 2025-07-10 21:23:04 +07:00
Nguyen Ngoc Minh
0f7f2a7b38
Merge pull request #5745 from menloresearch/refactor/tauri-workflow
refactor: tauri workflow
2025-07-10 21:18:26 +07:00
Louis
a770e08013
test: migrate jest to vitest 2025-07-10 21:14:21 +07:00
Louis
1c7a20be44
fix: linux build 2025-07-10 21:14:20 +07:00
Louis
bc0ea343cc
fix: remove legacy build step 2025-07-10 20:24:11 +07:00
Louis
37718d1e71
fix: build issue with legacy libs 2025-07-10 20:17:20 +07:00
Louis
af8404d627
fix: tests 2025-07-10 20:16:09 +07:00
Louis
5fe4cc6bab
chore: remove cortex install step 2025-07-10 20:09:26 +07:00
Louis
389721ba89
fix: build step 2025-07-10 16:49:21 +07:00
Louis
ca6f4f8977
test: fix failed tests 2025-07-10 16:25:47 +07:00
Louis
6e0218c084
Merge branch 'release/v0.7.0' into feat/inference-llamacpp-extension
# Conflicts:
#	.devcontainer/buildAppImage.sh
#	.github/workflows/template-tauri-build-linux-x64.yml
#	Makefile
#	core/src/node/extension/index.test.ts
#	package.json
#	src-tauri/tauri.conf.json
#	web-app/package.json
2025-07-10 15:36:41 +07:00
Louis
94d9304c0b
Merge branch 'dev' into release/v0.7.0 2025-07-10 15:33:21 +07:00
Minh141120
94ada5969b refactor: deprecate electron-checksum.py script 2025-07-10 15:05:51 +07:00
Minh141120
39256dad09 refactor: clean up tauri build workflow for macos 2025-07-10 15:05:21 +07:00
Minh141120
291a32759a refactor: clean up tauri build workflow for windows 2025-07-10 15:03:41 +07:00
Minh141120
3790bd5753 refactor: clean up tauri build workflow for linux 2025-07-10 15:01:52 +07:00
Minh141120
0fd346181c chore: enable active installation for window installer 2025-07-10 14:57:55 +07:00
Nguyen Ngoc Minh
5b01d0c196
Merge pull request #5732 from DistractionRectangle/refactor/linux-build-process
Refactor/linux build process
2025-07-10 13:03:01 +07:00
Louis
08342b5b00
Merge pull request #5742 from menloresearch/feat/bump-version-of-llamacpp
feat: bump version of llama.cpp - b5857
2025-07-10 12:51:36 +07:00
Louis
10bb8527bd
feat: bump llama.cpp b5857 2025-07-10 11:51:27 +07:00
D. Rect.
a668204cdc refactor: pin linuxdeploy in make/yarn build process instead of github workflow
- pulls fix for #5463 out of the github release workflow and into
  the make/yarn build process
- implements a wrapper script that pins linuxdeploy and injects
  a new location for XDG_CACHE_HOME into the build pipeline,
  allowing manipulating .cache/tauri without tainting the hosts
  .cache
- adds ./.cache (project_root/.cache) to make clean and mise clean
  task
- remove .devcontainer/buildAppImage.sh, obsolete now that extra
  build steps have been removed from the github workflow and
  incorporated in the normal build process
- remove appimagetool from .devcontainer/postCreateCommand.sh,
  as it was only used by .devcontainer/buildAppImage.sh
2025-07-10 04:50:12 +00:00
D. Rect.
7d04d66a0b refactor: pull appimage packaging steps out of github linux release workflow
- pulled appimage packaging steps out of release workflow into new
  src-tauri/build-utils/buildAppImage.sh
- cleaned up yarn scripts:
  - moved multi platform yarn scripts out of yarn build:tauri:<platform>
    into generic yarn build:tauri
  - split yarn build:tauri:linux:win32 into separate yarn scripts so it's
    clearer what is specific to which platform
- added src-tauri/build-utils/buildAppImage.sh to new yarn build:tauri:linux
  yarn script

    This is also a good entry point to add flatpak builds in the future.

    Part of #5641
2025-07-10 04:50:12 +00:00
D. Rect.
4134917a45 refactor: split platform specific config out of tauri.conf.json
Allows for better per platform default config. Currently the
default serves windows/macos fine while it has to be tweaked
in order to build for linux

make build-tauri now successfully runs where it errored out before.
Appimages made with make alone however is incomplete as there are
still post processing steps in the github release workflow to bundle
additional resources.

- split platform specific config out of tauri.conf.json into auxiliary
  platform specific config files, natively supported by tauri

- pull improved defaults out of template-tauri-build-linux-x64.yml
  into new tauri.linux.conf.json

- fix tauri-build-linx-x64.yml to utilize new tauri.linux.conf.json
2025-07-10 04:50:12 +00:00
Louis
a8ed759a06 fix: model download - windows path issue 2025-07-10 09:42:36 +07:00
Louis
61cd33284d
Merge pull request #5579 from bob-ros2/de_de-i18n
Add language support locale de-DE Germany
2025-07-10 08:52:18 +07:00
Louis
46c95ebb97
feat: bump version of llama.cpp - b5833 2025-07-10 08:29:56 +07:00
Louis
9567bd9a49
Merge branch 'dev' into de_de-i18n 2025-07-08 16:42:32 +07:00
hiento09
d2d8778425
chore: disable coverage check for external contributor pr (#5728) 2025-07-08 16:36:38 +07:00
Louis
2f02a228cc
fix: download on windows 2025-07-08 15:41:17 +07:00
Bob Ros
e160339c7b
Merge branch 'dev' into de_de-i18n 2025-07-08 09:38:09 +02:00
Faisal Amir
60b7e6a081
🐛fix: think tag auto expand like tool tag behavior (#5727) 2025-07-08 11:11:46 +07:00
Bob Ros
0a3185f88d
Merge branch 'dev' into de_de-i18n 2025-07-07 22:18:55 +02:00
Louis
b26ae7d0a4
ci: remove cortex build steps 2025-07-07 22:39:04 +07:00
Akarshan
d5ffc6a476
feat: Migrate Jan's API server to llamacpp-extension
Things to ponder:
- Now, the v1/models endpoint of the API server will return an empty
  list if no models are loaded
- Streaming v1/chat/completion routing works as well as v1/models; needs
  further testing
2025-07-07 20:52:00 +05:30
Louis
e3faf09ab2
chore: try fixing CI 2025-07-07 21:27:37 +07:00
Louis
5ce9bbb304
fix: linux build without cortex binaries 2025-07-07 18:56:04 +07:00
Louis
e75bb0de27
fix: libvulkan download 2025-07-07 18:40:25 +07:00
Louis
6b496ae413
fix: build issues 2025-07-07 18:27:45 +07:00
Faisal Amir
42d4d48362
fix: broken hero image landing page website (#5719) 2025-07-07 14:06:59 +07:00
Louis
ccab7f9119
Merge pull request #5389 from STRRL/feat/identify-jan-on-openrouter
feat: identidy jan for openrouter
2025-07-07 12:51:55 +07:00
Louis
a2c59e9934
Merge pull request #5715 from menloresearch/release/v0.6.6
Merge Release/v0.6.6 into release 0.6.5
2025-07-07 11:43:04 +07:00
hiento09
641275ee79
chore: add coverage report comment (#5716) 2025-07-07 11:37:57 +07:00
hiento09
3287e8b300
chore: enable test coverage (#5710)
* chore: enable test coverage
2025-07-07 11:24:13 +07:00
Faisal Amir
977a8a5774
Update web-app/src/routes/settings/providers/index.tsx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-07-07 11:19:00 +07:00
Faisal Amir
1422d94fac
🐛fix: make three dots default show 3 dots and can trigger with right click (#5712)
* 🐛fix: default show 3 dots

* enhancement: enable resizable left panel (#5713)

* enhancement: enable resizable left panel

* Update web-app/src/hooks/useLeftPanel.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-07-07 11:14:43 +07:00
Faisal Amir
a0be23b500
enhancement: show readme on detail each model (#5705)
* 🧹cleanup: linter and log

* Update web-app/src/routes/hub/$modelId.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-07-07 09:54:16 +07:00
Louis
9696589e79
Merge pull request #5389 from STRRL/feat/identify-jan-on-openrouter
feat: identidy jan for openrouter
2025-07-07 09:32:46 +07:00
Louis
9975580497
Merge pull request #5358 from ethanova/allow-assistant-message-edits 2025-07-07 08:22:24 +07:00
Zhiqiang ZHOU
9ff3cbe63f
Merge remote-tracking branch 'upstream/dev' into feat/identify-jan-on-openrouter 2025-07-06 11:54:46 -07:00
Ethan Garber
5bf78a31d9 streaming content doesn't need to deal with edits so doesn't need updateMessage function 2025-07-05 21:41:29 -04:00
Ethan Garber
a1ff097336 Merge branch 'dev' into allow-assistant-message-edits 2025-07-05 19:58:24 -04:00
Akarshan
d4a3d6a0d6
Refactor session PID types from string to number across backend and extension
- Changed `pid` field in `SessionInfo` from `string` to `number`/`i32` in TypeScript and Rust.
- Updated `activeSessions` map key from `string` to `number` to align with new PID type.
- Adjusted process monitoring logic to correctly handle numeric PIDs.
- Removed fallback UUID-based PID generation in favor of numeric fallback (-1).
- Added PID cleanup logic in `is_process_running` when the process is no longer alive.
- Bumped application version from 0.5.16 to 0.6.900 in `tauri.conf.json`.
2025-07-04 21:40:54 +05:30
Akarshan
dbdc031583
chore: store session_info in backend as well for API server(WIP) 2025-07-04 20:31:30 +05:30
Sherzod Mutalov
f8daa07a48
Merge branch 'dev' into feat/old-mac-support 2025-07-04 10:03:03 +05:00
Sam Hoang Van
36c2024cb3
fix: update base URL for Anthropic provider (#5600) 2025-07-04 09:43:45 +07:00
Bob Ros
4665876698
Merge branch 'menloresearch:dev' into de_de-i18n 2025-07-03 23:35:01 +02:00
Akarshan
ffef7b9cab enhancement: Add custom Jinja chat template option
Adds a new configuration option `chat_template` to the Llama.cpp extension, allowing users to define a custom Jinja chat template for the model.

The template can be provided via a new input field in the settings, and if set, it will be passed to the Llama.cpp backend using the `--chat-template` argument. This enhances flexibility for users who require specific chat formatting beyond the GGUF default.

The `chat_template` is added to the `LlamacppConfig` type and conditionally pushed to the command arguments if it's provided. The placeholder text provides an example of a Jinja template structure.
2025-07-03 23:38:16 +07:00
Faisal Amir
3a197d56c0 enhancement: filter active gpu on system monitor 2025-07-03 23:36:53 +07:00
Faisal Amir
19fc399ae1 enhancement: gpu list based on backend 2025-07-03 23:18:50 +07:00
Akarshan
40f1fd4ffd
feat: Auto update backend implementation 2025-07-03 19:32:12 +05:30
Akarshan
03f0c5aad6
fix: remove unsupported BOOL for windows_sys in cleanup to fix windows build(attempt 3) 2025-07-03 18:35:13 +05:30
Akarshan
11db1ecaed
fix: server-side Ctrl-C handling for Windows x86_64 targets (attempt 2)
The current implementation of Ctrl-C handling was not properly tested on Windows x86_64 architectures. To address this, the code has been modified to use `i32` instead of `BOOL` to handle the result of the `GenerateConsoleCtrlEvent` function, ensuring that the return value is correctly checked across different platforms.
2025-07-03 14:13:56 +05:30
Akarshan
6ab7d37a08
fix: Update Cargo.toml dependencies on Windows & fix Ctrl+C handling on Windows
This change updates the dependencies of the Cargo.toml file on Windows to include additional features from the `windows-sys` crate. The `CreateProcess flags like CREATE_NEW_PROCESS_GROUP` feature is now enabled to allow for proper process management.
The code now properly sends Ctrl+C to the llama process on Windows, and also includes error handling for when the Ctrl+C command fails. Additionally, it now uses the `Windows` API to kill the process when it times out, and properly handles the wait for the process to exit.
2025-07-03 13:51:59 +05:30
Faisal Amir
c34291237f enhancement: add hub detail page 2025-07-03 13:36:00 +07:00
Faisal Amir
0343c09704 🧹cleanup: hub model title should not truncate just let make another line 2025-07-03 11:05:34 +07:00
Akarshan
c2493fc535
Fix camelCase 2025-07-03 09:13:33 +05:30
Akarshan
396573055f
Address bot's review comment and minor refactoring 2025-07-03 09:13:33 +05:30
Akarshan
37151ba926
Feat: Auto load and download default backend during first launch 2025-07-03 09:13:32 +05:30
hiento09
f572350c20
chore: migrate to selfhosted runner (#5593) 2025-07-03 00:05:52 +07:00
Bob Ros
c778e8bcac
Merge branch 'dev' into de_de-i18n 2025-07-02 15:49:59 +02:00
Bui Quang Huy
b173fe2dcb
Merge pull request #5677 from menloresearch/template/add-type
Update 2-feature-request.md
2025-07-02 19:00:30 +08:00
Bui Quang Huy
264895cd59
Update 2-feature-request.md 2025-07-02 18:59:07 +08:00
Louis
e123d22b8d
fix: deprecate sidecar run 2025-07-02 12:48:50 +07:00
Akarshan
663c720f2a
Add windows-sys to cargo.toml 2025-07-02 12:29:03 +07:00
Akarshan
449bf17692
Add process aliveness check 2025-07-02 12:29:03 +07:00
Louis
0dbfde4c80
refactor: wait for extension load 2025-07-02 12:29:02 +07:00
Louis
66bae2adb8
chore: clean up 2025-07-02 12:29:02 +07:00
Louis
9b730058b4
feat: use hardware information api 2025-07-02 12:29:02 +07:00
Louis
d264220245
fix: restrict Windows-specific code to x86_64 and update scripts
Updated Rust code to apply Windows-specific logic only on x86_64 targets using #[cfg(all(windows, target_arch = "x86_64"))]. Modified dev:tauri script in package.json to remove CLEAN=true and added CLEAN=true to beforeDevCommand in tauri.conf.json for consistency. Minor formatting changes in tauri.conf.json.
2025-07-02 12:29:02 +07:00
Louis
2bdbce2e40
refactor: clean up unused apis 2025-07-02 12:29:02 +07:00
Louis
c6ac9f1d2a
feat: sync hub with model catalog 2025-07-02 12:29:01 +07:00
Louis
c9c1ff1778
refactor: clean up core node packages 2025-07-02 12:28:38 +07:00
Louis
b538d57207
feat: auto unload models on model start 2025-07-02 12:28:25 +07:00
Akarshan
0cbf35dc77
Add auto unload setting to llamacpp-extension 2025-07-02 12:28:25 +07:00
Louis
f70bb2705d
🔧test: util and lib unit tests 2025-07-02 12:28:25 +07:00
Louis
5edc773535
fix: wait for model start 2025-07-02 12:28:25 +07:00
Akarshan
54691044d4
Add missing --jinja flag 2025-07-02 12:28:25 +07:00
Louis
ae58c427a5
fix: tool call params 2025-07-02 12:28:25 +07:00
Akarshan
6b86baaa2f
Add tool choice type 2025-07-02 12:28:24 +07:00
Akarshan
6d5251d1c6
Fixup tool type definition 2025-07-02 12:28:24 +07:00
Akarshan
7f25311d26
Add tool type to chat completion requests 2025-07-02 12:28:24 +07:00
Louis
8bd4a3389f
refactor: frontend uses new engine extension
# Conflicts:
#	extensions/model-extension/resources/default.json
#	web-app/src/containers/dialogs/DeleteProvider.tsx
#	web-app/src/routes/hub.tsx
2025-07-02 12:28:24 +07:00
Akarshan
ad06b2a903
Move llama-server cleanup code to a separate file 2025-07-02 12:27:42 +07:00
Akarshan
7de694c0cd
add missing import during rebase 2025-07-02 12:27:42 +07:00
Akarshan
62ba503b86
chore: cleanup llama-server processes upon app exit 2025-07-02 12:27:42 +07:00
Akarshan
01d49a4b28
fix: Update server process handling for Windows and Unix systems 2025-07-02 12:27:42 +07:00
Thien Tran
7dbc2c3af2
download lib at build time 2025-07-02 12:27:41 +07:00
Akarshan
48d1164858
feat: add embedding support to llamacpp extension
This commit introduces embedding functionality to the llamacpp extension. It allows users to generate embeddings for text inputs using the 'sentence-transformer-mini' model.  The changes include:

- Adding a new `embed` method to the `llamacpp_extension` class.
- Implementing model loading and API interaction for embeddings.
- Handling potential errors during API requests.
- Adding necessary types for embedding responses and data.
- The load method now accepts a boolean parameter to determine if it should load embedding model.
2025-07-02 12:27:36 +07:00
Akarshan
2eeabf8ae6
fix: ensure server process is properly terminated and reaped 2025-07-02 12:27:35 +07:00
Akarshan
f463008362
feat: add model load wait to ensure model is ready before use 2025-07-02 12:27:35 +07:00
Akarshan
9d4e7cb2b8
fix: correct model_id to model_id in console error message
This change ensures that the error message includes the correct model ID, as `modelId` is capitalized in the `sInfo` object.
2025-07-02 12:27:35 +07:00
Akarshan
d60257ebbd
Revert: extension/yarn.lock 2025-07-02 12:27:35 +07:00
Akarshan
dbcce86bb8
refactor: rename interfaces and add getLoadedModels
The changes include:
- Renaming interfaces (sessionInfo -> SessionInfo, unloadResult -> UnloadResult) for consistency
- Adding getLoadedModels() method to retrieve active model IDs
- Updating variable names from modelId to model_id for alignment
- Updating cleanup paths to use XDG-standard locations
- Improving type consistency across extension implementation
2025-07-02 12:27:35 +07:00
Akarshan
4ffc504150
style: Rename camelCase to snake_case in llamacpp extension code
Rename variable, struct, and enum names from camelCase to snake_case throughout the llamacpp extension codebase to align with Rust naming conventions. This change improves readability and consistency without altering functionality.
2025-07-02 12:27:34 +07:00
Akarshan
c2b606a3fc
feat: enhance chatCompletionRequest with advanced sampling parameters
Add comprehensive sampling parameters for fine-grained control over AI output generation, including dynamic temperature, Mirostat sampling, repetition penalties, and advanced prompt handling. These parameters enable more precise tuning of model behavior and output quality.
2025-07-02 12:27:34 +07:00
Akarshan
6c769c5db9
feat: refactor llama server process storage to use HashMap
Change the llama_server_process state from an Option<Child> to a HashMap<String, Child> to support managing multiple server instances by PID. This allows precise process tracking and termination, replacing the previous single-process limitation.

Previously, only one server process could be tracked at a time. Now, each process is stored with its PID as the key, enabling:
- Accurate session matching during unloading
- Proper termination of specific processes
- Better error handling for mismatched PIDs

The load_llama_model function now inserts processes into the map, and unload_llama_model removes them by PID.
2025-07-02 12:27:34 +07:00
Thien Tran
8bf4a5eb7d
remove migration 2025-07-02 12:27:34 +07:00
Thien Tran
525cc93d4a
fix system cudart detection on linux 2025-07-02 12:27:34 +07:00
Thien Tran
ae349159ce
remove yarn install:cortex 2025-07-02 12:27:33 +07:00
Thien Tran
95944fa081
add Jan's library path to path 2025-07-02 12:27:17 +07:00
Thien Tran
65d6f34878
check for system libraries 2025-07-02 12:27:17 +07:00
Thien Tran
1eb49350e9
add is_library_available command 2025-07-02 12:27:17 +07:00
Thien Tran
622f4118c0
add placeholder for windows and linux arm 2025-07-02 12:27:17 +07:00
Thien Tran
f7bcf43334
update folde structure. small refactoring 2025-07-02 12:27:16 +07:00
Thien Tran
3b72d80979
fix wrong key for backend 2025-07-02 12:27:16 +07:00
Akarshan Biswas
331c0e04a5
fix: use modelId instead of sessionId for unloading
The loop now extracts session info to retrieve the model ID, ensuring correct unloading of sessions by their associated model identifiers rather than session IDs. This aligns the cleanup process with the actual model resources being managed.
2025-07-02 12:27:16 +07:00
Akarshan Biswas
e3d6cbd80f
feat: add port parameter to generateApiKey for secure model-specific API keys
The generateApiKey method now incorporates the model's port to create a unique,
port-specific API key, enhancing security by ensuring keys are tied to both
model ID and port. This change supports better isolation between models
running on different ports. Code formatting improvements were also made
for consistency and readability.
2025-07-02 12:27:16 +07:00
Akarshan Biswas
4dfdcd68d5
refactor: rename session identifiers to pid and modelId
The changes standardize identifier names across the codebase for clarity:
- Replaced `sessionId` with `pid` to reflect process ID usage
- Changed `modelName` to `modelId` for consistency with identifier naming
- Renamed `api_key` to `apiKey` for camelCase consistency
- Updated corresponding methods to use these new identifiers
- Improved type safety and readability by aligning variable names with their semantic meaning
2025-07-02 12:27:16 +07:00
Akarshan Biswas
f9d3935269
feat: allow specifying port via command line argument
This change allows the port to be specified via command line arguments, providing flexibility. The port is parsed from the arguments, defaulting to 8080 if not provided.
2025-07-02 12:27:16 +07:00
Akarshan Biswas
5d61062b0e
feat: enhance argument parsing and add API key generation
The changes improve the robustness of command-line argument parsing in the Llama model server by replacing direct index access with safe iteration methods. A new generate_api_key function was added to handle API key generation securely. The sessionId parameter was standardized to match the renamed property in the client code.
2025-07-02 12:27:15 +07:00
Thien Tran
6679debf72
mkdir before write yaml 2025-07-02 12:27:15 +07:00
Thien Tran
1ae7c0b59a
update version/backend format. fix bugs around load() 2025-07-02 12:27:15 +07:00
Akarshan Biswas
fd9e034461
feat: update AIEngine load method and backend path handling
- Changed load method to accept modelId instead of loadOptions for better clarity and simplicity
- Renamed engineBasePath parameter to backendPath for consistency with the backend's directory structure
- Added getRandomPort method to ensure unique ports for each session to prevent conflicts
- Refactored configuration and model loading logic to improve maintainability and reduce redundancy
2025-07-02 12:27:15 +07:00
Thien Tran
9e24e28341
add await to config 2025-07-02 12:27:15 +07:00
Thien Tran
070d8534c4
add some string validation 2025-07-02 12:27:14 +07:00
Thien Tran
494a47aaa5
fix download condition 2025-07-02 12:27:14 +07:00
Thien Tran
f32ae402d5
fix CUDA version URL 2025-07-02 12:27:14 +07:00
Thien Tran
27146eb5cc
fix feature parsing 2025-07-02 12:27:14 +07:00
Thien Tran
a75d13f42f
fix version compare 2025-07-02 12:27:14 +07:00
Thien Tran
3490299f66
refactor get supported features. check driver version for cu11 and cu12 2025-07-02 12:27:13 +07:00
Akarshan Biswas
267bbbf77b
feat: add model and mmproj paths to ImportOptions
The `ImportOptions` interface was updated to include `modelPath` and `mmprojPath`. These options are required for importing models and multi-modal projects.
2025-07-02 12:27:13 +07:00
Akarshan Biswas
07d76dc871
feat: Allow specifying mmproj path during model loading
The `loadOptions` interface in `AIEngine.ts` now includes an optional `mmprojPath` property.  This allows users to provide a path to their MMProject file when loading a model, which is required for certain model types.  The `llamacpp-extension/src/index.ts` has been updated to pass this option to the llamacpp server if provided.
2025-07-02 12:27:13 +07:00
Thien Tran
fbfaaf43c5
download CUDA libs if needed 2025-07-02 12:27:13 +07:00
Thien Tran
40cd7e962a
feat: download backend for llama.cpp extension (#5123)
* wip

* update

* add download logic

* add decompress. support delete file

* download backend upon selecting setting

* add some logging and nootes

* add note on race condition

* remove then catch

* default to none backend. only download if it's not installed

* merge version and backend. fetch version from GH

* restrict scope of output_dir

* add note on unpack
2025-07-02 12:27:13 +07:00
Akarshan Biswas
da23673a44
feat: Add API key generation for Llama.cpp
This commit introduces API key generation for the Llama.cpp extension.  The API key is now generated on the server side using HMAC-SHA256 and a secret key to ensure security and uniqueness.  The frontend now passes the model ID and API secret to the server to generate the key. This addresses the requirement for secure model access and authorization.
2025-07-02 12:27:12 +07:00
Akarshan Biswas
d6edb1e944
If checking for proper ctx_len settings after refactoring 2025-07-02 12:27:12 +07:00
Thien Tran
39bb3f34d6
patch failing calls to cortex 2025-07-02 12:27:12 +07:00
Akarshan Biswas
31971e7821
(WIP)randomly generate api-key hash each session 2025-07-02 12:27:12 +07:00
Akarshan Biswas
1dd762f0cf
remove parseGGUFFileName function as it is not used 2025-07-02 12:27:12 +07:00
Akarshan Biswas
7481fae0df
remove ununsed imports and remove n_ctx key from loadOptions 2025-07-02 12:27:11 +07:00
Akarshan Biswas
77d861f56f
Fixup: change key to ctx_size to align with upstream and remove duplicate key 2025-07-02 12:27:11 +07:00
Thien Tran
d5c07acdb5
feat: add LlamacppConfig for llama.cpp extension to improve settings (#5121)
* add engine settings

* update load options

* rename variable
2025-07-02 12:27:11 +07:00
Thien Tran
9bb4deeb78
update model config (import and list) 2025-07-02 12:27:11 +07:00
Thien Tran
5803fcdb99
add read_yaml. use buffered reader/writer 2025-07-02 12:27:11 +07:00
Thien Tran
d01cbe44ae
use PathBuf to check exists() 2025-07-02 12:27:11 +07:00
Thien Tran
77f6770333
update fileStat() 2025-07-02 12:27:10 +07:00
Akarshan Biswas
742e731e96
Add --reasoning_budget option 2025-07-02 12:27:10 +07:00
Akarshan Biswas
fe457a5368
slight modelbasepath refactoring 2025-07-02 12:27:10 +07:00
Akarshan Biswas
c5a0ee7f6e
refactor unload and implement a destructor to clean up sessions 2025-07-02 12:27:10 +07:00
Thien Tran
cd36b423b6
add basic model list 2025-07-02 12:27:10 +07:00
Thien Tran
d523166b61
implement delete 2025-07-02 12:27:09 +07:00
Akarshan Biswas
587ed3c83c
refactor OAI request payload type to support image and audio 2025-07-02 12:27:09 +07:00
Thien Tran
ded9ae733a
feat: Model import (download + local import) for llama.cpp extension (#5087)
* add pull and abortPull

* add model import (download only)

* write model.yaml. support local model import

* remove cortex-related command

* add TODO

* remove cortex-related command
2025-07-02 12:27:09 +07:00
Akarshan Biswas
a7a2dcc8d8
refactor load/unload again; move types to core and refactor AIEngine abstract class 2025-07-02 12:27:09 +07:00
Akarshan Biswas
ee2cb9e625
remove override from localOAIEngine and OAIEngine 2025-07-02 12:27:09 +07:00
Akarshan Biswas
0e9a8a27e5
fixup from refactoring 2025-07-02 12:27:08 +07:00
Akarshan Biswas
bbbf4779df
refactor load/unload 2025-07-02 12:27:08 +07:00
Akarshan Biswas
b4670b5526
remove cortex engine dirs 2025-07-02 12:27:08 +07:00
Akarshan Biswas
47881db696
remove cortex from tauri.conf.json 2025-07-02 12:27:08 +07:00
Akarshan Biswas
021f8ae80f
Fixup: llama-server load 2025-07-02 12:27:08 +07:00
Akarshan Biswas
ed6f86d4b1
Change scripts to download only llama.cpp engine 2025-07-02 12:27:07 +07:00
Akarshan Biswas
a8abc9f9aa
Resolved conflicts by keeping HEAD changes 2025-07-02 12:27:07 +07:00
Akarshan Biswas
19274f7e69
update settings 2025-07-02 12:26:39 +07:00
Thien Tran
3f082372fd
add llamacpp-extension. can list some models 2025-07-02 12:26:39 +07:00
Thien Tran
15f0b11c0d
make it compile 2025-07-02 12:26:38 +07:00
Akarshan Biswas
0551b0bfd2
Fix import 2025-07-02 12:26:38 +07:00
Akarshan Biswas
f5b5596306
add thiserror to Cargo.toml 2025-07-02 12:26:38 +07:00
Akarshan Biswas
5c9e8dce76
Add spaces before EOF 2025-07-02 12:26:38 +07:00
Akarshan Biswas
9016fbff68
feat: inference-llamacpp-extension: backend implementation 2025-07-02 12:26:37 +07:00
Louis
c288e75407
Merge pull request #5671 from menloresearch/dev
Sync dev into Release/v0.7.0
2025-07-02 11:33:01 +07:00
Louis
a3fd6fcd3c
Merge pull request #5670 from menloresearch/release/v0.6.6
Sync Release/v0.6.6 into dev
2025-07-02 10:58:33 +07:00
Louis
dc4e592de9
Merge branch 'dev' into release/v0.6.6 2025-07-02 10:43:12 +07:00
Louis
ccffe4ced5
Merge pull request #5669 from menloresearch/release/v0.6.4
Sync Release/v0.6.4 into dev
2025-07-02 10:42:07 +07:00
Faisal Amir
2a0597ff01
Merge branch 'dev' into release/v0.6.6 2025-07-02 10:26:32 +07:00
Bob Ros
f072aded62
Merge branch 'menloresearch:dev' into de_de-i18n 2025-07-01 20:46:46 +02:00
Bui Quang Huy
defc6b92d2
Merge pull request #5661 from menloresearch/template/yml-to-md
🔧 config: all yml to md for issue template
2025-07-01 23:47:33 +08:00
LazyYuuki
a8a1de9ad0 🔧 config: all yml to md for issue template 2025-07-01 23:45:44 +08:00
Bui Quang Huy
5690c43633
Merge pull request #5658 from menloresearch/template/fix-bug-md
🔧 config: fix bug template
2025-07-01 23:36:13 +08:00
LazyYuuki
5dc9073108 🔧 config: fix bug template 2025-07-01 23:33:30 +08:00
Bui Quang Huy
99df080bd6
Merge pull request #5657 from menloresearch/template/yml-to-md
🔧 config: from yml to md for template
2025-07-01 23:26:21 +08:00
LazyYuuki
8e837fc73d 🔧 config: from yml to md for template 2025-07-01 23:25:08 +08:00
Louis
71cf69bb16
Merge pull request #5606 from menloresearch/dependabot/npm_and_yarn/multi-f00634d4ce
chore(deps-dev): bump jest and @types/jest
2025-07-01 20:02:59 +07:00
Louis
94b25ec6e8
Merge pull request #5650 from menloresearch/fix/top_k-model-setting-validation
fix: top_k validation
2025-07-01 17:31:03 +07:00
Louis
0b88d93e18
fix: top_k validation 2025-07-01 16:40:22 +07:00
Bui Quang Huy
7dd95101c2
Merge pull request #5647 from menloresearch/template/update-config
Update config.yml
2025-07-01 15:04:51 +08:00
Bui Quang Huy
f1e28c2ab5
Update config.yml 2025-07-01 15:03:12 +08:00
Louis
9e9bc49729
Merge pull request #5644 from menloresearch/fix/some-of-model-settings-are-not-applied
fix: some of the model settings are not applied
2025-07-01 13:43:02 +07:00
Louis
db74f2cf3f
fix: check newValue not null 2025-07-01 13:28:30 +07:00
Louis
7b22ba8c54
fix: some of the model settings are not applied 2025-07-01 13:17:32 +07:00
Louis
1e8c9956cd
Merge pull request #5568 from menloresearch/fix/min_p-validation-on-model-load
fix: min p validation on model load
2025-07-01 11:15:35 +07:00
Daniel Ching
e274d04d9b
Merge pull request #5597 from menloresearch/docs/update-explanation
docs: update explanation and model parameter sections
2025-07-01 11:58:45 +08:00
Daniel Ching
439cc55147
Merge branch 'dev' into docs/update-explanation 2025-07-01 11:55:24 +08:00
Daniel Ching
9ba1995030 Updated Jan description 2025-07-01 11:52:19 +08:00
Faisal Amir
662879bb5d
enhancement: setting responsive (#5615)
* feat: setting responsive

* 🧹cleanup: feeback PR

* 🧹cleanup: unused className

* 🧹cleanup: unused props
2025-07-01 09:44:32 +07:00
Bui Quang Huy
ac6d683733
Merge pull request #5636 from menloresearch/template/config-template
🔧 config: github template
2025-07-01 10:20:09 +08:00
LazyYuuki
2a143e71e4 🔧 config: github template 2025-07-01 10:15:50 +08:00
Nguyen Ngoc Minh
34014451ce
chore: add build script for appimage package (#5635) 2025-07-01 09:14:50 +07:00
Bui Quang Huy
aa353fbbaa
Merge pull request #5634 from menloresearch/template/create-epic
Create epic.yml
2025-07-01 10:01:36 +08:00
Bui Quang Huy
f62290cb00
Update .github/ISSUE_TEMPLATE/epic.yml
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-07-01 10:01:27 +08:00
Bui Quang Huy
041fc2b330
Update .github/ISSUE_TEMPLATE/epic.yml
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-07-01 10:01:11 +08:00
Bui Quang Huy
0e2a00e006
Create epic.yml 2025-07-01 09:58:36 +08:00
dependabot[bot]
c3b6a08ff3
chore(deps-dev): bump jest and @types/jest
---
updated-dependencies:
- dependency-name: jest
  dependency-version: 30.0.3
  dependency-type: direct:development
  update-type: version-update:semver-major
- dependency-name: "@types/jest"
  dependency-version: 30.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-30 18:12:27 +00:00
Louis
50f387733a
Merge pull request #5613 from menloresearch/dependabot/npm_and_yarn/core/rimraf-6.0.1
chore(deps-dev): bump rimraf from 3.0.2 to 6.0.1 in /core
2025-07-01 01:10:00 +07:00
Louis
5caf9cc690
Merge pull request #5607 from menloresearch/dependabot/npm_and_yarn/extensions/download-extension/rimraf-6.0.1
chore(deps-dev): bump rimraf from 3.0.2 to 6.0.1 in /extensions/download-extension
2025-07-01 01:09:45 +07:00
Louis
9917716cc9
Merge pull request #5608 from menloresearch/dependabot/npm_and_yarn/extensions/conversational-extension/rimraf-6.0.1
chore(deps-dev): bump rimraf from 3.0.2 to 6.0.1 in /extensions/conversational-extension
2025-07-01 01:09:28 +07:00
Louis
48f51b5ec7
Merge pull request #5609 from menloresearch/dependabot/npm_and_yarn/extensions/assistant-extension/rimraf-6.0.1
chore(deps-dev): bump rimraf from 3.0.2 to 6.0.1 in /extensions/assistant-extension
2025-07-01 01:09:11 +07:00
Bui Quang Huy
fa41ae11a4
Merge pull request #5630 from menloresearch/template/fix-config
Update config.yml
2025-07-01 01:32:16 +08:00
Bui Quang Huy
f24346b4fa
Update config.yml 2025-07-01 01:30:53 +08:00
Bui Quang Huy
0735d3bc80
Merge pull request #5628 from menloresearch/template/disable-blank
Update config.yml
2025-07-01 01:21:10 +08:00
Bui Quang Huy
fd893c3af6
Merge pull request #5627 from menloresearch/template/delete-model-request
Delete .github/ISSUE_TEMPLATE/model_request.yml
2025-07-01 01:19:59 +08:00
Bui Quang Huy
18f0228794
Merge pull request #5626 from menloresearch/template/update-feature-request
Update feature_request.yml
2025-07-01 01:19:45 +08:00
Bui Quang Huy
62d078355a
Merge pull request #5625 from menloresearch/template/update-bug-report
Update bug_report.yml
2025-07-01 01:19:02 +08:00
Bui Quang Huy
73ff61620e
Update config.yml
Disable blank issues
2025-07-01 01:18:35 +08:00
Bui Quang Huy
5c988d8890
Delete .github/ISSUE_TEMPLATE/model_request.yml 2025-07-01 01:17:25 +08:00
Bui Quang Huy
f4b6a2054e
Update feature_request.yml 2025-07-01 01:14:03 +08:00
Bui Quang Huy
03f30b8a1d
Update bug_report.yml 2025-07-01 01:12:25 +08:00
Bui Quang Huy
fcf38aae35
Merge pull request #5624 from menloresearch/template/goal-project-to-number
Update goal.yml
2025-07-01 01:07:52 +08:00
Bui Quang Huy
0d20f2e0b8
Update goal.yml 2025-07-01 01:06:04 +08:00
Bui Quang Huy
841c2301d6
Merge pull request #5623 from menloresearch/template/goal-projects
Update goal.yml
2025-07-01 01:04:38 +08:00
Bui Quang Huy
9fe34ca226
Update goal.yml 2025-07-01 01:02:32 +08:00
Bui Quang Huy
bbd7f024aa
Merge pull request #5622 from menloresearch/template/goal-projects
Update goal.yml
2025-07-01 00:58:27 +08:00
Bui Quang Huy
bfa5410a52
Update goal.yml 2025-07-01 00:57:07 +08:00
Bui Quang Huy
f0adeaec7d
Merge pull request #5621 from menloresearch/template/update-goal-template
Update goal.yml
2025-07-01 00:55:38 +08:00
Bui Quang Huy
0e41502bcc
Update goal.yml 2025-07-01 00:53:22 +08:00
Bui Quang Huy
d6bf62743d
Merge pull request #5620 from menloresearch/template/fix-goal-template-1
Fix goal.yml
2025-07-01 00:46:04 +08:00
Bui Quang Huy
8a309cf3d9
Fix goal.yml 2025-07-01 00:40:13 +08:00
Bui Quang Huy
a41b7114ca
Merge pull request #5619 from menloresearch/template/goal-yml
fix previous problem with goal.yml template
2025-07-01 00:38:20 +08:00
Bui Quang Huy
05a74481fa
Update goal.yml 2025-07-01 00:36:25 +08:00
Bui Quang Huy
d34ccadd2c
Merge pull request #5618 from menloresearch/template/update-goal-template
Update and rename goal.md to goal.yml
2025-07-01 00:31:15 +08:00
Bui Quang Huy
69438035eb
Update and rename goal.md to goal.yml 2025-07-01 00:29:19 +08:00
Bui Quang Huy
5086b45ce9
Merge pull request #5617 from menloresearch/template/update-goal-template
Update goal.md
2025-07-01 00:20:28 +08:00
Bui Quang Huy
c251b04d15
Update goal.md 2025-07-01 00:14:00 +08:00
Daniel Ching
229bed9955 Updated continue-dev documentation 2025-06-30 17:22:59 +08:00
dependabot[bot]
aa59a70b88
chore(deps-dev): bump rimraf from 3.0.2 to 6.0.1 in /core
---
updated-dependencies:
- dependency-name: rimraf
  dependency-version: 6.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-30 09:02:19 +00:00
dependabot[bot]
c358831808
chore(deps-dev): bump rimraf in /extensions/assistant-extension
---
updated-dependencies:
- dependency-name: rimraf
  dependency-version: 6.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-30 08:51:12 +00:00
dependabot[bot]
1c9a64855e
chore(deps-dev): bump rimraf in /extensions/conversational-extension
---
updated-dependencies:
- dependency-name: rimraf
  dependency-version: 6.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-30 08:49:18 +00:00
dependabot[bot]
3e22835049
chore(deps-dev): bump rimraf in /extensions/download-extension
---
updated-dependencies:
- dependency-name: rimraf
  dependency-version: 6.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-30 08:44:31 +00:00
Daniel Ching
d05e5a5dae Removed settings/ folder and GPU settings (settings.json) 2025-06-30 12:17:17 +08:00
Daniel Ching
1444374fea Removed Max Tokens and Stop Sequences from docs as they are no longer present in model settings 2025-06-30 12:15:20 +08:00
Sam Hoang Van
5918c9cd6f
fix: custom based url and header by upgrade token.js version (#5596) 2025-06-30 10:56:23 +07:00
Bob Ros
39f220fae1
Merge branch 'dev' into de_de-i18n 2025-06-29 18:33:45 +02:00
hiento09
35154887e3
chore: deprecate ci environment (#5592) 2025-06-29 22:34:36 +07:00
Louis
e52b6553a5
Merge branch 'dev' into allow-assistant-message-edits 2025-06-29 17:43:38 +07:00
Louis
cc2e6c7edc
Merge pull request #5519 from menloresearch/freelerobot-patch-1
chore: update issue templates for goals
2025-06-29 17:37:06 +07:00
Louis
834bc39242
test: init e2e test with selenium and CI work (#5591)
* test: init e2e test

* Update yarn.lock
2025-06-29 17:12:16 +07:00
Sherzod Mutalov
1e51f1699a
Merge branch 'dev' into feat/old-mac-support 2025-06-28 15:32:25 +05:00
Bob Ros
3f696b4d12
Merge branch 'dev' into de_de-i18n 2025-06-28 11:38:59 +02:00
Nguyen Ngoc Minh
a7453d16ef
ci: add issues to project board (#5583) 2025-06-28 15:50:48 +07:00
Bob Ros
3b7ed88180
Update web-app/src/locales/de-DE/common.json
change to informal

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:11:21 +02:00
Bob Ros
2fdfba208a
Update web-app/src/locales/de-DE/mcp-servers.json
use modern style for ß

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:09:51 +02:00
Bob Ros
224aa1b4e6
Update web-app/src/locales/de-DE/mcp-servers.json
fix typo

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:09:21 +02:00
Bob Ros
8a77c41519
Update web-app/src/locales/de-DE/mcp-servers.json
use modern style of ß

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:08:28 +02:00
Bob Ros
9c3b93a8c7
Update web-app/src/locales/de-DE/common.json
fix forgotten translation

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:07:21 +02:00
Bob Ros
0114d89993
Update web-app/src/locales/de-DE/common.json
fix forgotten translation

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:06:53 +02:00
Bob Ros
3329be5c73
Update web-app/src/locales/de-DE/common.json
fix forgotten translation deleteAll

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:06:24 +02:00
Bob Ros
e6f77faf06
Update web-app/src/locales/de-DE/providers.json
remove useless white space

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:05:46 +02:00
Bob Ros
f962c45d8e
Update web-app/src/locales/de-DE/model-errors.json
change 'ß' to modern German orthography

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:04:41 +02:00
Bob Ros
c187af27e7
Update web-app/src/locales/de-DE/setup.json
change 'ß' to modern German orthography

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:04:06 +02:00
Bob Ros
e5b392af09
Update web-app/src/locales/de-DE/tool-approval.json
fix typo securityNotice

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:02:42 +02:00
Bob Ros
4f940055be
Update web-app/src/locales/de-DE/settings.json
fix typo in serverHostDesc

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:02:00 +02:00
Bob Ros
50f7de0f2d
Update web-app/src/locales/de-DE/providers.json
fix incosistence insertApiKeyTitle

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:01:39 +02:00
Bob Ros
5fbde39c75
Update web-app/src/locales/de-DE/common.json
fix forgotten translation pickColorWindowBackground

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 03:00:00 +02:00
Bob Ros
342509d136
Update web-app/src/locales/de-DE/model-errors.json
fix typo increaseContextSizeDescription

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 02:59:00 +02:00
Bob Ros
c6ce78912c
Update web-app/src/locales/de-DE/hub.json
fix typo editTheme

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 02:58:04 +02:00
Bob Ros
90041552b9
Update web-app/src/locales/de-DE/common.json
fix typo in enterNameForProvider

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 02:57:36 +02:00
Bob Ros
6ec0849a1b
Update web-app/src/locales/de-DE/assistants.json
fix empty field value

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-28 02:56:25 +02:00
Bob Ros
bd11ce2579 add locale de-DE Germany 2025-06-28 02:10:37 +02:00
ethanova
fd43b608e9
Merge branch 'dev' into allow-assistant-message-edits 2025-06-27 19:48:33 -04:00
Louis
6be9cb974c
Merge pull request #5395 from menloresearch/dependabot/npm_and_yarn/typescript-5.8.3
chore(deps-dev): bump typescript from 5.7.3 to 5.8.3
2025-06-27 23:35:00 +07:00
Louis
ea8d15e36b
Merge pull request #5439 from menloresearch/dependabot/npm_and_yarn/web-app/lucide-react-0.522.0
chore(deps): bump lucide-react from 0.503.0 to 0.522.0 in /web-app
2025-06-27 23:33:39 +07:00
Louis
54ac47d9af
Merge pull request #5440 from menloresearch/dependabot/npm_and_yarn/docs/lucide-react-0.522.0
chore(deps): bump lucide-react from 0.372.0 to 0.522.0 in /docs
2025-06-27 23:33:04 +07:00
Nguyen Ngoc Minh
472ef88bdc
chore: flexible installation path windows installer (#5573) 2025-06-27 23:21:28 +07:00
DistractionRectangle
50f3563a96
🐛fix: Tauri AppImage failing to render on wayland + mesa (#5463) 2025-06-27 23:16:25 +07:00
Daniel Ching
5fa9b9b66d update jan data-folder 2025-06-27 16:43:21 +08:00
Sherzod Mutalov
86e601dbe4
Merge branch 'dev' into feat/old-mac-support 2025-06-27 13:24:09 +05:00
Daniel Ching
2de4990543 Cleaned up outdated references in explanation section in jan docs 2025-06-27 16:05:36 +08:00
Sam Hoang Van
242fbcd43e
chore: update mise.toml configuration (#5556) 2025-06-27 13:27:25 +07:00
Nguyen Ngoc Minh
239f93e48d
🧹 chore: update issue template (#5572)
* chore: update label feature request

* chore: remove labels type bug
2025-06-27 13:09:19 +07:00
Louis
be465ec297
Merge pull request #5569 from menloresearch/dev
sync: commits from dev into release/v0.7.0
2025-06-27 12:41:04 +07:00
DistractionRectangle
ae25dbbbc4
chore: update .devcontainer to provide a reproducible build environment (#5558) 2025-06-27 12:18:16 +07:00
Louis
a324f4b84d
Merge pull request #5568 from menloresearch/fix/min_p-validation-on-model-load
fix: min p validation on model load
2025-06-27 11:39:59 +07:00
Louis
b49619b389
test: cover new changes 2025-06-27 10:41:34 +07:00
Louis
ba4a36dfb3
fix: min-p-validation-on-model-load 2025-06-27 10:34:43 +07:00
Sherzod Mutalov
e4116f6bb4
Merge branch 'dev' into feat/old-mac-support 2025-06-26 23:52:46 +05:00
Faisal Amir
6380ad0657
🐛fix: translation fallback (#5554)
* 🐛fix: translation fallback

* 🧹cleanup: remove duplicate key translation
2025-06-26 23:59:53 +07:00
Ethan Garber
c07f5dba03 Merge branch 'dev' into allow-assistant-message-edits 2025-06-26 12:41:26 -04:00
Louis
7223f6fc3f
Merge pull request #5552 from menloresearch/dev
sync: apply latest changes into release/v0.6.4
2025-06-26 09:02:27 -07:00
Louis
094d4a8879
Merge pull request #5550 from menloresearch/release/v0.6.3
sync: release/v0.6.3 into dev
2025-06-26 08:21:03 -07:00
Louis
74fafac5fa
fix: i18n after synced 2025-06-26 22:17:47 +07:00
Louis
e1b6690763
Merge branch 'dev' into release/v0.6.3
# Conflicts:
#	web-app/src/containers/DropdownModelProvider.tsx
#	web-app/src/containers/SettingsMenu.tsx
#	web-app/src/containers/dialogs/DeleteModel.tsx
#	web-app/src/routes/__root.tsx
#	web-app/src/routes/settings/general.tsx
#	web-app/src/routes/threads/$threadId.tsx
2025-06-26 21:55:35 +07:00
David
ab0a21ab0d
Merge pull request #5548 from menloresearch/ramon/docs-fix-v0.6.4
Fixed video demo on jan-nano-128, added the 0.6.3 changelog, and update tutorial image.
2025-06-26 14:51:35 +00:00
Ramon Perez
ffc7289e90 changed gif to changelog page 2025-06-27 00:44:12 +10:00
Ramon Perez
79a394effe Fixed video demo on jan-nano-128, added the changelog, and elarged an image in jan-nano-32 2025-06-26 23:26:42 +10:00
Louis
4229b9f873
Merge pull request #5547 from menloresearch/fix/undefined-setting-should-also-disable-context-shift
fix: handle context shift setting from old app versions
2025-06-26 05:37:31 -07:00
Louis
c5aac9270c
Update extensions/inference-cortex-extension/src/index.ts
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-26 19:36:07 +07:00
Louis
d75db73a43
fix: handle context shift setting from old app versions 2025-06-26 19:32:34 +07:00
Faisal Amir
2ae51bcf4e
🐛fix: modal action light mode (#5545) 2025-06-26 18:45:14 +07:00
Louis
0af271b05f
Merge pull request #5542 from menloresearch/fix/increase-context-window-could-not-popup 2025-06-26 03:22:22 -07:00
Louis
16aab0d661
fix: increase context size window does not popup first time 2025-06-26 16:40:55 +07:00
Sherzod Mutalov
0e28916f8a chore: extracted macos avx2 check code to the utility function 2025-06-26 14:16:10 +05:00
Faisal Amir
9bbf9a590c
enhancement: support base layout responsive UI (#5472)
* enhancement: support base layout responsive UI

* Update web-app/src/containers/LeftPanel.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Update web-app/src/containers/ThreadList.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* enhancement: responsive assistant screen (#5502)

* enhancement: support base layout responsive UI

* Update web-app/src/containers/LeftPanel.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Update web-app/src/containers/ThreadList.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* enhancement: responsive assistant screen

* Update web-app/src/containers/dialogs/AddEditAssistant.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* enhancement: sort assistant

* Update web-app/src/routes/assistant.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* enhancement: responsive hub screen (#5507)

* enhancement: support base layout responsive UI

* Update web-app/src/containers/LeftPanel.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Update web-app/src/containers/ThreadList.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* enhancement: responsive assistant screen

* Update web-app/src/containers/dialogs/AddEditAssistant.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* enhancement: sort assistant

* Update web-app/src/routes/assistant.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* enhancement: responsive hub screen

* 🧹cleanup: multiple key and useless for hub translation

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-26 15:01:50 +07:00
Faisal Amir
f46d45e786
🐛fix: disabled backdrop onboarding on linux (#5533) 2025-06-26 15:01:44 +07:00
Sherzod Mutalov
d229cbd098
Merge branch 'menloresearch:dev' into feat/old-mac-support 2025-06-26 10:42:22 +05:00
Ramon Perez
a670c49d14
Merge pull request #5535 from menloresearch/ramon/docs-v0.6.0
Rearranged docs, improved writing, and added Jan Nano 128k
2025-06-26 15:41:15 +10:00
Ramon Perez
45f6cd9368 small fixed on nano 32 2025-06-26 15:37:29 +10:00
Ramon Perez
52d7a928cc fixed typo and removed unused import 2025-06-26 15:35:39 +10:00
Ramon Perez
69b55db4a7 added mermaid diagram 2025-06-26 14:52:54 +10:00
Ramon Perez
ade7c6cb6c rearranged docs, added Jan Nano and minor improvements 2025-06-26 14:50:21 +10:00
Louis
906c539541
Merge pull request #5531 from menloresearch/config/remove-mcp-production-gate
config: remove MCP and tool use production gate
2025-06-25 20:07:15 -07:00
Louis
63761efca2
config: remove MCP and tool use production gate 2025-06-26 10:01:42 +07:00
ethanova
e8728dfa77
Merge branch 'dev' into allow-assistant-message-edits 2025-06-25 20:28:17 -04:00
Ethan Garber
9018f6deae provide a way to generate an assistant message if deleted or errored 2025-06-25 20:27:23 -04:00
Sherzod Mutalov
fd5ca5a215 chore: added comments 2025-06-26 01:16:55 +05:00
Sherzod Mutalov
6c08558512 chore: replaced with macros call to remove warning 2025-06-26 01:01:12 +05:00
Sherzod Mutalov
685ae14467 fix: use system npx on old mac's 2025-06-25 23:13:59 +05:00
Louis
ea662c4876
Merge pull request #5528 from menloresearch/fix/default-model-settings-jan-nano
🐛fix: default model settings for jan-nano-128k
2025-06-25 06:07:31 -07:00
Louis
d407ebc4e9
fix: typo 2025-06-25 19:42:22 +07:00
Louis
a7c441ee58
🐛fix: default model settings for jan-nano-128k 2025-06-25 19:36:34 +07:00
Faisal Amir
3eb31be62e
enhancement: adjust placement exp toggle (#5525)
* enhancement: adjust placement exp toggle

* Update web-app/src/routes/settings/general.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-25 17:10:02 +07:00
Louis
54a9d140b5
Merge pull request #5524 from menloresearch/enhancement/jan-nano-128k
enhancement: Added jan-nano-128k
2025-06-25 16:31:58 +07:00
Faisal Amir
f5cfe8a537 enhancement: Added jan-nano-128k 2025-06-25 15:56:38 +07:00
Sam Hoang Van
0890de1869
feat: improve local provider connectivity with CORS bypass (#5458)
* feat: improve local provider connectivity with CORS bypass

- Add @tauri-apps/plugin-http dependency
- Implement dual fetch strategy for local vs remote providers
- Auto-detect local providers (localhost, Ollama:11434, LM Studio:1234)
- Make API key optional for local providers
- Add comprehensive test coverage for provider fetching

refactor: simplify fetchModelsFromProvider by removing preflight check logic

* feat: extend config options to include custom fetch function for CORS handling

* feat: conditionally use Tauri's fetch for openai-compatible providers to handle CORS
2025-06-25 15:42:14 +07:00
Faisal Amir
52d15802d9
enhancement: experimental feature toggle (#5514) 2025-06-25 14:10:54 +07:00
Faisal Amir
c463090edb
🐛fix: delete pre populate remote models (#5516) 2025-06-25 13:49:55 +07:00
Nicole Zhu
942a3d6195
chore: update issue templates for goals 2025-06-25 14:42:49 +08:00
Daniel Ching
c74e5280e7
Merge pull request #5513 from menloresearch/docs/update-images-and-links
Update outdated images and links
2025-06-25 14:19:05 +08:00
Louis
6e3852554a
sync: cherry pick v0.6.2 release (#5515)
* Feat: auto restart mcp (#5226)

* feat: implement retry mechanism for MCP server activation with exponential backoff

feat: enhance MCP server activation with configurable retry attempts

feat: implement MCP server restart monitoring and cleanup functionality

feat: enhance MCP server restart logic with improved monitoring and configuration handling

feat: add manual deactivation for MCP servers to prevent automatic restarts

* feat: enhance MCP server startup with initial attempt tracking and health monitoring

* 🐛fix: prevent render error when additional information missing from hardware (#5413)

---------

Co-authored-by: Sam Hoang Van <samhv.ict@gmail.com>
Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-06-25 13:15:10 +07:00
Daniel Ching
4f237b88ac
Update docs/src/pages/docs/index.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-25 13:32:48 +08:00
Daniel Ching
3a1cb87a47
Merge branch 'dev' into docs/update-images-and-links 2025-06-25 13:31:54 +08:00
Faisal Amir
8fdb65eba5
🐛fix: prevent render error when additional information missing from hardware (#5413) 2025-06-25 11:41:28 +07:00
Sam Hoang Van
329fb7d023
Feat: auto restart mcp (#5226)
* feat: implement retry mechanism for MCP server activation with exponential backoff

feat: enhance MCP server activation with configurable retry attempts

feat: implement MCP server restart monitoring and cleanup functionality

feat: enhance MCP server restart logic with improved monitoring and configuration handling

feat: add manual deactivation for MCP servers to prevent automatic restarts

* feat: enhance MCP server startup with initial attempt tracking and health monitoring
2025-06-25 11:40:28 +07:00
dependabot[bot]
5373b9336c chore(deps): bump lucide-react from 0.372.0 to 0.522.0 in /docs
Bumps [lucide-react](https://github.com/lucide-icons/lucide/tree/HEAD/packages/lucide-react) from 0.372.0 to 0.522.0.
- [Release notes](https://github.com/lucide-icons/lucide/releases)
- [Commits](https://github.com/lucide-icons/lucide/commits/0.522.0/packages/lucide-react)

---
updated-dependencies:
- dependency-name: lucide-react
  dependency-version: 0.522.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-24 18:54:55 +07:00
dependabot[bot]
828261ea9c
chore(deps): bump @tanstack/react-router-devtools (#5441)
---
updated-dependencies:
- dependency-name: "@tanstack/react-router-devtools"
  dependency-version: 1.121.34
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-24 15:25:48 +07:00
dependabot[bot]
5185d19129
chore(deps-dev): bump typescript from 5.7.3 to 5.8.3
Bumps [typescript](https://github.com/microsoft/TypeScript) from 5.7.3 to 5.8.3.
- [Release notes](https://github.com/microsoft/TypeScript/releases)
- [Changelog](https://github.com/microsoft/TypeScript/blob/main/azure-pipelines.release-publish.yml)
- [Commits](https://github.com/microsoft/TypeScript/compare/v5.7.3...v5.8.3)

---
updated-dependencies:
- dependency-name: typescript
  dependency-version: 5.8.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-24 07:56:32 +00:00
dependabot[bot]
51b6c0a7de
chore(deps-dev): bump typescript in /extensions/download-extension (#5405)
Bumps [typescript](https://github.com/microsoft/TypeScript) from 5.3.3 to 5.8.3.
- [Release notes](https://github.com/microsoft/TypeScript/releases)
- [Changelog](https://github.com/microsoft/TypeScript/blob/main/azure-pipelines.release-publish.yml)
- [Commits](https://github.com/microsoft/TypeScript/compare/v5.3.3...v5.8.3)

---
updated-dependencies:
- dependency-name: typescript
  dependency-version: 5.8.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-24 14:54:11 +07:00
Louis
e389011b48
🐛 fix: add back a couple of major fixes (#5469) (#5470) 2025-06-24 14:50:40 +07:00
Louis
1dc9e47524
🐛 fix: add back a couple of major fixes (#5469) 2025-06-24 14:43:31 +07:00
Daniel Ching
9ec159ddf8 Updated screenshots to revised frontend 2025-06-24 14:19:39 +08:00
Daniel Ching
0c4eb4eacf Updated link in index.mdx 2025-06-24 13:24:02 +08:00
Daniel Ching
b554fddb01 Updated index.mdx to remove broken links and changed landing page image 2025-06-24 13:22:03 +08:00
dependabot[bot]
43a4a98f6f
chore(deps): bump lucide-react from 0.503.0 to 0.522.0 in /web-app
Bumps [lucide-react](https://github.com/lucide-icons/lucide/tree/HEAD/packages/lucide-react) from 0.503.0 to 0.522.0.
- [Release notes](https://github.com/lucide-icons/lucide/releases)
- [Commits](https://github.com/lucide-icons/lucide/commits/0.522.0/packages/lucide-react)

---
updated-dependencies:
- dependency-name: lucide-react
  dependency-version: 0.522.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-23 08:15:44 +00:00
Sam Hoang Van
64a7822cc8
Feat: auto restart mcp (#5226)
* feat: implement retry mechanism for MCP server activation with exponential backoff

feat: enhance MCP server activation with configurable retry attempts

feat: implement MCP server restart monitoring and cleanup functionality

feat: enhance MCP server restart logic with improved monitoring and configuration handling

feat: add manual deactivation for MCP servers to prevent automatic restarts

* feat: enhance MCP server startup with initial attempt tracking and health monitoring
2025-06-23 12:20:05 +07:00
ethanova
4e2b28c687
Merge branch 'dev' into allow-assistant-message-edits 2025-06-21 06:39:33 -04:00
Sam Hoang Van
e9b28c5a90
🐛fix: remove unused exports from i18n index and ensure translate function returns correct type (#5419) 2025-06-21 14:42:15 +07:00
Sam Hoang Van
565c7412c2
Improve dev experience by using mise & sccache (#5265)
* feat: add initial mise.toml configuration with core tasks and development setup

* docs: update Quick Start section to recommend mise for development setup
2025-06-21 12:49:32 +07:00
Louis
2e9aa4ec17
🔧config: update yarn.lock file (#5417) 2025-06-21 12:36:33 +07:00
Zhiqiang ZHOU
aa7775225a
chore: change how headers affect
Signed-off-by: Zhiqiang ZHOU <im@strrl.dev>
2025-06-20 12:39:18 -07:00
Faisal Amir
0518fea2a2
🐛fix: prevent render error when additional information missing from hardware (#5413) 2025-06-21 00:03:04 +07:00
Ethan Garber
1771cec811 Merge branch 'dev' into allow-assistant-message-edits 2025-06-20 07:39:46 -04:00
Ethan Garber
3ed6252ad8 removed electron dir from vscode settings eslint working dirs as it no longer exists 2025-06-20 07:33:57 -04:00
Rene Leonhardt
ec2602307d
Merge pull request #5391 from reneleonhardt/feat/add-dependabot
feat: add dependabot for cargo and npm
2025-06-20 16:50:37 +07:00
Sam Hoang Van
c32dd092d0
Enhance i18n and add missing i18n for all component (#5314)
* Refactor translation imports and update text for localization across settings and system monitor routes

- Changed translation import from 'react-i18next' to '@/i18n/react-i18next-compat' in multiple files.
- Updated various text strings to use translation keys for better localization support in:
  - Local API Server settings
  - MCP Servers settings
  - Privacy settings
  - Provider settings
  - Shortcuts settings
  - System Monitor
  - Thread details
- Ensured consistent use of translation keys for all user-facing text.

Update web-app/src/routes/settings/appearance.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

Update web-app/src/routes/settings/appearance.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

Update web-app/src/locales/vn/settings.json

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

Update web-app/src/containers/dialogs/DeleteMCPServerConfirm.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

Update web-app/src/locales/id/common.json

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Add Chinese (Simplified and Traditional) localization files for various components

- Created `tools.json`, `updater.json`, `assistants.json`, `chat.json`, `common.json`, `hub.json`, `logs.json`, `mcp-servers.json`, `provider.json`, `providers.json`, `settings.json`, `setup.json`, `system-monitor.json`, `tool-approval.json` in both `zh-CN` and `zh-TW` locales.
- Added translations for tool approval, updater notifications, assistant management, chat interface, common UI elements, hub interactions, logging messages, MCP server configurations, provider management, settings options, setup instructions, and system monitoring.

* Refactor localization strings for improved clarity and consistency in English, Indonesian, and Vietnamese settings files

* Fix missing key and reword

* fix pr comment

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-20 15:33:54 +07:00
Zhiqiang ZHOU
7a8a38ac6f
feat: identidy jan for openrouter
Signed-off-by: Zhiqiang ZHOU <im@strrl.dev>
2025-06-19 23:20:31 -07:00
Ramon Perez
ebd9e0863e
Merge pull request #5385 from menloresearch/ramon/docs-jan-models
Added Models section with jan nano to docs, updated api server section and changelog.
2025-06-20 15:11:20 +10:00
Ramon Perez
47145ef4ac changed wording at index 2025-06-20 14:53:27 +10:00
Ramon Perez
efca02904d fixed typos 2025-06-20 14:09:25 +10:00
Ramon Perez
76b2be8ba4 added FAQ section 2025-06-20 14:07:54 +10:00
Ramon Perez
5bcd850add added jan nano to docs, api key example to api server section, and changelog section with 0.6.1 2025-06-20 13:59:50 +10:00
Ethan Garber
75208737ee revert main yarn.lock too 2025-06-20 09:47:07 +07:00
Ethan Garber
a22d08394b revert yarn.lock 2025-06-20 09:47:07 +07:00
Ethan Garber
1d5852fbb5 fix ux concern to manage message state in dialog component 2025-06-20 09:47:07 +07:00
Ethan Garber
00e960b9ef lint 2025-06-20 09:47:07 +07:00
Ethan Garber
7a53228341 allow the user to edit assistant messages like in LM Studio 2025-06-20 09:47:07 +07:00
Louis
a1cef450de
♻️ Sync changes from version 0.6.1 into dev branch (#5384)
* chore: enable shortcut zoom (#5261)

* chore: enable shortcut zoom

* chore: update shortcut setting

* fix: thinking block (#5263)

* Merge pull request #5262 from menloresearch/chore/sync-new-hub-data

chore: sync new hub data

* enhancement: model run improvement (#5268)

* fix: mcp tool error handling

* fix: error message

* fix: trigger download from recommend model

* fix: can't scroll hub

* fix: show progress

* enhancement: prompt users to increase context size

* enhancement: rearrange action buttons for a better UX

* 🔧chore: clean up logics

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>

* fix: glitch download from onboarding (#5269)

* enhancement: Model sources should not be hard coded from frontend (#5270)

* 🐛fix: default onboarding model should use recommended quantizations (#5273)

* 🐛fix: default onboarding model should use recommended quantizations

* enhancement: show context shift option in provider settings

* 🔧chore: wording

* 🔧 config: add to gitignore

* 🐛fix: Jan-nano repo name changed (#5274)

* 🚧 wip: disable showSpeedToken in ChatInput

* 🐛 fix: commented out the wrong import

* fix: masking value MCP env field (#5276)

*  feat: add token speed to each message that persist

* ♻️ refactor: to follow prettier convention

* 🐛 fix: exclude deleted field

* 🧹 clean: all the missed console.log

* enhancement: out of context troubleshooting (#5275)

* enhancement: out of context troubleshooting

* 🔧refactor: clean up

* enhancement: add setting chat width container (#5289)

* enhancement: add setting conversation width

* enahncement: cleanup log and change improve accesibility

* enahcement: move const beta version

* 🐛fix: optional additional_information gpu (#5291)

* 🐛fix: showing release notes for beta and prod (#5292)

* 🐛fix: showing release notes for beta and prod

* ♻️refactor: make an utils env

* ♻️refactor: hide MCP for production

* ♻️refactor: simplify the boolean expression fetch release note

* 🐛fix: typo in build type check (#5297)

* 🐛fix: remove onboarding local model and hide the edit capabilities model (#5301)

* 🐛fix: remove onboarding local model and hide the edit capabilities model

* ♻️refactor: conditional search params setup screen

* 🐛fix: hide token speed when assistant params stream false (#5302)

* 🐛fix: glitch padding speed token (#5307)

* 🐛fix: immediately show download progress (#5308)

* 🐛fix:safely convert values to numbers and handle NaN cases (#5309)

* chore: correct binary name for stable version (#5303) (#5311)

Co-authored-by: hiento09 <136591877+hiento09@users.noreply.github.com>

* 🐛fix: llama.cpp default NGL setting does not offload all layers to GPU (#5310)

* 🐛fix: llama.cpp default NGL setting does not offload all layers to GPU

* chore: cover more cases

* chore: clean up

* fix: should not show GPU section on Mac

* 🐛fix: update default extension settings (#5315)

* fix: update default extension settings

* chore: hide language setting on Prod

* 🐛fix: allow script posthog (#5316)

* Sync 0.5.18 to 0.6.0 (#5320)

* chore: correct binary name for stable version (#5303)

* ci: enable devtool on prod build (#5317)

* ci: enable devtool on prod build

---------

Co-authored-by: hiento09 <136591877+hiento09@users.noreply.github.com>
Co-authored-by: Nguyen Ngoc Minh <91668012+Minh141120@users.noreply.github.com>

* fix: glitch model download issue (#5322)

* 🐛 fix(updater): terminate sidecar processes before update to avoid file access errors (#5325)

* 🐛 fix: disable sorting for threads in SortableItem and clean up thread order handling (#5326)

* improved wording in UI elements (#5323)

* fix: sorted-thread-not-stable (#5336)

* 🐛fix: update wording desc vulkan (#5338)

* 🐛fix: update wording desc vulkan

* enhancement: update copy

* 🐛fix: handle NaN value tokenspeed (#5339)

* 🐛 fix: window path problem

* feat(server): filter /models endpoint to show only downloaded models (#5343)

- Add filtering logic to proxy server for GET /models requests
- Keep only models with status "downloaded" in response
- Remove Content-Length header to prevent mismatch after filtering
- Support both ListModelsResponseDto and direct array formats
- Add comprehensive tests for filtering functionality
- Fix Content-Length header conflict causing empty responses

Fixes issue where all models were returned regardless of download status.

* 🐛fix: render streaming token speed based on thread ID & assistant metadata (#5346)

* fix(server): add gzip decompression support for /models endpoint filtering (#5349)

- Add gzip detection using magic number check (0x1f 0x8b)
- Implement gzip decompression before JSON parsing
- Add gzip re-compression for filtered responses
- Fix "invalid utf-8 sequence" error when upstream returns gzipped content
- Maintain Content-Encoding consistency for compressed responses
- Add comprehensive gzip handling with flate2 library

Resolves issue where filtering failed on gzip-compressed model responses.

* fix(proxy): implement true HTTP streaming for chat completions API (#5350)

* fix: glitch toggle gpus (#5353)

* fix: glitch toogle gpu

* fix: Using the GPU's array index as a key for gpuLoading

* enhancement: added try-finally

* fix: built in models capabilities (#5354)

* 🐛fix: setting provider hide model capabilities (#5355)

* 🐛fix: setting provider hide model capabilities

* 🐛fix: hide tools icon on dropdown model providers

* fix: stop server on app close or reload

* enhancement: reset heading class

---------

Co-authored-by: Louis <louis@jan.ai>

* fix: stop api server on page unload (#5356)

* fix: stop api server on page unload

* fix: check api server status on reload

* refactor: api server state

* fix: should not pop the guard

* 🐛fix: avoid render html title thread (#5375)

* 🐛fix: avoid render html title thread

* chore: minor bump - tokenjs for manual adding models

---------

Co-authored-by: Louis <louis@jan.ai>

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
Co-authored-by: LazyYuuki <huy2840@gmail.com>
Co-authored-by: Bui Quang Huy <34532913+LazyYuuki@users.noreply.github.com>
Co-authored-by: hiento09 <136591877+hiento09@users.noreply.github.com>
Co-authored-by: Nguyen Ngoc Minh <91668012+Minh141120@users.noreply.github.com>
Co-authored-by: Sam Hoang Van <samhv.ict@gmail.com>
Co-authored-by: Ramon Perez <ramonpzg@protonmail.com>
2025-06-20 09:46:43 +07:00
Louis
5a09317c8d
Merge branch 'dev' into release/v0.6.1
# Conflicts:
#	extensions/inference-cortex-extension/resources/default_settings.json
#	extensions/inference-cortex-extension/src/index.ts
#	extensions/model-extension/resources/default.json
#	web-app/src/containers/ThreadContent.tsx
#	web-app/src/containers/TokenSpeedIndicator.tsx
#	web-app/src/hooks/useChat.ts
#	web-app/src/lib/version.ts
#	web-app/src/routes/hub.tsx
#	web-app/src/routes/settings/hardware.tsx
2025-06-20 09:41:43 +07:00
Faisal Amir
67592f3f45
🐛fix: avoid render html title thread (#5375)
* 🐛fix: avoid render html title thread

* chore: minor bump - tokenjs for manual adding models

---------

Co-authored-by: Louis <louis@jan.ai>
2025-06-19 23:08:45 +07:00
Faisal Amir
5a73031d62
fix: remove log (#5366) 2025-06-19 15:52:29 +07:00
Faisal Amir
cf17576e1c
fix: download link (#5365) 2025-06-19 15:40:54 +07:00
Faisal Amir
85d32a4c70
enhancement: show app size on download dropdown (#5360)
* enhancement: show app size on download dropdown

* Update docs/src/utils/format.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* chor: update copy

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-19 12:04:16 +07:00
Louis
22396111be
fix: stop api server on page unload (#5356)
* fix: stop api server on page unload

* fix: check api server status on reload

* refactor: api server state

* fix: should not pop the guard
2025-06-19 00:12:03 +07:00
David
8c507e5569
Merge pull request #5357 from menloresearch/fix/update-broken-installation-url
fix: update broken installation url
2025-06-18 22:59:48 +07:00
David
4400d50c30 fix: update broken installation url 2025-06-18 22:57:33 +07:00
Faisal Amir
5b60116d21
🐛fix: setting provider hide model capabilities (#5355)
* 🐛fix: setting provider hide model capabilities

* 🐛fix: hide tools icon on dropdown model providers

* fix: stop server on app close or reload

* enhancement: reset heading class

---------

Co-authored-by: Louis <louis@jan.ai>
2025-06-18 21:48:18 +07:00
Faisal Amir
c6cd37d916
fix: built in models capabilities (#5354) 2025-06-18 20:28:30 +07:00
Faisal Amir
0681c6bb9e
fix: glitch toggle gpus (#5353)
* fix: glitch toogle gpu

* fix: Using the GPU's array index as a key for gpuLoading

* enhancement: added try-finally
2025-06-18 19:58:24 +07:00
Bui Quang Huy
f5971b9d03
🔀 Merge: pull request #5351 from menloresearch/fix/window-path-fix
🐛 Fix: window path name with a space lead to cannot find correct path to Jan datafolder
2025-06-18 17:17:53 +07:00
Sam Hoang Van
eb5655bbd4
fix(proxy): implement true HTTP streaming for chat completions API (#5350) 2025-06-18 16:19:48 +07:00
Sam Hoang Van
6cee466f52
fix(server): add gzip decompression support for /models endpoint filtering (#5349)
- Add gzip detection using magic number check (0x1f 0x8b)
- Implement gzip decompression before JSON parsing
- Add gzip re-compression for filtered responses
- Fix "invalid utf-8 sequence" error when upstream returns gzipped content
- Maintain Content-Encoding consistency for compressed responses
- Add comprehensive gzip handling with flate2 library

Resolves issue where filtering failed on gzip-compressed model responses.
2025-06-18 15:30:31 +07:00
Faisal Amir
45df0b272d
🐛fix: render streaming token speed based on thread ID & assistant metadata (#5346) 2025-06-18 14:54:56 +07:00
Sam Hoang Van
369ba5ac75
feat(server): filter /models endpoint to show only downloaded models (#5343)
- Add filtering logic to proxy server for GET /models requests
- Keep only models with status "downloaded" in response
- Remove Content-Length header to prevent mismatch after filtering
- Support both ListModelsResponseDto and direct array formats
- Add comprehensive tests for filtering functionality
- Fix Content-Length header conflict causing empty responses

Fixes issue where all models were returned regardless of download status.
2025-06-18 14:11:53 +07:00
Saugat Acharya
f41c565f95
docs: update continue integration link (#5344) 2025-06-18 14:03:55 +07:00
LazyYuuki
a075debb05 🐛 fix: window path problem 2025-06-18 14:02:36 +08:00
Faisal Amir
771105a5b2
🐛fix: handle NaN value tokenspeed (#5339) 2025-06-18 12:35:42 +07:00
Faisal Amir
417b789b5e
🐛fix: update wording desc vulkan (#5338)
* 🐛fix: update wording desc vulkan

* enhancement: update copy
2025-06-18 12:35:37 +07:00
Sam Hoang Van
b30de3d1ae
fix: sorted-thread-not-stable (#5336) 2025-06-18 09:39:18 +07:00
Ramon Perez
06be778e98
improved wording in UI elements (#5323) 2025-06-18 09:35:57 +07:00
Sam Hoang Van
1160ea140b
🐛 fix: disable sorting for threads in SortableItem and clean up thread order handling (#5326) 2025-06-18 00:23:53 +07:00
Nguyen Ngoc Minh
3f07358125
🐛 fix(updater): terminate sidecar processes before update to avoid file access errors (#5325) 2025-06-17 23:43:15 +07:00
Ramon Perez
3b624eb466
improved wording in UI elements (#5323) 2025-06-17 23:17:15 +07:00
Louis
52bb54d2d5
fix: glitch model download issue (#5322) 2025-06-17 23:01:22 +07:00
Louis
ebc268018b
Sync 0.5.18 to 0.6.0 (#5320)
* chore: correct binary name for stable version (#5303)

* ci: enable devtool on prod build (#5317)

* ci: enable devtool on prod build

---------

Co-authored-by: hiento09 <136591877+hiento09@users.noreply.github.com>
Co-authored-by: Nguyen Ngoc Minh <91668012+Minh141120@users.noreply.github.com>
2025-06-17 21:08:56 +07:00
Faisal Amir
11d767633e
🐛fix: allow script posthog (#5316) 2025-06-17 18:35:02 +07:00
Louis
86079074d2
🐛fix: update default extension settings (#5315)
* fix: update default extension settings

* chore: hide language setting on Prod
2025-06-17 17:37:31 +07:00
Louis
2899d58ad7
🐛fix: llama.cpp default NGL setting does not offload all layers to GPU (#5310)
* 🐛fix: llama.cpp default NGL setting does not offload all layers to GPU

* chore: cover more cases

* chore: clean up

* fix: should not show GPU section on Mac
2025-06-17 15:30:07 +07:00
Louis
50c25b65b6
chore: correct binary name for stable version (#5303) (#5311)
Co-authored-by: hiento09 <136591877+hiento09@users.noreply.github.com>
2025-06-17 13:35:53 +07:00
Faisal Amir
321fb858dd
🐛fix:safely convert values to numbers and handle NaN cases (#5309) 2025-06-17 13:15:40 +07:00
Faisal Amir
f0ec3e03d1
🐛fix: immediately show download progress (#5308) 2025-06-17 12:46:23 +07:00
Faisal Amir
a745d24fbe
🐛fix: glitch padding speed token (#5307) 2025-06-17 10:00:55 +07:00
Faisal Amir
f7b53da898
🐛fix: hide token speed when assistant params stream false (#5302) 2025-06-16 21:50:23 +07:00
Faisal Amir
4dfc9f604a
🐛fix: remove onboarding local model and hide the edit capabilities model (#5301)
* 🐛fix: remove onboarding local model and hide the edit capabilities model

* ♻️refactor: conditional search params setup screen
2025-06-16 20:53:48 +07:00
Louis
4181454799
🐛fix: typo in build type check (#5297) 2025-06-16 18:45:26 +07:00
Louis
035cc0f79c
Sync Release/v0.6.0 into dev (#5293)
* chore: enable shortcut zoom (#5261)

* chore: enable shortcut zoom

* chore: update shortcut setting

* fix: thinking block (#5263)

* Merge pull request #5262 from menloresearch/chore/sync-new-hub-data

chore: sync new hub data

* enhancement: model run improvement (#5268)

* fix: mcp tool error handling

* fix: error message

* fix: trigger download from recommend model

* fix: can't scroll hub

* fix: show progress

* enhancement: prompt users to increase context size

* enhancement: rearrange action buttons for a better UX

* 🔧chore: clean up logics

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>

* fix: glitch download from onboarding (#5269)

* enhancement: Model sources should not be hard coded from frontend (#5270)

* 🐛fix: default onboarding model should use recommended quantizations (#5273)

* 🐛fix: default onboarding model should use recommended quantizations

* enhancement: show context shift option in provider settings

* 🔧chore: wording

* 🔧 config: add to gitignore

* 🐛fix: Jan-nano repo name changed (#5274)

* 🚧 wip: disable showSpeedToken in ChatInput

* 🐛 fix: commented out the wrong import

* fix: masking value MCP env field (#5276)

*  feat: add token speed to each message that persist

* ♻️ refactor: to follow prettier convention

* 🐛 fix: exclude deleted field

* 🧹 clean: all the missed console.log

* enhancement: out of context troubleshooting (#5275)

* enhancement: out of context troubleshooting

* 🔧refactor: clean up

* enhancement: add setting chat width container (#5289)

* enhancement: add setting conversation width

* enahncement: cleanup log and change improve accesibility

* enahcement: move const beta version

* 🐛fix: optional additional_information gpu (#5291)

* 🐛fix: showing release notes for beta and prod (#5292)

* 🐛fix: showing release notes for beta and prod

* ♻️refactor: make an utils env

* ♻️refactor: hide MCP for production

* ♻️refactor: simplify the boolean expression fetch release note

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
Co-authored-by: LazyYuuki <huy2840@gmail.com>
Co-authored-by: Bui Quang Huy <34532913+LazyYuuki@users.noreply.github.com>
2025-06-16 17:27:42 +07:00
David
38dedc2fb8
Merge pull request #5295 from menloresearch/fix/jan-doc-hotfix-index
fix: update jan doc
2025-06-16 19:21:13 +09:00
David
9ddee97107 fix: update jan doc 2025-06-16 17:19:40 +07:00
David
8d514c3e30
Merge pull request #5294 from menloresearch/fix/jan-doc-hotfix
fix: jan doc hotfix
2025-06-16 19:15:23 +09:00
Faisal Amir
9b1f206cc6
🐛fix: showing release notes for beta and prod (#5292)
* 🐛fix: showing release notes for beta and prod

* ♻️refactor: make an utils env

* ♻️refactor: hide MCP for production

* ♻️refactor: simplify the boolean expression fetch release note
2025-06-16 17:14:38 +07:00
David
f3e7ee2f2f fix: jan doc hotfix 2025-06-16 17:12:37 +07:00
Faisal Amir
8e921ab521
🐛fix: optional additional_information gpu (#5291) 2025-06-16 16:28:54 +07:00
Faisal Amir
da2f97c227
enhancement: add setting chat width container (#5289)
* enhancement: add setting conversation width

* enahncement: cleanup log and change improve accesibility

* enahcement: move const beta version
2025-06-16 15:02:43 +07:00
David
637cf77ed9
Merge pull request #5176 from menloresearch/chore/jan-doc-update
refactor: Jan doc update
2025-06-16 00:15:51 +09:00
David
f7b5408275 chore: update mcp doc and model param pics 2025-06-15 22:11:37 +07:00
David
617213eb1c Merge branch 'dev' into chore/jan-doc-update 2025-06-15 21:58:28 +07:00
David
4395be40f3
chore: add a place to download beta apps (#5280) 2025-06-15 20:35:49 +07:00
Bui Quang Huy
bea806c26c
Merge pull request #5278 from menloresearch/feat/token-speed-modification
 Feat: Token Speed Display Feature
2025-06-15 20:33:52 +08:00
Louis
079c1a6bab
Update docs/src/pages/docs/mcp.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-15 19:30:38 +07:00
Louis
97b975b527
Update docs/src/pages/docs/manage-models.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-15 19:29:57 +07:00
Louis
833f749e4b
Update docs/src/pages/docs/settings.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-15 19:29:41 +07:00
Louis
29fd785614
Update docs/src/pages/docs/remote-models/anthropic.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-15 19:29:22 +07:00
Louis
235d4b43e9
Update docs/src/pages/docs/mcp.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-15 19:28:38 +07:00
Louis
2a9f5d4209
Update docs/src/pages/docs/index.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-15 19:28:33 +07:00
Louis
5ed9908881
Update docs/src/pages/docs/mcp.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-15 19:28:27 +07:00
Louis
84030e8f94
Update docs/src/pages/docs/mcp.mdx
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-15 19:28:16 +07:00
Louis
e20c801ff0
enhancement: out of context troubleshooting (#5275)
* enhancement: out of context troubleshooting

* 🔧refactor: clean up
2025-06-15 18:20:17 +07:00
LazyYuuki
de5ddaac6d 🧹 clean: all the missed console.log 2025-06-15 19:12:19 +08:00
LazyYuuki
b93f8afda2 🐛 fix: exclude deleted field 2025-06-15 19:05:11 +08:00
LazyYuuki
4b3a0918fe ♻️ refactor: to follow prettier convention 2025-06-15 18:54:22 +08:00
LazyYuuki
665de7df55 feat: add token speed to each message that persist 2025-06-15 18:30:39 +08:00
Ramon Perez
f74024db66 README, troubleshooting, and settings updated 2025-06-15 19:26:22 +10:00
Ramon Perez
af428a58b9 MCP section completed 2025-06-15 19:26:22 +10:00
Ramon Perez
a88b97c875 new docs revamped for Jan v0.5.18-rc 2025-06-15 19:26:22 +10:00
Ramon Perez
96492f6a1a new docs revamped for Jan v0.5.18 2025-06-15 19:26:22 +10:00
David
051d6d3727 chore: update docs for tauri
chore: update docs for tauri
2025-06-15 19:26:22 +10:00
Faisal Amir
d131752419
fix: masking value MCP env field (#5276) 2025-06-15 16:18:43 +07:00
LazyYuuki
3ae4d12f60 🐛 fix: commented out the wrong import 2025-06-15 16:08:58 +08:00
LazyYuuki
2ff1776379 🚧 wip: disable showSpeedToken in ChatInput 2025-06-15 16:07:08 +08:00
Louis
9ab69b157b
🐛fix: Jan-nano repo name changed (#5274) 2025-06-15 11:17:41 +07:00
LazyYuuki
c896398fab 🔧 config: add to gitignore 2025-06-15 10:45:37 +08:00
Louis
2634659366
🐛fix: default onboarding model should use recommended quantizations (#5273)
* 🐛fix: default onboarding model should use recommended quantizations

* enhancement: show context shift option in provider settings

* 🔧chore: wording
2025-06-15 02:34:14 +07:00
Louis
a10dbef2c8
enhancement: Model sources should not be hard coded from frontend (#5270) 2025-06-14 22:00:43 +07:00
Faisal Amir
b5bdf3cfd2
fix: glitch download from onboarding (#5269) 2025-06-14 17:38:14 +07:00
Louis
1e17cc6ec7
enhancement: model run improvement (#5268)
* fix: mcp tool error handling

* fix: error message

* fix: trigger download from recommend model

* fix: can't scroll hub

* fix: show progress

* enhancement: prompt users to increase context size

* enhancement: rearrange action buttons for a better UX

* 🔧chore: clean up logics

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-06-14 16:32:15 +07:00
Louis
23240f958e
Merge pull request #5262 from menloresearch/chore/sync-new-hub-data
chore: sync new hub data
2025-06-13 17:05:49 +07:00
Faisal Amir
e04dfc73c7
fix: thinking block (#5263) 2025-06-13 15:22:55 +07:00
Faisal Amir
2b8c448be4
chore: enable shortcut zoom (#5261)
* chore: enable shortcut zoom

* chore: update shortcut setting
2025-06-13 11:37:34 +07:00
Louis
e586f2387e
Merge pull request #5213 from menloresearch/release/v0.5.18
Sync Release/v0.5.18 into Development branch
2025-06-13 09:49:37 +07:00
Louis
72aa39d67f
Merge branch 'dev' into release/v0.5.18
# Conflicts:
#	.github/workflows/jan-tauri-build-nightly.yaml
#	.github/workflows/template-tauri-build-linux-x64.yml
#	.github/workflows/template-tauri-build-macos.yml
#	.github/workflows/template-tauri-build-windows-x64.yml
#	web/containers/ModelDropdown/index.tsx
2025-06-13 00:07:57 +07:00
Louis
27c4918395
fix: default settings should leave empty (#5257)
* fix: default settings should leave empty

* fix: default settings

* fix: remove some more default settings

* fix: threads and cont

* fix: data

* fix: default setting

* fix: settings

* chore: bump cortex version

* chore: bump to cortex 1.0.14

* chore: clean up

* typoe

* chore: fix dialog hang

* fix: default parameter

* chore: truncate edit model title

* chore: update default provider settings

* chore: fix typo

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-06-13 00:01:25 +07:00
Sam Hoang Van
e22452b26e
fix: add cortex_killed_intentionally state to manage sidecar process termination (#5255)
* fix: add cortex_killed_intentionally state to manage sidecar process termination

* fix: improve handling of intentionally killed sidecar process
2025-06-12 19:20:27 +07:00
Faisal Amir
32f68de36f
fix: race condition tools approval state (#5259) 2025-06-12 18:51:42 +07:00
Faisal Amir
414a9f0da5
fix/replace close think tag from text segment (#5258) 2025-06-12 16:33:33 +07:00
Faisal Amir
6300875e19
fix: reduce app state left panel (#5256) 2025-06-12 15:27:55 +07:00
Nguyen Ngoc Minh
37d72c3869
ci: add manual sign for appimage artifact (#5254) 2025-06-12 14:50:24 +07:00
Faisal Amir
57ad0894ab
fix: cleanup console error and warning render FE (#5253)
* fix: console error render FE

* chore: cleanup error and warning console
2025-06-12 14:35:34 +07:00
Faisal Amir
82736c96b1
chore: fix wrong classname color text (#5252) 2025-06-12 14:03:45 +07:00
Louis
079f206044
fix: avoid persisting threads and messages on local storage (#5249) 2025-06-12 09:10:00 +07:00
Faisal Amir
3accef8c92
fix: minor ui (#5247) 2025-06-12 09:04:47 +07:00
Faisal Amir
e33a37776f
fix: tool call block width code (#5246) 2025-06-12 00:53:27 +07:00
Faisal Amir
d2e88ffdc4
fix: update style cortex dialog (#5245) 2025-06-12 00:09:19 +07:00
David
35a0a4e9a5
Merge pull request #5244 from menloresearch/chore/enhance-hub-guide
chore: enhance hub guide
2025-06-11 21:55:15 +07:00
Faisal Amir
ab5ce6e774
fix: update hgf jan nano (#5242) 2025-06-11 21:54:55 +07:00
David
6152afaed5 chore: enhance hub guide 2025-06-11 21:41:20 +07:00
Faisal Amir
7b59aa32f9
chore: onboarding local model (#5234)
* chore: simple onboarding local model

* chore: update new model and improve flow e2e onboarding local model

* fix: default tool support models

---------

Co-authored-by: Louis <louis@jan.ai>
2025-06-11 18:38:07 +07:00
Louis
50b83d7342
fix: could not add custom models (#5241)
* fix: could not add custom models

* Update web-app/src/lib/completion.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* chore: remove hard coded ID string

* fix: revert suggestion change

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-11 17:04:00 +07:00
Faisal Amir
46add8e88a
chore: experimental tag mcp (#5239)
* chore: experimental tag on mcp setting

* chore: dupl classname
2025-06-11 15:35:55 +07:00
Sam Hoang Van
dba35bc5a4
chore: comment out API documentation handling code (#5240) 2025-06-11 15:15:45 +07:00
Faisal Amir
808fdb02a7
chore: streaming tool output (#5237)
* enhancement: tool streaming output

* chore: update memo

* fix: streaming

* chore: update stream tools arguments

* chore: update condition

* fix: style

* fix: style

* chore: fix stop button

* chore: update color accent and hide arrow button

---------

Co-authored-by: Louis <louis@jan.ai>
2025-06-11 14:35:41 +07:00
David
cfefcb00cb
Merge pull request #5238 from menloresearch/fix/hyper-link-playground
feat(local-api-server): add button to open API documentation and improve layout
2025-06-11 11:53:33 +07:00
sam hoang
6f030f720a
feat(local-api-server): add button to open API documentation and improve layout 2025-06-11 11:46:04 +07:00
Sam Hoang Van
eef37defb4
fix(server): enhance CORS handling for local API network access (#5236)
* fix(server): enhance CORS handling for local API network access

- Fix CORS preflight validation to use Host header for target validation
- Use Origin header correctly for CORS response headers
- Improve host validation to support both host:port and host-only formats
- Filter upstream CORS headers to prevent duplicate Access-Control-Allow-Origin
- Add CORS headers to all error responses for consistent behavior
- Fix host matching logic to handle trusted hosts with and without ports
- Ensure single Access-Control-Allow-Origin header per response

This resolves CORS preflight failures that were blocking cross-origin
requests to the local API server, enabling proper network access from
web applications and external tools.

Fixes: OPTIONS requests being rejected due to incorrect host validation
Resolves: "access control allow origin cannot contain more than one origin" error

* fix(proxy): bypass host and authorization checks for root path in CORS preflight

* fix(proxy): bypass host and authorization checks for whitelisted paths
2025-06-11 09:44:17 +07:00
Louis
1799bfed3f
chore: temporary disable web response 2025-06-10 18:36:48 +07:00
Louis
92a52dfa08
fix: tauri path env (#5233) 2025-06-10 18:31:21 +07:00
Louis
51a321219d
chore: fix model settings are not applied accordingly on change (#5231)
* chore: fix model settings are not applied accordingly on change

* chore: handle failed tool call

* chore: stop inference and model on reject
2025-06-10 16:26:42 +07:00
Sam Hoang Van
dcb3f794d3
Feat: render mcp content (#5229) 2025-06-10 15:06:42 +07:00
Sam Hoang Van
fbb6b6f800
make fzf case-insensitive (#5228) 2025-06-10 12:27:17 +07:00
Faisal Amir
8ba4b0be36
chore: add toggle loading sever MCP (#5225)
* chore: add toggle loading sever mcp

* chore: remove duplicate classname

* chore: remove log

* chore: remove log

* fix: save server config

---------

Co-authored-by: Louis <louis@jan.ai>
2025-06-09 23:56:49 +07:00
Louis
891c149f1b
fix: MCP server should not spawn shell window (#5223)
* fix: MCP server should not spawn shell window

* Update src-tauri/src/core/mcp.rs

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-09 23:23:34 +07:00
Louis
6d6790d5e0
fix: clean up cortex processes (#5215)
* fix: clean up cortex processes

* chore: clean up

* chore: does not need output shell
2025-06-09 22:23:07 +07:00
Nguyen Ngoc Minh
ecfbdf8256
chore: build config info plist (#5224)
* chore: update Info.plist and tauri config to reflect build channel
2025-06-09 22:20:38 +07:00
Faisal Amir
c41a6c3899
fix: tools call available dropdown (#5222) 2025-06-09 20:58:09 +07:00
Louis
919b6671a1
enahancement: mcp server activation response and error handling (#5220)
* fix: mcp server error handling

* fix: custom installation path of MCP package managers

* chore: clean up

* chore: clean up

* chore: append mcp server errors to app logs

* fix: logs reading

* chore: typo
2025-06-09 19:43:16 +07:00
Faisal Amir
0d0c624e99
chore: force windows to default alpha color 1 (#5218) 2025-06-09 17:44:22 +07:00
Faisal Amir
4a3a0e6496
fix/ui-glitch-dots-truncated (#5219) 2025-06-09 17:44:06 +07:00
Faisal Amir
1d69101f97
fix: conditional button refresh model (#5221) 2025-06-09 17:43:48 +07:00
Faisal Amir
1bbac32d88
fix: glitch UI thinking or duplicate content when multiple think after tools call (#5217)
* fix: update id streaming content think

* fix: glitch UI or duplicate content when multiple thinking
2025-06-09 11:36:36 +07:00
Faisal Amir
44b5310a6a
fix/pretify json when paste content (#5216) 2025-06-09 11:04:29 +07:00
Louis
46c7f02827
fix: avoid spamming server restarts (#5212) 2025-06-07 11:54:35 +07:00
Louis
b72259d78f
chore: trim all mcp server configs before saving (#5211) 2025-06-07 00:55:12 +07:00
Louis
1fa9f4e731
fix: should not show vulkan options in cpu only mode (#5210) 2025-06-07 00:55:01 +07:00
Louis
c444643294
fix: path resolver in windows (#5209) 2025-06-06 17:26:08 +07:00
Nguyen Ngoc Minh
19bcce80fa
ci: update file size tauri build template macos and windows (#5208)
* chore: update filesize latest-mac.yaml

* chore: disable createUpdaterArtifacts as handled on ci

* chore: update file size latest.yaml
2025-06-06 16:02:09 +07:00
Louis
cceae09fef
fix: load threads from api instead of states (#5206) 2025-06-06 13:16:29 +07:00
Faisal Amir
2feba874ef
fix: force provider avatar to render in high quality (#5203) 2025-06-06 08:56:29 +07:00
Louis
b85bce8e09
fix: migrate provider settings (#5205)
* chore: fix migrate api key

* chore: add logs

* chore: deprecate migration step

* chore: clean up

* fix: key apply
2025-06-05 20:25:43 +07:00
David
81f1d644e1
Merge pull request #5204 from menloresearch/fix/mcp-file-system
Fix: mcp server file system missing param
2025-06-05 15:00:19 +07:00
Faisal Amir
ac8a3b4f96
feat: store last use model (#5201) 2025-06-05 14:32:22 +07:00
David
3cdbff53eb fix: file system mcp server missing param 2025-06-05 14:32:10 +07:00
Faisal Amir
a84034c552
chore: thinking block auto collapse when streaming finish (#5202)
* chore: thinking block  auto collapse when streaming finish

* chore: fix padding
2025-06-05 14:29:33 +07:00
Faisal Amir
8ee4969aa9
fix: dropdown model position (#5199) 2025-06-05 12:07:43 +07:00
Faisal Amir
2588c3fa55
fix: truncate tool name (#5198)
* fix: truncate tool name

* fix: border hub search
2025-06-05 00:47:11 +07:00
Sam Hoang Van
9c9a9cb521
feat: integrate fuzzy search into model dropdown (#5197)
* feat: integrate fuzzy search into model dropdown

- Replace DropdownMenu with Popover for better search UX
- Include search input with clear functionality
- Reorganize layout with capabilities at end of row
- Maintain provider grouping and model selection functionality

Improves model discovery and selection with instant search across
model names, providers, and capabilities.

* chore: enhance input search style

* feat: enhance model dropdown with search highlighting and fixed positioning

- Add FZF search highlighting with text-accent color for matched characters
- Fix dropdown to only appear below (prevent upward positioning)
- Import highlightFzfMatch utility for search result highlighting
- Update SearchableModel interface to include highlightedId property
- Modify FZF selector to target model.id for more accurate highlighting
- Use dangerouslySetInnerHTML to render highlighted search matches
- Add avoidCollisions=false to PopoverContent for consistent positioning

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-06-05 00:30:38 +07:00
Louis
fb7dc21135
chore: update MCP servers list (#5195)
* chore: update MCP servers list

* chore: rename

* chore: attempt to stop models before updating

* chore: clean up logs

* chore: fix bug refresh
2025-06-04 21:47:27 +07:00
David
f97a51b34d
Merge pull request #5196 from menloresearch/fix/add-missing-default-host-ip
fix: add missing default host ip
2025-06-04 20:42:32 +07:00
David
534a673c51 fix: add missing default host ip 2025-06-04 20:08:41 +07:00
Louis
cb3ac4b136
feat: Jan API Server should have API Key setting (#5193)
* feat: Jan API Server should have API Key setting

* chore: reveal api key icon

* Update src-tauri/src/core/server.rs

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* chore: add validation apiKey

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-04 18:04:47 +07:00
Faisal Amir
da10502bdd
fix: remind me later updater (#5191)
* fix: remind me later app updater

* chore: update state app updater

* chore sync state
2025-06-04 15:35:38 +07:00
Louis
6faca3e732
refactor: remove JS server package (#5192)
* refactor: remove js server package

* chore: migrate HF token data
2025-06-04 15:33:35 +07:00
David
30acc6f493
Merge pull request #5186 from menloresearch/fix/headers-validations-for-local-api-server
Fix: headers validations for local api server
2025-06-04 12:45:38 +07:00
Faisal Amir
a88da16edc
chore: hide some model capabilities (#5189)
* chore: hide some model capabilities

* chore: update model setting description

* chore: disable vision and embedding and add tooltip

---------

Co-authored-by: Louis <louis@jan.ai>
2025-06-04 12:11:16 +07:00
Faisal Amir
7ca57e1fa7
fix: hub refresh state (#5190) 2025-06-04 12:11:03 +07:00
David
b674a521f2 fix: validate trusted hosts for local api server 2025-06-04 11:50:51 +07:00
Louis
a3e78dd563
refactor: clean up migrations (#5187) 2025-06-04 00:41:14 +07:00
Louis
171b1e8c60
fix: handle tool availability states (#5183)
* fix: handle tool availability states

* Update web-app/src/hooks/useToolAvailable.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Update web-app/src/hooks/useToolAvailable.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Update web-app/src/hooks/useToolAvailable.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* fix: hub refresh

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-04 00:17:39 +07:00
Nguyen Ngoc Minh
9c825956e8
ci: tauri build macos (#5184)
* ci: tauri build macos

* chore: comment out electron builder .zip.sig file to s3

* chore: enable auto updater tauri

* chore: comment out s3 upload mac.zip.sig

* chore: handle remind me later state

* chore: add dll file windows

* chore: add debug step verbose

* ci: add msvcp140_codecvt_ids.dll bundle windows

* chore: update download progress

* chore: update app updater UI

* chore: remove log

* chore: reload app after download app

* chore: reset remindmelater
2025-06-03 23:00:04 +07:00
Louis
7dc51c5e0f
fix: relocate jan data folder (#5179)
* fix: relocate jan data folder failed

* fix: avoid infinite recursion

* chore: kill background processes to unblock factory reset

* chore: stop models before reset factory

* chore: clean up

* chore: clean up

* fix: show error

* chore: get active models should not have retry
2025-06-03 21:23:42 +07:00
Faisal Amir
135e75b812
fix: avatar assistants render (#5181)
* fix: avatar assistants render

* fix: delete assistant

* Update web-app/src/containers/dialogs/AddEditAssistant.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-03 20:00:25 +07:00
Sam Hoang Van
a3ebabfd4e
feat: add updateThreadTimestamp function to manage thread order and timestamp updates (#5180) 2025-06-03 18:53:58 +07:00
Louis
cf56f7e5c0
fix: migration should wait for extensions load (#5177)
* fix: migration should wait for extensions load

* fix: check engines load

* chore: resolve out of attempts
2025-06-03 18:04:07 +07:00
Faisal Amir
6861c46ac6
feat: setting toggle vulkan (#5126)
* feat: setting toggle vulkan

* feat: add vulkan toggle setting

* chore: default flash attention disable

* chore: fix vulkan retrieval

* fix: vulkan setting does not affect engine run

* Update web-app/src/routes/settings/hardware.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: Louis <louis@jan.ai>
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-03 13:56:23 +07:00
Louis
de9c59d309
chore: enhance MCP permission settings (#5178)
* chore: enhance MCP permission settings

* chore: bring default mcp servers in

* chore: default mcp servers are inactive
2025-06-03 13:36:21 +07:00
Sam Hoang Van
307ea39413
fix: handle undefined search index in getFilteredThreads (#5175) 2025-06-03 11:29:19 +07:00
Louis
ecef9d7df6
feat: handle open Jan on HF GGUF repo (#5173)
* feat: handle open Jan on HF GGUF repo

* chore: reset retry attempts
2025-06-03 01:09:36 +07:00
Louis
817e3175f3
fix: model run failed on windows (#5168)
* fix: model run failed on windows

* chore: fix dependency path on windows
2025-06-03 00:03:10 +07:00
Faisal Amir
aeba895250
fix: app updater state (#5171) 2025-06-02 22:25:38 +07:00
Faisal Amir
b0d3d485cf
fix: sticky action scroll to bottom when edit message (#5169) 2025-06-02 22:00:12 +07:00
Faisal Amir
d56686fd21
chore: check app update via general setting (#5167) 2025-06-02 20:33:48 +07:00
Louis
1a0f643d87
refactor: clean up repo (#5165)
* chore: remove legacy themes

* refactor: clean up dependencies

* chore: remove cuda 11 dependency - fix linux LD_LIBRARY_PATH

* fix: load models issue on Linux

# Conflicts:
#	src-tauri/src/core/setup.rs

* chore: do not download cuda 11 by default

* chore: remove cuda 11 from installer

* fix: cuda lookup on Linux
2025-06-02 19:03:06 +07:00
Thien Tran
8509479dfb
fix: Fix hwinfo bugs (#5164)
* add libnvidia-ml.so.1 fallback for linux

* fix AMD memory usage on Linux

* add os_type. use std::env::consts::ARCH directly
2025-06-02 17:39:10 +08:00
Louis
ae6d343d19
fix: create new provider should not have previous settings (#5166) 2025-06-02 15:56:11 +07:00
Louis
302ebc0a72
chore: remove build:joi step 2025-06-02 15:35:34 +07:00
Louis
38c9cf9a68
refactor: deprecate legacy packages and clean up build scripts (#5162)
* refactor: deprecate legacy packages and clean up build scripts

* chore: remove joi publish workflow

* chore: core publish run on dispatch only

* chore: correct version bump on web package

* chore: make dev for tauri target
2025-06-02 14:29:17 +07:00
Faisal Amir
5d070f6a17
fix/solid background for linux and web (#5163) 2025-06-02 14:25:14 +07:00
Faisal Amir
5c60d2887a
fix: race condition get Assistant (#5161) 2025-06-02 14:17:55 +07:00
Faisal Amir
5dd4b62bcc fix: tooltip tools chat input 2025-06-02 12:31:58 +07:00
Faisal Amir
fa9d81e3b2
enhancement/tmp-hide-attachment-icon (#5160) 2025-06-02 10:02:03 +07:00
Faisal Amir
101e692e50
fix: remove capitalize class from provider name (#5158) 2025-06-02 09:37:31 +07:00
Faisal Amir
b98c31b184
enhancement: open folder log and change data folder dialog confirm (#5159)
* enhancement: ux change data folder with confirmation and reveal in finder logs

* chore: update button open logs local api server

* Update web-app/src/components/ui/button.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* chore: handle error when change location data folder failed

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-02 08:54:16 +07:00
Faisal Amir
057accfb96
enhancement: ux tool call permission dialog and state active (#5157)
* enhancement: mcp toold dialog approval

* enhancement: update mcp tool enable or disable

* chore: add toggle mcl global permission
2025-06-01 23:58:20 +07:00
Louis
573e667c34
feat: migrate legacy local storage data to new app (#5156)
* feat: migrate legacy local storage data to new app

* chore: refactor localstorage db read

* chore: clean up

* chore: migrate api key setting

* chore: apply proxy configs

* chore: fix key
2025-06-01 22:57:01 +07:00
Louis
646ba86de8
fix: extension settings are not retained in new sessions (#5154) 2025-05-31 21:28:08 +07:00
Nguyen Ngoc Minh
88c7a0fcb6
ci: add tauri build nightly manual (#5153)
* ci: add tauri build nightly manual

* ci: add template tauri build for linux mac and windows
2025-05-31 16:24:24 +07:00
Nguyen Ngoc Minh
9265a56f04
ci: deprecate electron build (#5149)
* ci: deprecate electron build
2025-05-30 19:43:06 +07:00
Faisal Amir
120de819e7
fix: avoid floating content when render table markdown (#5148) 2025-05-30 17:33:38 +07:00
Faisal Amir
81a7248a93
enhancement: querry search hub include list of model (#5147) 2025-05-30 15:09:43 +07:00
Faisal Amir
cde10a662c
chore: render markdown on user message (#5146) 2025-05-30 15:09:28 +07:00
Faisal Amir
3022fdebc2
fix: update model id dropdown without refresh (#5144) 2025-05-30 13:05:06 +07:00
Faisal Amir
426dc2ab87
fix: thread list state order after dragable (#5141)
* fix: thread list state order after dragable

* fix: new chat order

* chore: revert data provider
2025-05-30 00:00:26 +07:00
Faisal Amir
27c2a360f0
fix: reverse setting local provider (#5140)
* fix: reverse setting local provider

* fix conflict
2025-05-30 00:00:07 +07:00
Faisal Amir
e9c9205544
fix/content overflow when long text without space (#5142) 2025-05-29 23:46:09 +07:00
Louis
2b7b9c2dc6
chore: add timeout to tool use requests (#5143) 2025-05-29 23:45:55 +07:00
Faisal Amir
ec7d0c6abf
fix: tool call block spacing (#5139) 2025-05-29 22:28:11 +07:00
Faisal Amir
8046f95b67
feat: add refresh button list model remote provider (#5136) 2025-05-29 22:06:25 +07:00
Faisal Amir
dc1071fff8
chore: hide reaveal password (#5138) 2025-05-29 22:04:37 +07:00
Louis
a1111033d9
chore: allow users to setting model offload (#5134)
* chore: allow users to setting model offload

* chore: apply model.yaml configurations to default model settings

* chore: fallback default value
2025-05-29 13:29:32 +07:00
Faisal Amir
1b3f16b3e1
feat: start and stop model (#5133)
* feat: start and stop model

* refactor: clean up start models

---------

Co-authored-by: Louis <louis@jan.ai>
2025-05-29 13:23:12 +07:00
Faisal Amir
72d1192499
chore: add skip button joyride (#5125) 2025-05-28 20:10:59 +07:00
Faisal Amir
f812952044
enhancement: all platform layout (#5119)
* enhancement: conditional layout leftpanel for windows

* chore: calculate height leftpanel windows

* chore: enhance calc left panel height

* enhancement minor ui

* Update web-app/src/routes/settings/hardware.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-05-28 20:10:51 +07:00
Faisal Amir
cfcc99d75f
feat: predefined params (#5128) 2025-05-28 20:09:48 +07:00
Louis
4672754b81
chore: persist assistants settings (#5127)
* chore: assistant settings

* chore: fix model sources issue after deleted models

* chore: assistants as files

* chore: clean up
2025-05-28 19:33:13 +07:00
Thien Tran
ab3f027d02
fix: support delete file for fs.rm() (#5117) 2025-05-28 09:28:13 +08:00
Louis
eb0e21e5d6
chore: bump llama.cpp to b5509 (#5120) 2025-05-27 23:29:41 +07:00
Louis
26154941ca
fix: chore UI issues (#5116)
* fix: app log outputs with debug level

* fix: reasoning block still show loading indicator when stopped

* chore: fix mistral AI base url
2025-05-27 19:38:21 +07:00
Louis
0b8c7bae69
fix: correct app data folder name (#5115)
* fix: correct app data folder name

* chore: clean up
2025-05-27 15:58:25 +07:00
Faisal Amir
2ae6c7ed92
feat: filter downloaded model on hub screen (#5113)
* feat: filter downloaded model on hub screen

* chore: custom avatar provider

* chore: alignment dropdown
2025-05-27 15:17:07 +07:00
Louis
c6ce193256
fix: remove chat message on GUI (#5114)
* fix: remove chat message on GUI

* Update web-app/src/containers/ThreadContent.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* chore: fix message removal sequence

* chore: add comment

* Update web-app/src/containers/ThreadContent.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-05-27 15:13:47 +07:00
Thien Tran
bbfc754fa4
chore: update make clean (#5112) 2025-05-27 13:33:24 +08:00
David
db731efb62
Merge pull request #5107 from menloresearch/fix/janhq-url-correction
Fix: janhq url correction
2025-05-27 10:15:20 +07:00
Faisal Amir
e08b98ec6a
fix: overflow content codeblock (#5110) 2025-05-27 10:07:36 +07:00
Thien Tran
6415be9c74
feat: Support download resume (#5111)
* initial support

* append instead of replace extension
2025-05-27 10:46:49 +08:00
Faisal Amir
e312913088
fix: prevent send message when empty message (#5109) 2025-05-27 09:33:51 +07:00
Louis
0fbc4a4664
chore: add function to model settings (#5108) 2025-05-26 18:53:08 +07:00
David
eb97e4ef26 fix: correct jan repo url 2025-05-26 16:52:32 +07:00
Louis
3aaa6078c0
chore: sync dev to release/v0.5.18 (#5106)
* chore: Jan's code is now under the Apache license (#5042)

* make the model selector popup responsive and wider for bigger screens (#5025)

* make the model selector popup responsive and wider for bigger screens

* fix linting issue

* use vscode config files to recommend prettier plugin and use it to auto format on save

---------

Co-authored-by: Ethan Garber <ethancgarber@gmail.com>

* chore: update Jan change logs v0.5.17

chore: update Jan change logs v0.5.17

* Update README.md (#5072)

Updated license to Apache 2.0

---------

Co-authored-by: ethanova <ethanova@users.noreply.github.com>
Co-authored-by: Ethan Garber <ethancgarber@gmail.com>
Co-authored-by: David <david@menlo.ai>
Co-authored-by: Emre Can Kartal <159995642+eckartal@users.noreply.github.com>
2025-05-26 16:02:30 +07:00
Louis
64f5703461
chore: allow users to import hf repo (#5103)
* chore: allow users to input HF repo id / url

* chore: allow users to search HuggingFace models

* chore: normalize input

* chore: normalize input from FE

* chore: clean up

* chore: clean up

* fix: conflict

* fix: model name from metada instead id

* chore: enable ryhype raw for desc card hub

* fix: broken link

* chore: remove log

---------

Co-authored-by: Faisal Amir <urmauur@gmail.com>
2025-05-26 15:13:22 +07:00
Louis
b8de48c9e9
fix: enhance tool use and model provider not persisted issues (#5094)
* chore: enhance tool use loop

* fix: create new custom provider is not saved

* chore: bump llama.cpp b5488

* chore: normalize reasoning assistant response

* chore: fix tool call parse in stream mode

* fix: give tool call default generated id

* fix: system instruction should be on top of the history

* chore: allow users to add parameters
2025-05-26 15:12:55 +07:00
Nguyen Ngoc Minh
2744e787d1
fix: ci remove pr review trigger (#5105)
* fix: remove pull_request_review trigger to avoid redundant builds

* chore: comment out pr-build-url job in nightly workflow
2025-05-26 15:04:43 +07:00
Thien Tran
71bb7ce1e9
fix: fileStat returned object in JS (#5102)
* fix fileStat returned value in JS

* match type from JS
2025-05-26 14:40:03 +08:00
Faisal Amir
8afb962739
feat: add quick access model setting via dropdown model (#5104)
* feat: add quick access model setting via dropdown model

* Update web-app/src/containers/DropdownModelProvider.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-05-26 13:29:09 +07:00
Faisal Amir
83464b367f
chore: remove model provider from setup screen (#5101) 2025-05-26 12:55:34 +07:00
Faisal Amir
0b312f7a06
chore: translation (#5097)
* chore: translation

* Update web-app/src/locales/id/common.json

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-05-25 17:25:23 +07:00
Faisal Amir
253f9f9501
feat: add couple section about us on general settings (#5098)
* feat: initial about us

* feat: add couple about us on general setting

* chore: change discord url

* Update web-app/src/routes/settings/general.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Update web-app/src/routes/settings/general.tsx

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* chore: add rel attribute

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-05-25 17:25:13 +07:00
Faisal Amir
b29e579042
feat: product analytic (#5099)
* feat: product analytic

* chore: remove comment
2025-05-25 17:25:03 +07:00
Faisal Amir
484caf04aa
feat: file upload thumbnail (#5088) 2025-05-25 01:10:21 +07:00
Faisal Amir
0df92d8bda
fix: broken ui download count when leftpanel close (#5089) 2025-05-25 01:10:07 +07:00
Faisal Amir
a29152aa76
fix: text component scaling (#5090)
* fix: text component scaling

* chore: update scaling text xs to 0.75
2025-05-25 01:09:07 +07:00
Faisal Amir
3443c42947
fix: copy icon indicator when success (#5091) 2025-05-25 01:08:06 +07:00
Louis
cdd13594a3
fix: model import name issues (#5093) 2025-05-24 14:48:38 +07:00
Louis
125104320e
chore: handle many issues with app settings and message actions (#5086)
* chore: handle many issues with app settings and message actions

* Update web-app/src/services/mcp.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-05-23 21:23:52 +07:00
Louis
634efb9d9d
chore: providers should default on (#5083)
* chore: providers should default on

* chore: add emoji image source

* chore: correct connect-src
2025-05-23 16:26:17 +07:00
Thien Tran
56f4ec3b61
feat: improve download extension (#5073) 2025-05-23 16:49:41 +08:00
Faisal Amir
dfe15fac32
enhancement: built-in custom emoji and show metadata message (#5085)
* enhancement: built-in custom emoji and show metadata message

* chore: seperate render avatar as component

* fix: avatar on assistant screen
2025-05-23 15:37:47 +07:00
Thien Tran
063292db6d
fix: copy:lib on macos when directory already exists (#5084) 2025-05-23 14:59:57 +08:00
Louis
994de67f9e
fix: provider activation status (#5081)
* fix: provider activation status

* fix: thread assistant model
2025-05-23 12:04:49 +07:00
Thien Tran
c324ed592a
feat: Hardware info replacement for cortex (#4925) 2025-05-23 12:59:19 +08:00
vansangpfiev
4684cf8ba0
fix: bundle libraries on Linux and Windows (#5078)
* fix: updater

* chore: sync latest nightly

* chore: ignore electron updater config

* chore: upload signatures

* chore: update connect-src

* chore: add log

* chore: correct path macos s3

* fix: close cortex before restarting

* chore: clean

* chore: comment

* Revert "chore: update connect-src"

This reverts commit a592845c0b5293c121fb17671c14bb1f9958bf00.

* chore: update lastest.yml

* chore: cleanup

* chore: stop uploading yml for electron

* chore: linux workflow

* chore: add permissions

* chore: add logs

* chore: linux workflow

* chore: correct path

* chore: add log

* chore: correct path

* chore: pack libs

* chore: skip download cortex for extension

* chore: linux wf

* chore: try add more libs

* chore: rm logs

* fix: app data directory

* fix: windows path

* fix: windows path

* chore: update linux wf

* chore: lint

* chore: more binaries

* chore: update download script

* chore: lint
2025-05-23 11:30:43 +07:00
vansangpfiev
5ce1fad118
chore: update font-src (#5077) 2025-05-23 11:30:29 +07:00
Faisal Amir
fce559a8fa
fix: mcp info when long string without space (#5080) 2025-05-23 11:12:20 +07:00
Faisal Amir
bed0f98beb
fix: hidden date when value 0 (#5079) 2025-05-23 11:12:11 +07:00
Louis
2dda66390d
fix: close side windows should not kill background processes (#5076) 2025-05-23 09:34:29 +07:00
Sam Hoang Van
7df7d8ffa0
feat: Implement Cortex server auto-restart and webview notification (#5074)
* feat: Implement Cortex server auto-restart and webview notification

Implements a robust auto-restart mechanism for the Cortex server (sidecar)
managed by the Tauri backend.

Key changes:

Backend (src-tauri):
- Modified `core/setup.rs` to:
  - Loop sidecar spawning, attempting up to `MAX_RESTARTS` (5) times with a
    `RESTART_DELAY_MS` (5 seconds) between attempts.
  - Monitor the sidecar process for unexpected termination (crashes or
    non-zero exit codes).
  - Reset the restart attempt count to 0 in `AppState` upon a successful
    server spawn.
  - Emit a "cortex_max_restarts_reached" event to the webview if the
    server fails to start after `MAX_RESTARTS`.
- Updated `core/state.rs` to include `cortex_restart_count: Arc<Mutex<u32>>`
  in `AppState` to track restart attempts.
- Added a new Tauri command `reset_cortex_restart_count` in `core/cmd.rs`
  to allow the webview (or other parts of the app) to reset this counter.
- Registered the new command and initialized the `cortex_restart_count`
  in `lib.rs`.

Frontend (web-app):
- Created a new component `CortexFailureDialog.tsx` in
  `src/containers/dialogs/` to:
  - Listen for the "cortex_max_restarts_reached" event from Tauri.
  - Display a dialog informing the user that the local AI engine (Cortex)
    failed to start after multiple attempts.
  - Offer options to "Contact Support" (opens jan.ai/support),
    "Restart Jan" (invokes the `relaunch` Tauri command), or "Okay"
    (dismisses the dialog).
- Integrated the `CortexFailureDialog` into the `RootLayout` in
  `src/routes/__root.tsx` so it's globally available.
- Corrected button variants in `__root.tsx` to use `variant="default"`
  with appropriate classNames for outline styling, resolving TypeScript
  errors.

* refactor: Improve async handling and logging in setup_sidecar function
2025-05-22 23:09:43 +07:00
Louis
942f2f51b7
chore: send chat completion with messages history (#5070)
* chore: send chat completion with messages history

* chore: handle abort controllers

* chore: change max attempts setting

* chore: handle stop running models in system monitor screen

* Update web-app/src/services/models.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* chore: format time

* chore: handle stop model load action

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-05-22 20:13:50 +07:00
Emre Can Kartal
e813440332
Update README.md (#5072)
Updated license to Apache 2.0
2025-05-22 17:57:15 +07:00
Louis
570bb8290f
chore: add model information in System Monitoring (#5062)
* chore: add model information in System Monitoring

* chore: handle empty models case

* chore: fix type
2025-05-22 16:07:08 +07:00
Louis
4d66eaf0a7
chore: handle local models chat with MCP (#5065)
* chore: handle local models chat with MCP

* chore: update MCP server connection status in the settings page

* chore: error handling

* chore: normalize message

* chore: update finally block
2025-05-22 16:06:55 +07:00
Faisal Amir
aba75a7d2c
fix: allow dialog triggered by tooltip (#5066) 2025-05-22 15:52:29 +07:00
Faisal Amir
d3c6d7cfaa
enhancement: wrap long line codeblock (#5069) 2025-05-22 15:52:17 +07:00
Faisal Amir
12ad61aaa8
enhancement: show assistant info on message (#5064) 2025-05-22 14:45:58 +07:00
vansangpfiev
2d7d731a76
chore: wildcard for connect-src (#5048)
* chore: wildcard for connect-source

* chore: stricter list of connect-src

* chore: update tauri.conf.json

* chore: update font-src
2025-05-22 14:16:24 +07:00
vansangpfiev
e43b109291
fix: tauri updater (#5051)
* fix: updater

* chore: sync latest nightly

* chore: ignore electron updater config

* chore: upload signatures

* chore: update connect-src

* chore: add log

* chore: correct path macos s3

* fix: close cortex before restarting

* chore: clean

* chore: comment

* Revert "chore: update connect-src"

This reverts commit a592845c0b5293c121fb17671c14bb1f9958bf00.

* chore: update lastest.yml

* chore: cleanup

* chore: stop uploading yml for electron

* chore: linux workflow
2025-05-22 14:16:10 +07:00
Faisal Amir
dde4e97d8b
enhance: setup screen redirect to hub (#5061) 2025-05-22 11:55:34 +07:00
Faisal Amir
434abaaca6
chore: app updater UI (#5054)
* chore: initial app updater UI and download management enhance

* chore: revert package version

* chore: update conditional app updater

* chore: remove console

* chore: add utils isDev

* chore: close popup when user click download

* revert yarn lock
2025-05-22 11:54:06 +07:00
Faisal Amir
a7d2e72313
enhancement: disabled config when server is running (#5058) 2025-05-22 11:07:14 +07:00
Faisal Amir
fab8f0a9c9
Merge pull request #5059 from menloresearch/enhancement/hub-left-panel-collapse
enhancement: update layout hub when left panel collapse
2025-05-22 11:04:21 +07:00
Faisal Amir
bd0d2a5cec
Merge pull request #5057 from menloresearch/feat/assistant-emoji
feat: add assistant emoji picker
2025-05-22 10:56:01 +07:00
Faisal Amir
6a6ccc9a9e
Merge pull request #5055 from menloresearch/enhancement/message-toolbar
enhancement: message toolbar using tooltip
2025-05-22 10:55:28 +07:00
Faisal Amir
81e88f6632
Merge pull request #5060 from menloresearch/feat/app-logs
feat: initial app logs
2025-05-22 10:54:09 +07:00
Faisal Amir
0622106f8e chore: update routes log 2025-05-22 00:51:30 +07:00
Faisal Amir
0c73035b3c feat: initial app logs 2025-05-22 00:46:28 +07:00
Faisal Amir
661e907784 enhancement: update layout hub when left panel collapse 2025-05-22 00:14:16 +07:00
Faisal Amir
80cfd57dbd chore: cleanup unused code 2025-05-21 23:52:30 +07:00
Faisal Amir
974f7901e6 feat: add assistant emoji picker 2025-05-21 23:45:49 +07:00
David
d06526a97e
Merge pull request #5056 from menloresearch/4853-release-jan-v0517
chore: update Jan change logs v0.5.17
2025-05-21 23:14:50 +07:00
David
58f6b061a8 chore: update Jan change logs v0.5.17
chore: update Jan change logs v0.5.17
2025-05-21 23:11:37 +07:00
Faisal Amir
2e5795945b chore: fix slice default model 2025-05-21 22:38:19 +07:00
Faisal Amir
fa1a71cc01 chore: copy update 2025-05-21 22:38:19 +07:00
Faisal Amir
9d5e670344 enhancement: message toolbar using tooltip 2025-05-21 22:38:19 +07:00
Sam Hoang Van
ad962c2cf6
feat(webapp): Replace Fuse.js with Fzf for thread search and enhance highlighting (#5052)
This commit replaces Fuse.js with Fzf for client-side thread searching
within the web application, offering potentially improved performance and
a different fuzzy matching algorithm.

Key changes include:

- Updated `package.json` to remove `fuse.js` and add `fzf`.
- Refactored `useThreads.ts` hook:
    - Replaced Fuse.js instantiation and search logic with Fzf.
    - Integrated a new `highlightFzfMatch` utility to return thread
      titles with HTML highlighting for matched characters.
- Created `utils/highlight.ts` for the `highlightFzfMatch` function.
- Updated `ThreadList.tsx`:
    - Renders highlighted thread titles using `dangerouslySetInnerHTML`.
    - Ensures the rename functionality uses and edits a plain text
      version of the title, stripping any highlight tags.
- Updated `index.css`:
    - Modified the `.search-highlight` class to use `font-bold` and
      `color-mix(in srgb, currentColor 80%, white 20%)` for a
      subtly brighter text effect on highlighted matches, replacing
      previous styling.

This provides a more robust search experience with clear visual feedback
for matched terms in the thread list.
2025-05-21 22:31:01 +07:00
Louis
0627f29059
chore: enable / disable proxy configrations (#5050)
* chore: enable / disable proxy configrations

* Update web-app/src/routes/settings/https-proxy.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update web-app/src/lib/completion.ts

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-05-21 14:18:25 +07:00
Faisal Amir
a7e4037449
Merge pull request #5049 from menloresearch/chore/system-monitor
chore: intial new window system monitor
2025-05-21 13:30:37 +07:00
Faisal Amir
afab839733 chore: seperate function onclick 2025-05-21 12:47:06 +07:00
Sam Hoang Van
4b77548eb9
Fix/thread sorted and drag drop (#5046)
Modified the `onDragEnd` handler in `ThreadList.tsx` to use the complete global thread list from the `useThreads` store. This resolves a bug where dragging and dropping threads could lead to items disappearing from "Favorites" or "Recents" sections by ensuring the reordering logic operates on the full dataset.

Additionally, the default `order: 1` initialization for new threads in `useThreads.ts` and `services/threads.ts` has been commented out this make thread sorted by newest to oldest
2025-05-21 12:42:29 +07:00
Faisal Amir
2812a8978a chore: intial new window system monitor 2025-05-21 12:27:54 +07:00
Louis
6676e0ced8
chore: add relocate jan data folder function to new FE (#5043)
* chore: typo

* fix: linter issues

* chore: fix linter

* chore: fix linter

* chore: add relocate data folder
2025-05-21 10:48:10 +07:00
Faisal Amir
e4168a4c17
Merge pull request #5044 from menloresearch/chore/chat-input-inline-message
chore: add inline message chat input
2025-05-20 23:45:26 +07:00
Faisal Amir
b0a55d63f0
Merge pull request #5045 from menloresearch/chore/import-model-filename
chore: show model name as filename
2025-05-20 23:45:18 +07:00
ethanova
abe265ac71
make the model selector popup responsive and wider for bigger screens (#5025)
* make the model selector popup responsive and wider for bigger screens

* fix linting issue

* use vscode config files to recommend prettier plugin and use it to auto format on save

---------

Co-authored-by: Ethan Garber <ethancgarber@gmail.com>
2025-05-20 22:54:47 +07:00
Faisal Amir
88ea8b0638 chore: show model name as filename 2025-05-20 22:25:40 +07:00
Louis
e8ca7f3c1b
chore: Jan's code is now under the Apache license (#5042) 2025-05-20 22:18:59 +07:00
Faisal Amir
c0cef78ef2 chore: add inline message chat input 2025-05-20 21:36:19 +07:00
Louis
81c4dc516b
chore: handle hardware settings (#5041)
* chore: handle hardware settings

* chore: activate GPUs

* Update web-app/src/services/hardware.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-05-20 20:05:47 +07:00
Faisal Amir
3e887deb3e
Merge pull request #5038 from menloresearch/chore/import-model 2025-05-20 19:12:19 +07:00
David
22298f46a3
Merge pull request #5030 from samhvw8/fix/type-rename-thread
fix: type rename thread
2025-05-20 17:36:22 +07:00
Faisal Amir
c54e8c80b6 chore: model import from llama.cpp provider 2025-05-20 15:48:45 +07:00
vansangpfiev
9fe4dbdb3d
fix: windows installer (#5037) 2025-05-20 15:42:22 +07:00
sam hoang
06ba2f178b chore: update dialog title from "Rename Title" to "Rename Thread" 2025-05-20 14:45:44 +07:00
Faisal Amir
c4d32c72d1
Merge pull request #5035 from menloresearch/chore/data-folder
chore: show location data folder and ui for let user change folder
2025-05-20 14:42:21 +07:00
Faisal Amir
421c24bf4b
Merge pull request #5036 from menloresearch/chore/auto-focus-chat-input
chore: fix auto focus chat input
2025-05-20 14:42:14 +07:00
Louis
d5393e4563
feat: add custom OpenAI provider (#5033)
* feat: add custom OpenAI provider

* chore: add HF token setting

* chore: move HF token setting to llama.cpp provider - later deprecate model extension
2025-05-20 14:30:51 +07:00
Faisal Amir
adc90167d4 chore: fix auto focus chat input 2025-05-20 14:29:44 +07:00
Faisal Amir
4adaeed3da chore: show location data folder and prepare ui for let user change folder 2025-05-20 14:10:49 +07:00
Louis
46943a1cf7
chore: token speed and edit message (#5031)
* chore: add token speed measurement

* chore: add edit message handler

* chore: add DialogClose wrapper around save button
2025-05-20 14:09:25 +07:00
Faisal Amir
76827d42f5
Merge pull request #5032 from menloresearch/chore/model-loading
chore: model loading and truncate dropdown assiatant title
2025-05-20 12:44:51 +07:00
vansangpfiev
d70e20ae0a
chore: enable test on PR to release branch (#5028)
* chore: enable test on PR to release branch

* chore: disable coverage check

* chore: remove verbose build
2025-05-20 12:34:08 +07:00
Faisal Amir
d95439e3f4 chore: update copy 2025-05-20 12:21:30 +07:00
Faisal Amir
ead591d3b8
Merge pull request #5029 from menloresearch/chore/hardware
chore: add setting hardware
2025-05-20 11:30:03 +07:00
Faisal Amir
97728734a7 chore: model loading and truncate dropdown assiatant title 2025-05-20 11:29:18 +07:00
Faisal Amir
ba4d1d3c12 chore: fix typo 2025-05-20 10:49:57 +07:00
Faisal Amir
4c50ebfe0a chore: add setting hardware 2025-05-20 10:43:36 +07:00
vansangpfiev
837d3ab0e3
chore: remove electron nightly/manual (#5027)
* chore: remove electron nightly/manual

* chore: change nightly pull request branch
2025-05-20 10:22:13 +07:00
Louis
b3a6edb704
chore: reduce state update to prevent glitchy scroll to bottom (#5026) 2025-05-20 09:47:40 +07:00
Louis
9047d0df4f
chore: remove unnecessary imports 2025-05-20 09:42:34 +07:00
Faisal Amir
cbad4396cd
Merge pull request #5021 from menloresearch/chore/scroll-bottom-log
chore: scroll to bottom when have new log message
2025-05-20 09:33:12 +07:00
Faisal Amir
7d25bcb168
Merge pull request #5022 from menloresearch/chore/appearance-group
chore: regroup codeblock setting appearance
2025-05-20 09:33:04 +07:00
Louis
2dac53e9ca
feat: Jan supports multiple assistants (#5024)
* feat: Jan supports multiple assistants

* chore: persists current assistant to threads.json

* chore: update assistant persistence

* chore: simplify persistence objects
2025-05-20 00:57:26 +07:00
Louis
f6433544af
feat: handle stop streaming message, scroll to bottom and model loads (#5023) 2025-05-19 23:32:55 +07:00
Faisal Amir
0cc50531f8 chore: regroup codeblock setting appearance 2025-05-19 23:21:19 +07:00
Faisal Amir
fba7529281 chore: scroll to bottom when have new log message 2025-05-19 23:09:55 +07:00
Faisal Amir
b69a9ceb0f
Merge pull request #5020 from menloresearch/chore/cleanup-assistant
chore: add function delete and params type assistant
2025-05-19 22:53:45 +07:00
Louis
28c7e0d105
chore: stream app logs to log window (#5019)
* chore: stream app logs to log window

* chore: remove unused states
2025-05-19 22:51:37 +07:00
Faisal Amir
afb8ff716a chore: add functiond delete and params type assistant 2025-05-19 22:47:57 +07:00
Louis
2ae7417e10
feat: add MCP server connection status (#5018) 2025-05-19 15:17:19 +07:00
vansangpfiev
90da49f873
chore: add some ts-ignore to make tauri build works (#5010)
* chore: add some ts-ignore to make build works

* chore: remove tauri build nightly script

* chore: update core package.json

* chore: fix build

* chore: add devtools for tauri beta, nightly

* chore: change transport-sse to transport-sse-server

* chore: comment out dll files

* chore: add ts-ignore

* chore: update nightly CI
2025-05-19 14:49:03 +07:00
Faisal Amir
1d4af26b5c
Merge pull request #5017 from menloresearch/chore/whitespace-left-panel
chore: cleanup whitespace left panel on thread list
2025-05-19 14:15:42 +07:00
Faisal Amir
1507f220e5 chore: cleanup whitespace left panel on thread list 2025-05-19 13:55:46 +07:00
Faisal Amir
42088c44cb
Merge pull request #5016 from menloresearch/chore/switch-component
chore: improve switch component offset
2025-05-19 13:15:57 +07:00
Louis
2bc8fccaf0
chore: allow users to enable/disable MCP servers (#5015) 2025-05-19 13:15:37 +07:00
Faisal Amir
1ce0480684 chore: improve switch component offset 2025-05-19 13:08:23 +07:00
Thien Tran
16514050b9
chore: Pin rmcp commit (#5014) 2025-05-19 14:07:09 +08:00
Faisal Amir
3dea599b9a
Merge pull request #5013 from menloresearch/feat/assistant-ui
chore: initial assistant feature
2025-05-19 13:01:49 +07:00
Faisal Amir
1c81e5a95e chore: remove lock 2025-05-19 13:00:28 +07:00
Faisal Amir
3fedc9231c
Merge pull request #5012 from menloresearch/chore/cleanup-download-management
chore: cleanup download management
2025-05-19 12:47:18 +07:00
Faisal Amir
1435cd3162 chore: add functional use button when download complete 2025-05-19 12:35:18 +07:00
Faisal Amir
53f5729674 chore: update hub progress download, added toaster 2025-05-19 11:17:16 +07:00
Louis
2345ff172d
chore: update model handlers on the new frontend (#5011)
* chore: provide model handlers to new frontend

* chore: add API server function to the new front end
2025-05-19 10:39:43 +07:00
Louis
74c2c59c90
chore: handle chat functions (#5009) 2025-05-18 20:41:10 +07:00
Louis
c1091ce812
feat: new frontend with model download function (#5008) 2025-05-18 20:00:17 +07:00
Faisal Amir
1b2a29565f
Merge pull request #5007 from menloresearch/chore/empty-state
chore: update empty state thread list, search, and no model
2025-05-18 15:23:09 +07:00
Faisal Amir
bc327c40d4 chore: update empty state thread list, search, and no model 2025-05-18 14:58:15 +07:00
Faisal Amir
314bfb2313
Merge pull request #5005 from menloresearch/feat/setup-screen
chore: initial setup screen for remote provider
2025-05-16 22:20:52 +07:00
Faisal Amir
589de63328
Merge pull request #5004 from menloresearch/feat/tool-use
feat: tool use render UI
2025-05-16 22:20:46 +07:00
Faisal Amir
d57ed85d7e
Merge pull request #4997 from menloresearch/chore/window-dragable
chore: increase hight of drag area window
2025-05-16 22:20:37 +07:00
Faisal Amir
9299e772ba wip: initial setup screen 2025-05-16 22:13:16 +07:00
Faisal Amir
05ce85d9b1 chore: styling tool call funtion render UI 2025-05-16 22:10:27 +07:00
Louis
95f90f601d feat: tool use 2025-05-16 22:10:27 +07:00
Thien Tran
66a4ac420b
chore: delete Tauri pre-install in make clean (#5000) 2025-05-16 15:02:14 +08:00
Thien Tran
4bde6645d0
feat: Download manager for llama.cpp extension (#4933) 2025-05-16 15:01:42 +08:00
Faisal Amir
759d5c7257 chore: increase hight of drag area window 2025-05-16 09:17:06 +07:00
Louis
e9f37e98d1
refactor: remove hardcoded provider names (#4995)
* refactor: remove hardcoded provider names

* chore: continue the replacement
2025-05-15 22:10:43 +07:00
Louis
bf3f22c854
fix: should not spawn many llama.cpp servers for the same model (#4994)
* fix: should not spawn many llama.cpp servers for the same model

* chore: test step placeholder for the new revamp

* chore: coverage check should not fail pipeline
2025-05-15 21:27:41 +07:00
Faisal Amir
852ea84cd8
epic: Jan with new UI/UX (#4964)
* chore: initial new FE setup

* chore: update namespace text-left-panel foreground variable

* chore: enable dynamic mainview color

* chore: remove greetings new chat

* chore: fix chat input style

* chore: simplify hook useAppearance

* chore: enable internationalization

* chore: prepare vn locale

* chore: keyboardshortcut layout

* chore: update keyboard shortcut exclude pathname

* chore: update state active setting route

* chore: fix update theme by system

* chore: handle dynamic primary color

* chore: fix left panel navigation active state and styled item privacy analytic

* chore: reorder general setting being a first

* chore: add function reset appearance

* chore: update scrollbar

* chore: update delete thread with dialog confirmation

* chore: update state dialog inside dropdown menu

* chore: wip thread detail or chat page

* chore: wip model dropdown

* chore: prepare model dropdown select

* chore: update model providers setting

* chore: show provider on model dropdown based isActive toogle

* chore: update layout model provider

* chore: update state active on storage

* chore: update gap of item dropdown model

* chore: update select model base on id

* chore: update edit model capabilities

* chore: add dialog to add model

* chore: update sheet for model setting

* chore: add sheet setting each model

* chore: make dynamic syntax highlight

* chore: fix menu setting appearance theme

* chore: markdown render support emoji

* chore: markdown support latex

* chore: change codeblock default theme

* chore: update ui codeblock

* chore: custom render link taget new window

* chore: fix copy button codeblock

* chore: update accent and desctructive color

* chore: setup user chat message

* chore: prepare some page settings

* chore: simple list extension and prepare mcp, local api, and hardware

* chore: mcp-serve

* chore: MCP server UI

* chore: update local api server config

* chore: adjust chat input

* chore: update local api server log

* chore: prepare hub page

* chore: remove help page

* chore: update mock

* chore: prepare http proxy setting UI

* chore: adjust local api server and title every action

* fix: chore FE package (#4962)

* fix: update command which referred to non-existent web app

* fix: added commented out macos platform for now

* fix: remove the platform name as macos

* fix: remove unnecessary line for platform name in HeaderPage component

* fix: update dev script to specify port 3000 for Vite

* feat: model providers and chat completion

* enhancement: threads performance

* fix: thread content update

* chore: clean up threads

* fix: performance issue with streaming and state loop

* fix: streaming

* fix: react markdow

* feat: extension manager

* chore: add nodePolyfills include path

* chore: improve performance avoid unhandle rejection

* chore: update pre margin bottom

* chore: swith thread should be deafult scroll to bottom

* chore: wip scroll to bottom

* chore: add model loader

* chore: add platform utils

* feat: threads functionality

* chore: setup toaster

* chore: persist threads deletion

* fix: create thread with new message

* chore: create new thread should change route path

* chore: navigate after delet dialog thread

* chore: thread favorites and orders

* chore: dismiss deleting modal on delete

* chore: remove undefined properties

* chore: remove deprecated run step

* chore: fix delete thread

* chore: create empty thread content on started streaming

* chore: correct messages store key

* chore: stuck at generating state

* chore: preapre chat toolbar

* chore: introduce in-memory app state

* chore: update extensions migration logic

* chore: remove redundant extensions migration gate

* chore: message toolbar user and assistant

* chore: add logo gemini

* feat: remote providers with model capabilities

* chore: maintain provider settings

* chore: move speed token into chat input

* chore: temp harcoded model loader

* chore: make chat text selectable and truncate model list

* chore: update shortcut UI

* Feat/implement threads (#4977)

* chore: add fuse.js library for enhanced search functionality

* feat: implement thread filtering with Fuse.js for improved search capabilities

* fix: update the fuseOptions

* feat: add search functionality to LeftPanel and refactor thread retrieval logic

* refactor: optimize thread filtering and improve search functionality in LeftPanel

* fix: more edits

* refactor: remove duplicate import of useAppState in StreamingContent component

* chore: update navigate after delete all thread

* chore: pass prop speedToken from new chat input

* chore: persist provider general settings

* chore: styling search left panel

* chore: cleanup margin

* chore: update size icon

* chore: improve chat input

* chore: imprve list markdown

* chore: animate border

* feat: local model provider work

* chore: persist manually added model

* chore: prepare download management ui and show version on general setting

* chore: improve pre tag

* chore: remove buton install extension and improve light theme download

* chore: add missing hardware information handler

* chore: cleanup small ui

* chore: update default provider settings

* fix: missing fs commands

* chore: correct provider models

* chore: prepare delete model

* chore: handle thinking block

* chore: fix conditional message toolbar

* chore: pophover download select none

* enhancement: add prune mode

* chore: model settings

* chore: bump engine version tauri

* chore: update style thinking

* chore: add indicator and toogle mcp server

* chore: wip hub

* chore: update model settings

* chore: mvp hub

* chore: add function rename title

* chore: update function delete message

* chore: update rename title

* chore: update model settings

* chore: persist MCP configs

* refactor: clean up utils

* chore: add tools to completion request

* chore: clean up

* chore: ignore assets

---------

Co-authored-by: Ivan Leo <ivanleomk@gmail.com>
Co-authored-by: Louis <louis@jan.ai>
2025-05-15 19:38:59 +07:00
Louis
e15a5ab599
Merge pull request #4844 from menloresearch/feat/tauri-build-option
feat: Add Tauri as an Alternative Build Option for Jan
2025-05-15 19:18:05 +07:00
Louis
9063f7e6c4
chore: fix lint 2025-05-15 17:27:46 +07:00
vansangpfiev
2418095656
chore: update CI/CD (#4993)
* chore: updae ci cd
- replace electron beta by tauri beta
- only upload tauri nightly to s3
- remove preview

* chore: ignore electron nightly build

* chore: remove redundant workflows

* chore: add nsis template

* chore: update nsis template

* chore: update cuda url

* chore: bundle bun and uv

* chore: delete binaries folder on uninstalling
2025-05-15 17:11:19 +07:00
vansangpfiev
8fefe6e167
chore: tauri codesign and CI/CD (#4961)
* chore: build tauri

* chore: codesign tauri app

* chore: test update from electron to tauri

* chore: test update from electron to tauri

* chore: update csp config and cors

* chore: nightly to 1317

* fix: correct pre_install_path

* chore: jan-nightly to 1320

* chore: self sign tauri

* chore: CI/CD for Windows, Linux

commit 4897b2bcf7f044080fce81bd725515e62fc4eb29
Author: vansangpfiev <vansangpfiev@gmail.com>
Date:   Fri Apr 25 15:32:37 2025 +0700

    chore: cleanup tauri config

commit 66c5676ec146b25c89cccb570ede7c070dbc5853
Author: vansangpfiev <vansangpfiev@gmail.com>
Date:   Fri Apr 25 14:37:04 2025 +0700

    fix: store path

commit bc6560c576873e55f84c4b21764bedbdd9dbd5a8
Author: vansangpfiev <vansangpfiev@gmail.com>
Date:   Thu Apr 24 09:39:50 2025 +0700

    chore: Linux CI

commit b036275dc9f1df7614aaca3b358b9c6493082512
Author: vansangpfiev <vansangpfiev@gmail.com>
Date:   Wed Apr 23 16:41:22 2025 +0700

    chore: updater windows

commit e91b543dbdd82bd4a44db7550ffb993897b56081
Merge: dea80a83 4a54a378
Author: vansangpfiev <vansangpfiev@gmail.com>
Date:   Wed Apr 23 16:39:24 2025 +0700

    Merge branch 'chore/tauri-cicd' of https://github.com/menloresearch/jan into chore/tauri-cicd-windows

commit dea80a83966113b108137c385a3c28920d2adda4
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Wed Apr 23 11:47:04 2025 +0700

    chore: update azuresigntool install method

commit 2ec2234082be57e53887192153fa982a134ea535
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Wed Apr 23 11:01:31 2025 +0700

    chore: add verbose option build tauri and targets app and dmg for macos build

commit 42c7592cc89641130545551d4d864268cde3d5b0
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Wed Apr 23 10:35:27 2025 +0700

    chore: update targets build

commit 4c8ba44ff60cdef8b639fa189f5729dc69c5aff6
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Wed Apr 23 09:53:21 2025 +0700

    refactor: remove debug step and upload electron build artifact

commit 158c08b465e18823e0f2b9a30fd5ecd589d08934
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Wed Apr 23 09:21:08 2025 +0700

    chore: add script codesign on windows

commit 4545b2bcd852029472298e530176494992dd0950
Author: vansangpfiev <vansangpfiev@gmail.com>
Date:   Tue Apr 22 13:39:49 2025 +0700

    chore: update csp setting

commit f64a1e1ca958e3c1c685485a06d45956ddcf14a0
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Tue Apr 22 10:15:14 2025 +0700

    chore: update azuresigntool installation

commit 1f4b9d18b332d5205685a6fe68f5dfaf973d273c
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Tue Apr 22 09:49:42 2025 +0700

    chore: update signcommand

commit 911a3ab3540f872f6fe906c8e2135440d39f108c
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Mon Apr 21 19:19:23 2025 +0700

    chore: update codesign tauri windows

commit fba15c4c2de43b4cb87308ef998cdd8dc88b1ce6
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Mon Apr 21 19:04:29 2025 +0700

    chore: update path azuresigntool

commit 8b8c950b56f5aa42baf76aba064fc99b50758150
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Mon Apr 21 18:38:56 2025 +0700

    chore: update azuresigntool path

commit bd67a2b7908b5f3a126c634a840e0b941373a3c6
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Mon Apr 21 17:47:33 2025 +0700

    chore: update azuresigntool url

commit f70effca7c09cd2fe9b5866b4f194b64a13294b9
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Mon Apr 21 17:33:32 2025 +0700

    chore: update azuretoolsign download

commit 667910772f30369b9afa554ad06e4378f93d0b1a
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Mon Apr 21 16:56:25 2025 +0700

    chore: update path azuresigntool

commit f1610bfd80dfa996db4a777bb58475f2e6d02cc6
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Mon Apr 21 16:52:36 2025 +0700

    chore: update azuresigntool path

commit 0873d56fb88fb66c884eff31d3f63aa99858f038
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Mon Apr 21 16:19:46 2025 +0700

    chore: add debug step

commit 88e0b1a697ed478375429686eb1c03ae71a3b447
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Mon Apr 21 15:58:39 2025 +0700

    ci(windows): download AzureSignTool to src-tauri for Tauri code signing

commit 47f94e86589826c3941a3d602298f188d6480980
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Mon Apr 21 15:21:20 2025 +0700

    fix: AzureSignTool signcommand Path

commit dc014a7905fd0b49b5972e24b4d5773c5dc29ea5
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Mon Apr 21 15:00:02 2025 +0700

    chore: add debug step azuresigntool tauri windows

commit ee7b6163a8419604dfba7dc2f967026be4884da4
Author: Minh141120 <minh.itptit@gmail.com>
Date:   Mon Apr 21 14:33:33 2025 +0700

    chore: tauri windows codesign

commit 6607090857120531d8a096f45ff556c3f2553e53
Author: vansangpfiev <vansangpfiev@gmail.com>
Date:   Thu Apr 17 10:29:50 2025 +0700

    chore: add windows download script

commit 4b1a5cc29c77eecca75978a1ab3126d2c710e738
Author: Nguyen Ngoc Minh <kuuhakuu@Nguyens-MacBook-Air.local>
Date:   Mon Apr 21 13:44:34 2025 +0700

    chore: tauri codesign windows

* chore: workflows for tauri

* chore: test tauri manual build

* chore: hide windows install detail

* chore: upload artifacts

* feat: run mcp with bundled bun and uv

* chore: clean up

* chore: update cicd

* chore: remove deprecated workflows

* chore: update allowed origins

* chore: pull binaries windows, linux (#4963)

* fix: get bun and uv from execution path

* fix: macos

* fix: typo

* fix: remove old Jan binaries on windows

* chore: build bun and uv universal

* fix: appimage bundle bun issue

* chore: libfuse2 for linux CI

* feat: tauri cicd preview (#4975)

* feat: tauri cicd preview

* chore: add suffix preview for tauri build

* chore: update condition for s3 upload nightly channel

* chore: add debug step for tauri macos preview

* chore: update aws s3 macos tauri build

* refactor: remove debug code

* chore: update artifact name tauri macos build

* chore: add tauri build step for electron beta and stable

* chore: update preview

* chore: bump llama.cpp engine to b5351

* chore: bump engine version

* fix: cors windows

---------

Co-authored-by: vansangpfiev <sang@jan.ai>
Co-authored-by: Service Account <service@jan.ai>
Co-authored-by: Louis <louis@jan.ai>
Co-authored-by: hiento09 <tominhhien97@gmail.com>
Co-authored-by: Nguyen Ngoc Minh <91668012+Minh141120@users.noreply.github.com>
2025-05-15 17:11:19 +07:00
vansangpfiev
b8b0a77e88
fix: add execution permission for bun and uv (#4990)
* fix: add execution permission for bun

* fix: add execution permission for uv
2025-05-15 17:11:19 +07:00
Thien Tran
dc23cc2716
Use token.js for non-tools calls (#4973)
* deprecate inference()

* fix tool_choice. only startModel for Cortex

* appease linter

* remove sse

* add stopInferencing support. temporarily with OpenAI

* use abortSignal in token.js

* bump token.js version
2025-05-15 17:11:19 +07:00
Louis
dbe7ef65e2
fix: download script should be mjs format 2025-05-15 17:11:18 +07:00
Thien Tran
6ed5d44258
[feat] Download bun+uv on make dev-tauri (#4981)
* only download if not exist

* add download:bin to dev-tauri
2025-05-15 17:11:18 +07:00
Louis
52ac14ad06
feat: run mcp with bundled bun and uv (#4949)
* feat: run mcp with bundled bun and uv

* chore: clean up

* chore: pull binaries windows, linux (#4963)

* fix: get bun and uv from execution path

* fix: macos

* fix: typo

---------

Co-authored-by: vansangpfiev <vansangpfiev@gmail.com>
2025-05-15 17:11:18 +07:00
vansangpfiev
dea29ff8c4
fix: Jan supports cortex with llama-server (#4904)
* fix: update logic to pull llama-cpp engine

* chore: bump cortex version

* fix: chat macos

* chore: bump llama.cpp

* chore: download windows

* chore: download linux

* chore: bump cortex to 1.0.13-rc6

* fix: stop cortex before exit

* chore: bum llama.cpp engine to b5350

---------

Co-authored-by: vansangpfiev <sang@jan.ai>
2025-05-15 17:11:18 +07:00
Louis
f3a808cb89
feat: simplify remote providers and tool use capability (#4970)
* feat: built-in remote providers go to tokenjs

* fix: error handling

* fix: extend models

* chore: error handling

* chore: update advanced settings of built-in providers

* chore: clean up message creation

* chore: fix import

* fix: engine name

* fix: error handling
2025-05-15 17:10:58 +07:00
Louis
7748f0c7e1
fix: local model run 2025-05-15 17:10:58 +07:00
Louis
5c88cedaf0
enhancement: automatically update MCP tool list UI on server change (#4940)
* enhancement: automatically update MCP tool list UI on server change

* enhancement: tool call block fit content
2025-05-15 17:10:58 +07:00
Louis
946e8dda65
Merge pull request #4942 from menloresearch/enhancement/mcp-servers-search-cache-results
enhancement: cache MCP Server search results to enhance UX
2025-05-15 17:10:58 +07:00
vansangpfiev
aefe9cc23a
chore: add windows download script (#4916) 2025-05-15 17:10:57 +07:00
Louis
89c095094f
chore: simplify assistant name 2025-05-15 17:10:57 +07:00
Louis
7edb987cbd
fix: glitchy UI when hover last message 2025-05-15 17:10:57 +07:00
Louis
a81b644a8f
enhancement: tool call block should be wrapped in a collapsible scroll area 2025-05-15 17:10:56 +07:00
Louis
1630e2eb77
feat: allow users to enable and disable tools 2025-05-15 17:10:56 +07:00
Louis
5e80587138
chore: button css 2025-05-15 17:10:56 +07:00
Louis
e1995a3ccb
feat: permission dialog for tool call requests 2025-05-15 17:10:56 +07:00
Faisal Amir
1a3cc64a7e
fix: prevent curly quotes from mcp config 2025-05-15 17:10:55 +07:00
Louis
9c1f0f8a33
chore: should not block users from creating new threads 2025-05-15 17:10:55 +07:00
Louis
92d7e33b7e
fix: thread title does not set on remote models 2025-05-15 17:10:55 +07:00
Louis
eda0d639f0
fix: clean up threads persistence and fix assistant update issue 2025-05-15 17:10:55 +07:00
Louis
c4ae61dd75
fix: tool outputs are gone after switching to another thread 2025-05-15 17:10:54 +07:00
Louis
19146fec6a
feat: restart MCP servers to reflect config updates (#4917) 2025-05-15 17:10:54 +07:00
Faisal Amir
efea4ebb59
chore: update tab setting 2025-05-15 17:10:54 +07:00
Faisal Amir
c0b9e8eb77
chore: update UI mcp settings 2025-05-15 17:10:53 +07:00
Louis
80d11e1057
chore: add mcp write and read commands 2025-05-15 17:10:53 +07:00
Faisal Amir
72cb1c16cc
chore: setting mcp 2025-05-15 17:10:53 +07:00
Faisal Amir
d60967b4f7
chore: initial commit mcp setting 2025-05-15 17:10:53 +07:00
Louis
6f53f1056a
refactor: Jan manages threads for a better performance (#4912)
* refactor: Jan manages threads for a better performance

* test: add tests
2025-05-15 17:10:52 +07:00
Louis
f8144a73c1
chore: missing import 2025-05-15 17:10:52 +07:00
Louis
ea88b27593
Merge pull request #4900 from menloresearch/feat/jan-ui-with-tool-use
feat: jan UI with Tool use UX
2025-05-15 17:10:51 +07:00
Faisal Amir
e285f622bb
chore: enable window effect blur tauri 2025-05-15 17:10:22 +07:00
Louis
0b26647d94
chore: mcp supports env 2025-05-15 17:10:22 +07:00
Faisal Amir
9463ab4491
chore: exclude lock file 2025-05-15 17:10:22 +07:00
Louis
cfc49c10ca
chore: fix tests 2025-05-15 17:10:21 +07:00
Louis
8eb92e4291
refactor: remove FS call from frontend - remove any casting 2025-05-15 17:10:21 +07:00
Louis
3173328396
chore: differentiate debug and release logging destination 2025-05-15 17:10:21 +07:00
Louis
baee71dd8e
refactor: app logging - script-src access in release 2025-05-15 17:10:21 +07:00
Louis
52290f9ee5
chore: app updater 2025-05-15 17:10:21 +07:00
Louis
ed85ecb1e1
refactor: clean up assistant extension to remove node modules 2025-05-15 17:10:20 +07:00
Louis
1027059a6b
refactor: remove lagecy tools 2025-05-15 17:10:20 +07:00
Louis
cc90c1e86e
chore: tool type 2025-05-15 17:10:20 +07:00
Louis
72a7157509
feat: Jan Tool Use - MCP frontend implementation 2025-05-15 17:10:20 +07:00
Louis
24cafa2d30
chore: clean up 2025-05-15 17:10:20 +07:00
Louis
8f0b7dc87c
chore: clean up generated assets 2025-05-15 17:10:20 +07:00
Louis
05857e85f0
chore: clean up 2025-05-15 17:10:19 +07:00
Louis
cdd5515a98
chore: clean up 2025-05-15 17:10:19 +07:00
Louis
8d97e37985
refactor: clean up 2025-05-15 17:10:19 +07:00
Louis
9467834c29
chore: improve startup time 2025-05-15 17:10:19 +07:00
Louis
726bf4d333
chore: add tests 2025-05-15 17:10:19 +07:00
Louis
4f7af0a10d
feat: Jan supports MCP as a client host 2025-05-15 17:10:18 +07:00
Louis
f4c5b95ba2
chore: ignore lock files - bring back required assets 2025-05-15 17:10:18 +07:00
Louis
66decbca84
refactor: remove generated assets 2025-05-15 17:10:02 +07:00
Louis
b3c109f3a4
chore: add make step to run tauri dev 2025-05-15 17:10:02 +07:00
Louis
e9d1731781
refactor: proxy server and clean up 2025-05-15 17:10:02 +07:00
Louis
a85a98f295
chore: fix tests 2025-05-15 17:10:01 +07:00
Louis
68d7dec23b
chore: maintain electron build 2025-05-15 17:10:01 +07:00
Louis
a0c00d660e
chore: fix tests 2025-05-15 17:10:01 +07:00
Louis
53c05bc561
chore: copy resources on build 2025-05-15 17:10:01 +07:00
Louis
c65a8fde0c
chore: update tests 2025-05-15 17:10:00 +07:00
Louis
c597cb6af6
chore: bump cortex with cors fix 2025-05-15 17:10:00 +07:00
Louis
fc521ecda9
feat: extensions versioning 2025-05-15 17:10:00 +07:00
Louis
cb6261e4d1
chore: update app icon 2025-05-15 17:10:00 +07:00
Louis
dfbeb553b3
chore: kill sidecar process on exit 2025-05-15 17:10:00 +07:00
Louis
27e85010d4
chore: fix fs api 2025-05-15 17:09:59 +07:00
Louis
eed0db00fd
chore: allow shell open default browser 2025-05-15 17:09:59 +07:00
Louis
f0487bea8a
refactor: setup extensions, engines and sidecar 2025-05-15 17:09:59 +07:00
Louis
520a0d04ea
chore: clean up logs opening 2025-05-15 17:09:59 +07:00
Louis
85389aec68
chore: update native apis 2025-05-15 17:09:59 +07:00
Louis
9079067332
chore: factory reset works 2025-05-15 17:09:58 +07:00
Louis
24b8a1b66a
chore: simplify themes and assistants 2025-05-15 17:09:58 +07:00
Louis
27beb46801
feat: tauri toolkit 2025-05-15 17:09:58 +07:00
Louis
154e0cba47
fix: should not normalize user input content (#4985) 2025-05-14 12:17:47 +07:00
Louis
b64749b4bb
fix: distinguish between hub and models search (#4989)
* fix: distinguish between hub and models search

* chore: refresh models hub when going to hub screen
2025-05-14 12:08:33 +07:00
David
db43008813
fix: border for the search box in my models (#4987) 2025-05-14 11:48:18 +07:00
David
8d8703bedf
Merge pull request #4986 from menloresearch/4923-chore-jan-can-use-all-latest-remote-models-april-20-2025
fix: update remote models list
2025-05-14 08:47:13 +07:00
David
29a53a5747 fix: update remote models list 2025-05-13 23:36:52 +07:00
Louis
dc9750ecb4
chore: my models search box css issue (#4984) 2025-05-13 21:28:17 +07:00
Louis
75d3dd2de0
fix: qwen3 - weird token output - reasoning content should not be in completion request (#4983)
* fix: qwen3 - weird token output  - reasoning content should not be in completion request

* chore: bump engine version to llama.cpp b5219
2025-05-13 21:08:16 +07:00
Faisal Amir
57e0707850
Merge pull request #4979 from menloresearch/blog/qwen3
chore: qwen3 blog
2025-05-12 10:35:23 +07:00
Faisal Amir
9fe7a5797f chore: qwen3 blog 2025-05-12 10:24:05 +07:00
hiento09
869b89c78d
chore: fix headers (#4958)
Co-authored-by: Service Account <service@jan.ai>
2025-05-02 20:56:33 +07:00
Ramon Perez
86b2a64c70
Merge pull request #4943 from menloresearch/ramon/docs-improvements-2
Enhanced wording on the installation pages, the data folder and the privacy section.
2025-04-25 01:38:06 -04:00
Ramon Perez
ebcd75af48 Enhanced the wording on the installation pages, the data folder and privacy section 2025-04-24 15:37:40 -04:00
David
0eb6a80d83
Merge pull request #4937 from menloresearch/4932-chore-refactor-doc-httpsjanaiabout
chore: fix jan about doc
2025-04-24 16:39:23 +07:00
David
5b21853e8b chore: fix jan about doc 2025-04-23 15:10:13 +07:00
Nguyen Ngoc Minh
8e5ce1e188
ci: add condition pr labelling job for forked repo (#4934) 2025-04-23 13:40:46 +07:00
Ramon Perez
c068b152b0
Merge pull request #4930 from menloresearch/ramon/docs-improvements
Enhanced the wording on the overview and the quickstart pages.
2025-04-22 10:36:02 -04:00
Ramon Perez
642931bb0a Enhanced the wording on the overview and the quickstart pages. 2025-04-21 12:01:03 -04:00
Akarshan Biswas
cfdd2f0cf8
fix: llama.cpp repo url in readme (#4921) 2025-04-18 14:51:51 +07:00
David
535f2b4de1
Merge pull request #4826 from emeric-martineau/dev
fix: "GPU Acceleration" section missing after enabling Experimental Mode since version 0.5.15
2025-04-14 00:36:00 +07:00
mimic
6b89e5cc48 fix: "GPU Acceleration" section missing after enabling Experimental Mode since version 0.5.15 2025-04-13 18:20:34 +02:00
David
21984afa1b
Merge pull request #4856 from menloresearch/origin/chore/update-jan-doc-remove-workflow
chore: remove workflow automation
2025-04-07 16:44:32 +07:00
David
7a84732682
Merge pull request #4851 from menloresearch/origin/chore/update-jan-doc
chore: update jan doc v0.5.16
2025-04-04 21:30:16 +07:00
Lại Tuấn Anh
bcc9f74607
fix: use more appropriate html tag for 'ModelDropdown' trigger and 'Settings' button (#4841) 2025-03-31 14:39:48 +07:00
Lại Tuấn Anh
5d9dd92625
fix: main-chat-page: warnings from React (#4855)
* fix/home-page: warnings from React

* minor changes

* minor changes

* update electron/package.json
2025-03-31 14:39:20 +07:00
david
d932960323 chore: remove workflow automation 2025-03-28 00:09:46 +07:00
david
697bb47664 chore: update jan doc v0.5.16 2025-03-27 09:29:26 +07:00
Faisal Amir
ebf4951597
Merge pull request #4836 from menloresearch/feat/changelog-v0.5.16
chore: Update Changelogs for v0.5.15 and v0.5.16
2025-03-24 22:37:28 +07:00
Emre Can Kartal
cd4be34559
Merge branch 'dev' into feat/changelog-v0.5.16 2025-03-24 12:32:00 +03:00
Faisal Amir
b9800ff6cc
Merge pull request #4838 from menloresearch/chore/rmv-attr-homebrew
chore: remove attribute Homebrew
2025-03-24 15:36:51 +07:00
Faisal Amir
912db293d4 chore: remove attribute homebrew 2025-03-24 15:24:48 +07:00
Siddhartha Shrestha
3ce6b30887
Merge pull request #4766 from sdhrt/settings-sidebar
fix: show settings sidebar panel when chat sidebar is closed
2025-03-24 13:47:03 +07:00
eckartal
c1871da1de docs: update changelogs for v0.5.15 and v0.5.16 with new features and security fixes 2025-03-24 09:12:10 +03:00
Louis
9d64e9bef4
chore: merge release/v0.5.16 into dev (#4833)
* chore: bump cortex 1.0.11-rc10

* chore: bump to latest cortex release

* feat: Cortex API Authorization

* chore: correct CI CD repo name

* chore: correct new menloresearch repo name

* feat: rotate api token for each run (#4820)

* feat: rotate api token for each run

* chore: correct github repo url

* chore: correct github api url

* chore: should not filter out models first launch

* chore: bump cortex release

* chore: should get hardware information on launch (#4821)

* chore: should have an option to not revalidate hardware information

* chore: cortex.cpp gpu activation could cause a race condition (#4825)

* fix: jan beta logo displayed in jan release (#4828)

---------

Co-authored-by: David <davidpt.janai@gmail.com>
Co-authored-by: Nguyen Ngoc Minh <91668012+Minh141120@users.noreply.github.com>
2025-03-24 11:53:30 +07:00
Ashley
eacae5f17a
Update Hub images (#4710) 2025-03-24 11:27:06 +07:00
Nguyen Ngoc Minh
0f9269a1ed
fix: jan logo beta (#4827) 2025-03-21 22:45:24 +07:00
Faisal Amir
52f1fe85e5
Merge pull request #4815 from menloresearch/chore/menloresearch
chore: janhq to menloresearch
2025-03-20 19:24:16 +07:00
Faisal Amir
33055b8db6 chore: janhq to menloresearch 2025-03-18 13:06:17 +07:00
Louis
39e5649454
fix: clear logs should not delete the folder (#4806) 2025-03-13 23:49:35 +08:00
Faisal Amir
74f6682263
Merge pull request #4805 from janhq/fix/ui-minor-issue
fix: minor ui issue
2025-03-13 19:18:36 +07:00
Faisal Amir
9e9f685eca chore: fix padding 2025-03-13 13:47:36 +07:00
Faisal Amir
6def8193cb fix: scroll setting preferences 2025-03-13 13:45:48 +07:00
Faisal Amir
24e301854c fix: minor ui issue 2025-03-13 11:39:13 +07:00
David
6e0e33dbd0
Merge pull request #4802 from janhq/chore/correct-cohere-response-template
chore: correct cohere response template
2025-03-12 21:29:22 +07:00
Louis
c0f4517c34
chore: bump llama.cpp to support gemma3 2025-03-12 22:11:43 +08:00
Louis
a84f10cba2
chore: correct cohere response template 2025-03-12 16:03:23 +07:00
Faisal Amir
a3b2ce25ea
Merge pull request #4800 from janhq/fix/update-career-url
fix: update career url
2025-03-12 12:18:49 +07:00
Faisal Amir
8985926b9a fix: update career url 2025-03-12 11:59:01 +07:00
David
216dbf6ba0
Merge pull request #4798 from janhq/chore/do-not-symlink-engine-on-linux
chore: do not symlink engine on linux
2025-03-11 23:45:04 +07:00
Louis
3c4afea5c7
chore: do not symlink engine on linux 2025-03-11 21:42:33 +07:00
Faisal Amir
cce52f012c
Merge pull request #4795 from janhq/enhancement/selected-model
enhancement: add checkmark selected model
2025-03-11 21:26:27 +07:00
Faisal Amir
72c484ea8d
Merge pull request #4797 from janhq/fix/table-markdown
fix: table markdown
2025-03-11 16:52:41 +07:00
Faisal Amir
a7c3cbec55 fix: table markdown 2025-03-11 15:57:19 +07:00
David
3e6bccdc9c
Merge pull request #4796 from janhq/fix/hub-desc-render
fix: hub model list desc render
2025-03-11 15:29:03 +07:00
Faisal Amir
ab2c6a87cc chore linter 2025-03-11 15:13:55 +07:00
Faisal Amir
ba736d264b fix: render desc hub model list 2025-03-11 15:13:23 +07:00
Faisal Amir
f2b1d68ab1 enhancement: add checkmark selected model 2025-03-11 14:49:27 +07:00
David
c000f75593
Merge pull request #4794 from janhq/fix/appimage-could-not-load-model
fix: app image - could not load model
2025-03-11 13:42:47 +07:00
Louis
f4f4d411aa
chore: bump cortex version (#4793) 2025-03-11 13:42:42 +07:00
Louis
580cf5d38f
fix: app image - could not load model 2025-03-11 13:30:24 +07:00
Faisal Amir
2a2adf2223
Merge pull request #4792 from janhq/fix/ui-issue
fix: Hub UI issue render readme
2025-03-11 12:42:29 +07:00
Faisal Amir
60514ac56d fix: result search scrollable 2025-03-11 11:16:34 +07:00
David
e98f303d9b
Merge pull request #4791 from janhq/fix/cohere-response-template
fix: cohere response template correction for proper markdown parsing
2025-03-11 11:04:46 +07:00
Faisal Amir
3bf88a3da1 chore: fix linter 2025-03-11 11:01:13 +07:00
Faisal Amir
8844046b19 fix: hub UI issue render readme 2025-03-11 11:00:47 +07:00
Louis
55aa045991
fix: cohere response template correction for proper markdown parsing 2025-03-11 10:11:34 +07:00
Faisal Amir
abfbb2616c
fix: image preview overlap toolbar message (#4790) 2025-03-10 16:36:30 +07:00
David
074992dcd1
Merge pull request #4789 from janhq/fix/anthropic-response-template
fix: anthropic response template correction
2025-03-10 15:49:11 +07:00
Louis
ba282d637e
fix: anthropic response template correction 2025-03-10 15:23:15 +07:00
Louis
455d320d35
fix: engine version update - cortex version bump - update tests (#4787) 2025-03-10 13:26:48 +07:00
Faisal Amir
77717a780e
analytics: integrate posthog into Jan web (#4788) 2025-03-10 12:23:53 +07:00
Louis
4f7a8d58ca
refactor: clean up legacy vision model settings (#4777) 2025-03-06 09:53:31 +07:00
Nguyen Ngoc Minh
8dc30dd047
fix: naming nightly and beta build (#4779)
* fix: naming nightly and beta build

* chore: enhance replace icons for beta and nightly build logic

* chore: update icon linux build

* chore: add debug step

* chore: remove specific icon linux build
2025-03-05 20:30:57 +07:00
Louis
b0deeed937
chore: sync initial hub models (#4778)
* chore: sync initial hub models

* fix: openai request template
2025-03-04 22:33:19 +07:00
Louis
3168ce7016
chore: bump cortex version to fix model sources issue (#4775) 2025-03-04 09:20:25 +07:00
Faisal Amir
c4cccc1574
fix: quickask ui color and alignment on mymodel list (#4774)
* fix: quickask ui color and alignment on mymodel list

* fix: color scheme quickask
2025-03-04 00:09:29 +07:00
Louis
a8aa938f42
refactor: clean up deprecated components and events (#4769) 2025-03-03 22:20:39 +07:00
Faisal Amir
c79c10c96b
fix: list space styled and hidden message toolbar when editmode (#4773) 2025-03-03 20:42:07 +07:00
Louis
889ab953e0
fix: image upload button does not work - refresh models list persist current selected engine (#4768) 2025-03-03 11:37:58 +07:00
David
45f957475d
Merge pull request #4763 from janhq/chore/correct-channel-name-to-ask-for-help-model-troubleshooting
fix: correct jan discord channel
2025-03-03 08:47:21 +07:00
David
e376e8e1f9
Merge pull request #4764 from janhq/feat/add-openai-gpt45preview-anthropic-sonnet37
feat: add openai 4.5 preview and anthropic claude 3.7 sonnet models
2025-03-03 08:46:49 +07:00
Minh
fb93226aff feat: add openai 4.5 preview and anthropic claude 3.7 sonnet models 2025-03-01 00:31:17 +07:00
David
fb196139b2
Merge branch 'dev' into chore/correct-channel-name-to-ask-for-help-model-troubleshooting 2025-02-28 22:51:42 +07:00
Minh
bc48e99650 fix: correct jan discord channel 2025-02-28 22:49:10 +07:00
David
31edf0d315
Merge pull request #4762 from janhq/fix/conversation-messages-padding
fix: first message padding is off
2025-02-28 21:40:24 +07:00
Louis
7d7d343de1
fix: first message padding is off 2025-02-28 21:23:11 +07:00
Louis
dda0feb548
fix: Jan Quick Ask window capture input issues (#4758) 2025-02-28 16:50:08 +07:00
Faisal Amir
b4ba76aa71
chore: handle list number and disc readme hgf (#4756)
* chore: handle list number and disc readme hgf

* chore: fix space hover message toolbar

* chore: handle reset state filter hub revamp
2025-02-28 09:49:08 +07:00
Matt
7fef7b16f7
typo fix (#4748) 2025-02-28 09:31:05 +07:00
Louis
ad1765cd3f
fix: deeplink does not work sometime (#4755)
* fix: deep link does not work sometime and reduce redundant request

* chore: bump cortex fix
2025-02-27 21:02:43 +07:00
Faisal Amir
250d30d73a
chore: hub UI tooltip filter, max model size and search result (#4753)
* chore: fix hub ui tooltip, max-filter, and search result

* chore: fix linter
2025-02-27 15:31:11 +07:00
Louis
f586c19951
chore: correct model author with new cortexso update (#4754) 2025-02-27 15:08:38 +07:00
Louis
5682aa3a7e
fix: some endpoints are invisible (#4752) 2025-02-27 15:08:21 +07:00
Faisal Amir
b849fcb493
fix: app check available update (#4751) 2025-02-27 11:28:15 +07:00
Faisal Amir
aa26e45c22
fix: cannot click dropdown appearance (#4750) 2025-02-27 11:28:07 +07:00
Louis
6a0fb09610
fix: correct default engine variant setup on first launch (#4747)
* fix: there is a case where app selects incorrect engine variant first launch

* refactor: clean up legacy settings hook
2025-02-27 09:03:01 +07:00
Faisal Amir
ecb14b3621
enhancement: receommended label engine variant (#4740) 2025-02-26 19:07:25 +07:00
Faisal Amir
f0ad526aa9
fix: hub button download (#4742)
* fix: hub button download and use

* chore: fix linter

* fix: remove the button download on top of model page
2025-02-26 19:07:06 +07:00
Faisal Amir
36a14600ee
fix: hub ui no result search found (#4739) 2025-02-26 19:06:46 +07:00
Louis
d7329c7719
chore: remove hard coded recommendation models and use cortexso featured tags (#4741)
* chore: remove hard coded recommendation models and use cortexso featured tags

* chore: polish model detail page

* chore: fix test
2025-02-26 15:54:06 +07:00
Louis
916b28044d
fix: onboarding screen should show persisted cloud providers (#4738) 2025-02-26 14:29:36 +07:00
Faisal Amir
053604ec28
fix: chat body scrollbar (#4737)
* fix: chat body scrollbar

* chore: update lock file

* fix: remove PluggableList
2025-02-26 13:23:03 +07:00
Faisal Amir
a4368cf26e
enhancement: improve chat thread (#4736)
* enhancement: improve chat thread

* chore: fix linter

* fix: linter

* chore: fix linter

* fix: chore failed test
2025-02-26 09:42:31 +07:00
David
c7f5d68a39
Merge pull request #4733 from janhq/chore/correct-channel-name-to-ask-for-help
chore: correct channel name to ask for help
2025-02-25 18:08:21 +07:00
Faisal Amir
51f8c96a57
chore: update hub UI (#4734)
* chore: update hub ui based feedback

* chore: update hub ui

* chore: code block ui

* chore: update bg color

* chore: decrease margin codeblock
2025-02-25 14:37:15 +07:00
Faisal Amir
99f324286b
fix: flow app updater manual check from native menu (#4731) 2025-02-25 13:45:45 +07:00
Minh
fc4c567395 chore: correct channel name to ask for help 2025-02-25 13:07:55 +07:00
Louis
b990b259bc
refactor: clean up legacy predefined models (#4730)
* refactor: clean up legacy predefined models

* chore: fix onboarding filtered models
2025-02-25 12:40:37 +07:00
Faisal Amir
2ea8083ad7
enhancement: scrollbar setting options (#4726)
* enhancement: scrollbar setting options

* chore: fix linter
2025-02-25 09:37:04 +07:00
Louis
81fea5665b
chore: enhance onboarding screen's models (#4723)
* chore: enhance onboarding screen's models

* chore: lint fix

* chore: correct lint fix command

* chore: fix tests
2025-02-25 09:36:55 +07:00
Louis
60257635ad
fix: should not select vulkan by default when there are Nvidia GPUs detected (#4720) 2025-02-24 18:51:22 +07:00
Louis
2d7dd8e8ce
chore: fix model hub sorting (#4722)
* chore: fix model hub sorting

* chore: linter fix
2025-02-24 15:23:06 +07:00
Faisal Amir
2e9cca376c
enhancement: update pexelated icon on windows platform (#4721) 2025-02-24 13:53:39 +07:00
Louis
bc2f382e64
chore: migrate engine settings on update (#4719)
* chore: migrate engine settings on update

* chore: queue engine migration to ensure it only execute when server is on

* chore: ensure queue is empty instead of running in the queue
2025-02-24 11:29:11 +07:00
Louis
18e289e8f7
chore: sticky model hub filter panel (#4715) 2025-02-21 18:10:21 +07:00
Louis
cfc6734702
feat: Jan Model Hub filter options and responsiveness (#4714)
* feat: Jan Model Hub filter options and responsiveness

* chore: fix display unit

* chore: fix optional wrapping

* chore: correct joi component's test
2025-02-21 16:32:27 +07:00
Nguyen Ngoc Minh
1b4a91ba7e
chore: update pipeline change app logo for build nightly (#4709)
* chore: change app logo for build nightly

* chore: add nightly option to rename icons

* chore: add rename icons for nightly and beta build

* chore: remove rename icons job
2025-02-21 14:16:15 +07:00
Louis
c5a5e55afe
fix: should disable start model button when there is a model is loading (#4713) 2025-02-21 01:05:17 +07:00
Louis
a47942d7df
chore: streaming should be turned on by default (#4712) 2025-02-21 00:52:07 +07:00
Louis
cddaf61c99
feat: preserve token speed in the thread (#4711)
* feat: preserve token speed in the thread

* chore: lint fix
2025-02-21 00:45:11 +07:00
Louis
fddb7251fb
feat: Jan Model Hub should stay updated. (#4707)
* feat: Jan Model Hub should stay updated.

* chore: polish provider description
2025-02-20 23:25:03 +07:00
Nguyen Ngoc Minh
839a00127d
Merge pull request #4708 from janhq/chore/change-app-logo
chore: change app logo for jan beta and nightly version
2025-02-20 21:39:41 +07:00
Minh141120
bd7113aa74 chore: change app logo for jan beta and nightly version 2025-02-20 21:32:20 +07:00
Louis
badc632ee4
refactor: different Jan builds should have different Cortex server port (#4699)
* refactor: different Jan instances should have different Cortex server port configurations

* chore: update workflow to use env input

* chore: update env for cortex port setting
2025-02-20 15:53:16 +07:00
Louis
eba6884abb
feat: allow users to refresh cloud model list (#4698)
* feat: allow users to refresh cloud model list

* chore: reusable model list refresh

* chore: clean up
2025-02-19 23:24:29 +07:00
Louis
046e8d5094
chore: Hub UI and markdown CSS 2025-02-19 15:20:59 +07:00
Faisal Amir
4abd471a5f
fix: format compact number utils (#4695) 2025-02-19 13:58:43 +07:00
Louis
c4d7a143eb
Merge pull request #4683 from janhq/chore/sync-release-to-dev
chore: sync release v0.5.15 branch into dev branch
2025-02-18 18:40:03 +07:00
Louis
7d5aa46eef
chore: lint fix 2025-02-18 18:18:38 +07:00
Louis
133af33014
chore: typo 2025-02-18 18:02:22 +07:00
Louis
dc06a07c71
Merge branch 'release/v0.5.15' into chore/sync-release-to-dev
# Conflicts:
#	extensions/engine-management-extension/rolldown.config.mjs
#	extensions/inference-cortex-extension/bin/version.txt
#	extensions/yarn.lock
#	web/containers/Layout/BottomPanel/SystemMonitor/index.tsx
#	web/containers/ModelDropdown/index.tsx
#	web/containers/ModelLabel/ModelLabel.test.tsx
#	web/screens/Settings/HuggingFaceRepoDetailModal/ModelDownloadRow/index.tsx
#	web/screens/Thread/ThreadCenterPanel/TextMessage/MarkdownTextMessage.tsx
#	web/screens/Thread/ThreadCenterPanel/TextMessage/index.tsx
#	yarn.lock
2025-02-18 16:33:58 +07:00
Ashley
29a2a171d5
Merge pull request #4676 from janhq/chore/update-docs
chore: Update all images & some wrong parts in Jan docs
2025-02-18 14:00:46 +07:00
Louis
6c6fc08a45
chore: fix engine template for remote providers (#4680) 2025-02-18 13:05:23 +07:00
Louis
f08de8cc8f
chore: bump cortex release 1.0.10 (#4679) 2025-02-18 12:14:36 +07:00
Faisal Amir
4ff7959334
fix: reload app when gpu change (#4678) 2025-02-18 11:40:44 +07:00
Louis
23d1b72ab5
chore: bump cortex.cpp 1.0.10-rc13 (#4677) 2025-02-18 10:12:22 +07:00
Ashley
243a3faf77 Update all images & some wrong parts 2025-02-18 00:34:10 +07:00
Louis
8db8110dd7
chore: update api playground to be synced with the latest cortex.cpp specs (#4672) 2025-02-17 22:17:56 +07:00
Louis
e0437afb2c
fix: app stucks at generating response state after stopped the previous session (#4662)
* chore: add OpenAI o3-mini model to ship with the app by default

* chore: should not reload model on inference parameters update

* chore: update cortex.cpp rc build
2025-02-17 15:24:43 +07:00
Faisal Amir
9dc2597540
chore: update ui width text field slider, and conditional button copy for hgf token (#4661) 2025-02-17 15:19:59 +07:00
Faisal Amir
929fc579ec
chore: disable turn off local engine llamacpp (#4660) 2025-02-17 13:44:00 +07:00
Faisal Amir
b0c6779015
feat: app updater with changelog (#4631)
* feat: ui modal app updater with changelog

* chore: update action when click update now

* chore: update handler actions

* chore: fix linter
2025-02-17 12:08:08 +07:00
ddri
476c7f723f
Fix typo for Red Hat company name (#4637)
"Red Hat" is the correct company name, not "Redhat".
2025-02-16 11:47:35 +07:00
Louis
1927262b62
chore: bump cortex-cpp rc10 (#4656) 2025-02-15 15:21:01 +07:00
Louis
d472f2e30c
chore: bump cortex version and fix misc UI issues (#4654) 2025-02-15 10:18:26 +07:00
Faisal Amir
9aed6523ea
fix: link open new window inside chat message (#4651)
* fix: link open new window inside chat message

* chore: fix linter
2025-02-14 22:29:02 +07:00
Faisal Amir
dde260e723
fix: gpu hardware state (#4650)
* fix: gpu hardware state

* chore: cleanup state

* chore: clear state
2025-02-14 11:21:18 +07:00
Louis
7a6890bd7f
chore: remote engine error handling (#4646)
* chore: Gemini error handling

* chore: remote provider error handling

* chore: remote provider error handling

* chore: fix anthropic unsupported parameters

* chore: fix tests
2025-02-13 18:32:33 +07:00
Faisal Amir
0c0b7e5fcc
fix: error setting remote engine (#4648)
* fix: link setting error remote engine

* fix: change logo gemini, and resolve link error setting
2025-02-13 17:35:22 +07:00
Faisal Amir
d2336cfb0f
fix: model dropdown icon miss align (#4645) 2025-02-13 17:18:46 +07:00
Faisal Amir
c538c60ce0
fix: rename google gemini into gemini (#4644) 2025-02-13 16:01:48 +07:00
Louis
470fd64ab5
chore: bump cortex.cpp server 1.0.10-rc6 (#4642)
* chore: bump cortex.cpp server 1.0.10-rc6

* chore: don't force stop model on delete if its not currently running
2025-02-13 12:39:04 +07:00
Faisal Amir
aed42edb3f
fix: multiple gpu (#4641)
* fix: multiple gpu

* chore: check vulkan when app load

* chore: remove log

* chore: update engine variant conditional
2025-02-12 22:50:56 +07:00
Faisal Amir
6d73f49cdf
fix: filter out variant engine (#4639)
* fix: filter out variant engine

* fix: filter out startwith
2025-02-12 19:20:38 +07:00
hiento09
89fc777f0d
fix: beta noti discord (#4640) 2025-02-12 18:01:18 +07:00
Louis
b8743cfb50
fix: messages re-render on different threads (#4638) 2025-02-12 16:32:10 +07:00
hiento09
82c45debb7
chore: beta version not publish to github (#4634)
Co-authored-by: Service Account <service@jan.ai>
2025-02-12 09:53:54 +07:00
Louis
2510ed7bfe
chore: bump cortex-cpp to the rc5 to address race condition issue (#4630) 2025-02-11 20:56:38 +07:00
Faisal Amir
6a87b73ced
fix: render slow on device label (#4627)
* fix: render slow on device label

* chore: remove log
2025-02-11 15:36:53 +07:00
Louis
087aaa5a55
fix: app shows update button even there is no new release (#4628) 2025-02-11 15:29:24 +07:00
Louis
ab3b47f134
chore: fix engine variant for mac targets (#4626) 2025-02-11 14:28:08 +07:00
Louis
931d70fc50
chore: add back env paths setting so cortex engine can load libraries properly (#4625)
* chore: add back env paths setting so cortex engine can load libraries properly

* chore: bump cortex
2025-02-11 13:55:25 +07:00
Faisal Amir
1fe15236a0
fix: remove toggle enable GPU from setting (#4624)
* fix: remove toggle enable GPU

* chore: remove logic

* chore: fix linter
2025-02-11 13:49:51 +07:00
Louis
a6d2dac406
chore: change cortex.cpp log level to info for easier log observation (#4623) 2025-02-11 11:05:13 +07:00
Louis
ceb93cafef
chore: bump cortex to the latest version 1.0.10-rc1 to address hardware UI issues (#4622)
* chore: bump cortex to the latest version 1.0.10-rc1 to address hardware API issues

* fix: app crashes while reading properties from undefined value

* fix: cuda engine variant selection logic
2025-02-11 10:24:47 +07:00
Faisal Amir
386d41028a
fix: filter out fake gpu (#4617) 2025-02-10 21:03:28 +07:00
Louis
e877871dc6
fix: inconsistent models list on first launch (#4618) 2025-02-10 21:00:56 +07:00
Faisal Amir
6e891d9a3b
fix: remove from list dropdown when deleted remote model (#4616)
* fix: remove from list dropdown when deleted remote model

* chore: update logic
2025-02-10 20:19:47 +07:00
Emre Can Kartal
f8f19af8c5
docs: add new changelog posts and images (#4601)
* docs: add DeepSeek R1 local installation guide

- Add comprehensive guide for running DeepSeek R1 locally
- Include step-by-step instructions with screenshots
- Add VRAM requirements and model selection guide
- Include system prompt setup instructions

* docs: add comprehensive guide on running AI models locally

* docs: address PR feedback for DeepSeek R1 and local AI guides

- Improve language and terminology throughout
- Add Linux support information
- Enhance technical explanations
- Update introduction for better flow
- Fix parameters section in run-ai-models-locally.mdx

* docs: improve local AI guides content and linking

- Update titles and introductions for better SEO
- Add opinionated guidance section for beginners
- Link DeepSeek guide with general local AI guide
- Fix typos and improve readability

* docs: add new changelog posts and images

- Add DeepSeek R1 changelog (v0.5.14)
- Add key issues resolved changelog (v0.5.13)
- Add corresponding changelog images

---------

Co-authored-by: Louis <louis@jan.ai>
2025-02-10 09:49:54 +07:00
Emre Can Kartal
60447289bd
blog: improve local AI guide for beginners (#4610)
* docs: add DeepSeek R1 local installation guide

- Add comprehensive guide for running DeepSeek R1 locally
- Include step-by-step instructions with screenshots
- Add VRAM requirements and model selection guide
- Include system prompt setup instructions

* docs: add comprehensive guide on running AI models locally

* docs: address PR feedback for DeepSeek R1 and local AI guides

- Improve language and terminology throughout
- Add Linux support information
- Enhance technical explanations
- Update introduction for better flow
- Fix parameters section in run-ai-models-locally.mdx

* docs: improve local AI guides content and linking

- Update titles and introductions for better SEO
- Add opinionated guidance section for beginners
- Link DeepSeek guide with general local AI guide
- Fix typos and improve readability

* fix: remove git conflict markers from deepseek guide frontmatter

* docs: improve local AI guide for beginners

Key improvements:
- Add detailed explanation of GGUF and why it's needed
- Improve content structure and readability
- Add visual guides with SEO-friendly images
- Enhance llama.cpp explanation with GitHub link
- Fix heading hierarchy for better navigation
- Add practical examples and common questions
- Update image paths and captions for better SEO

Technical details:
- Add proper image alt text and captions
- Link to llama.cpp GitHub repository
- Clarify model size requirements
- Simplify hardware requirements section
- Improve heading structure (h1-h5)
- Add step-by-step model installation guide

* docs: add offline ChatGPT alternative guide with Jan

- Add comprehensive guide on using Jan as offline ChatGPT alternative
- Include step-by-step instructions for setup
- Add images for document chat feature
- Optimize content for SEO with relevant keywords

* docs: update description to emphasize computer-local aspect

---------

Co-authored-by: Louis <louis@jan.ai>
2025-02-10 09:43:07 +07:00
eckartal
af7297b6ae docs: update description to emphasize computer-local aspect 2025-02-10 00:10:17 +07:00
Ashley
2ef3e8b691
Merge pull request #4613 from janhq/chore/update-engine-docs
chore: Update guide for cloud model installation & some new remote engines
2025-02-09 22:28:07 +07:00
Louis
45edb9cc51
fix: error handling - pull remote models list raise an error on fail (#4615)
* chore: pull models list on /models update

* chore: correct engine extension name

* chore: fix undefined error

* chore: revert auto populating remote models on update
2025-02-09 19:40:32 +07:00
Louis
05b124f624
chore: add back app logging function (#4614) 2025-02-09 19:36:56 +07:00
Ashley
433bee7134 Added DeepSeek & Google guides, updated some images 2025-02-09 16:59:34 +07:00
Ashley
5b76a69bab Added guide for cloud model installation 2025-02-09 15:53:57 +07:00
Louis
8419973d5e
chore: open URL from model detail page should open in an external browser (#4611)
* chore: open URL from model detail page should open in an external browser

* chore: remove unused param
2025-02-09 14:23:54 +07:00
Faisal Amir
a9a63ab5d9
fix: server log actions position (#4608)
* fix: sever log actions position

* chore: unused import
2025-02-09 13:07:08 +07:00
Faisal Amir
c5f17b4e83
fix: remote engine model auto select (#4609) 2025-02-09 13:06:57 +07:00
eckartal
b0f24dd258 docs: add offline ChatGPT alternative guide with Jan
- Add comprehensive guide on using Jan as offline ChatGPT alternative
- Include step-by-step instructions for setup
- Add images for document chat feature
- Optimize content for SEO with relevant keywords
2025-02-08 15:35:33 +07:00
eckartal
d4bd51a205 docs: improve local AI guide for beginners
Key improvements:
- Add detailed explanation of GGUF and why it's needed
- Improve content structure and readability
- Add visual guides with SEO-friendly images
- Enhance llama.cpp explanation with GitHub link
- Fix heading hierarchy for better navigation
- Add practical examples and common questions
- Update image paths and captions for better SEO

Technical details:
- Add proper image alt text and captions
- Link to llama.cpp GitHub repository
- Clarify model size requirements
- Simplify hardware requirements section
- Improve heading structure (h1-h5)
- Add step-by-step model installation guide
2025-02-08 12:19:14 +07:00
Louis
42f767c191
chore: update remote provider response transform template (#4602) 2025-02-08 07:55:57 +07:00
Emre Can Kartal
404c3f096e
docs: improve local AI guides content and linking (#4600)
* docs: add DeepSeek R1 local installation guide

- Add comprehensive guide for running DeepSeek R1 locally
- Include step-by-step instructions with screenshots
- Add VRAM requirements and model selection guide
- Include system prompt setup instructions

* docs: add comprehensive guide on running AI models locally

* docs: address PR feedback for DeepSeek R1 and local AI guides

- Improve language and terminology throughout
- Add Linux support information
- Enhance technical explanations
- Update introduction for better flow
- Fix parameters section in run-ai-models-locally.mdx

* docs: improve local AI guides content and linking

- Update titles and introductions for better SEO
- Add opinionated guidance section for beginners
- Link DeepSeek guide with general local AI guide
- Fix typos and improve readability

* fix: remove git conflict markers from deepseek guide frontmatter

---------

Co-authored-by: Louis <louis@jan.ai>
2025-02-07 23:44:36 +07:00
eckartal
7c6b85d960 fix: remove git conflict markers from deepseek guide frontmatter 2025-02-07 22:36:34 +07:00
Faisal Amir
9837d09756
fix: load model error component (#4604)
* fix: load model error should using error component

* chore: fix linter issue
2025-02-07 22:18:21 +07:00
eckartal
52b3ba40a3 docs: resolve conflicts and add new changelog posts
- Resolve conflicts in deepseek-r1-locally.mdx and run-ai-models-locally.mdx
- Keep SEO-optimized content and structure
- Add new changelog posts for v0.5.13 and v0.5.14
2025-02-07 21:00:53 +07:00
eckartal
aff09598db docs: improve local AI guides content and linking
- Update titles and introductions for better SEO
- Add opinionated guidance section for beginners
- Link DeepSeek guide with general local AI guide
- Fix typos and improve readability
2025-02-06 21:44:42 +07:00
Faisal Amir
5ca310384a
chore: update style codeblock (#4599) 2025-02-06 21:42:52 +07:00
Louis
a70735b8a5
chore: bump cortex with conversation patch update (#4598)
* chore: correct conversational PATCH methods with latest cortex update (#4568)

# Conflicts:
#	extensions/inference-cortex-extension/bin/version.txt

* chore: bump cortex 1.0.9-rc8
2025-02-06 21:03:02 +07:00
Louis
a87bbd2840
chore: add google gemini and deepseek as new supported remote engine providers (#4596)
* chore: add google gemini and deepseek as new supported remote engine providers

* chore: add logos

* chore: fallback default error message on empty

* chore: update open router models

* chore: typo fix

* chore: remove unusable queen vl
2025-02-06 20:52:42 +07:00
Ashley
ca220d18a6
chore: Updated copies in-app (#4527)
* Updated copies in Advanced Settings

* Updated copies in Extensions Settings

* Updated copies in Engines Settings

* Updated copies in Engines Settings

* Updated copies in Install Engine modal

* chore: lint fix

---------

Co-authored-by: Louis <louis@jan.ai>
2025-02-06 10:09:32 +07:00
Louis
c32c9e1dcb
chore: add DeepSeek R1 Distill models to Hub (#4586) 2025-02-05 23:10:40 +07:00
Louis
b79edc225b
chore: add default inference parameters for custom remote models (#4584) 2025-02-05 21:21:36 +07:00
Faisal Amir
f2f31d8dc8
chore: calculate model label (#4585)
* chore: fix claculate model label

* chore: update test model label
2025-02-05 20:29:46 +07:00
Faisal Amir
ed5c6a61a5
enhancement: toggle change cover hub banner style (#4579) 2025-02-05 15:29:11 +07:00
Louis
4846befd4a
chore: engine model adding ux refinement (#4580)
* fix: enhance remote engine models adding UX

* fix: OpenAI o3 support template

* chore: fix models populating error

* chore: missing dependency
2025-02-05 15:28:35 +07:00
Faisal Amir
095a00441c
chore: delete custom engine (#4581)
* chore: delete custom engine

* chore: fix linter
2025-02-05 15:19:44 +07:00
Faisal Amir
7f4155c443
enhancement: error ui in threads (#4578) 2025-02-05 12:26:15 +07:00
Faisal Amir
2d82567de7
enhancement: adjust hub ui in different themes (#4574) 2025-02-04 21:24:04 +07:00
Faisal Amir
678116c6d6
fix: exclude yml into totaldownload start next version (#4572) 2025-02-04 20:59:27 +07:00
Louis
ddc2cd5e0f
chore: correct conversational PATCH methods with latest cortex update (#4568) 2025-02-04 19:25:01 +07:00
Faisal Amir
e99cbd9e5c
enhancement: code snippet color and bakground should depend on native theme (#4566) 2025-02-04 19:12:08 +07:00
Faisal Amir
0cc6f29f7f
fix: download progress import from hgf (#4567) 2025-02-04 19:09:20 +07:00
Faisal Amir
f8557c78d5
fix: think content render as markdown (#4564)
* fix: think content render as markdown

* chore: fix linter issue failed on CI
2025-02-04 14:54:21 +07:00
Faisal Amir
daa7c0ca21
feat: better hardware setting (#4471)
* feat: better hardware setting

* chore: update layout

* feat: better hardware setting

* chore: fix title section

* chore: added hardware engine management

* chore: integrate gpus and enable set gpu activate

* chore: update calculate ram and vram

* chore: update calulate vram and ram used

* fix: set active gpus

* chore: fix progress bar spacing

* chore: always update cache vram gpu

* chore: update cpu usage percentage

* chore: fix type usage cpu

* chore: update ram cpus usage getsystemmonitor from new api harware engine management system

* test: update test case data using hardware management extension

* chore: resolve conflict lock json

* chore: cleanup app services

* chore: update type OperationSystemInfo

* chore: update app service

* chore: show list gpus on system monitor

* chore: remove monitoring extension

* chore: update test case app service

* chore: remove unused hooks useGpusSetting

* chore: remove monitor from shource index

* chore: fix test core

* chore: update gpu and cpu info on engine management ext

* chore: fix app service test

* chore: update test appService include cpu info

* chore: filter gpus show or hide on system monitor based activated gpu

* chore: remove unused run_mode

* chore: remove tensort

* chore: update check gpu run_mode

* chore: handle undefined gpus

* chore: cleanup PR

* chore: cleanup process node error

* chore: fix type
2025-02-03 22:01:08 +07:00
Emre Can Kartal
54e04c8262
blog: add DeepSeek R1 local installation guide (#4552)
* docs: add DeepSeek R1 local installation guide

- Add comprehensive guide for running DeepSeek R1 locally
- Include step-by-step instructions with screenshots
- Add VRAM requirements and model selection guide
- Include system prompt setup instructions

* docs: add comprehensive guide on running AI models locally

* docs: address PR feedback for DeepSeek R1 and local AI guides

- Improve language and terminology throughout
- Add Linux support information
- Enhance technical explanations
- Update introduction for better flow
- Fix parameters section in run-ai-models-locally.mdx

---------

Co-authored-by: Louis <louis@jan.ai>
2025-02-03 21:01:27 +07:00
Faisal Amir
72b9aaeba1
enhancement: remote engine model (#4560)
* enhancement: add option delete model remote engine

* enhancement: add menu delete remote engine models
2025-02-03 20:36:31 +07:00
Faisal Amir
899f01d5c4
enhancement: update ui uploading files and images (#4562) 2025-02-03 20:36:19 +07:00
eckartal
a091e8e84d docs: address PR feedback for DeepSeek R1 and local AI guides
- Improve language and terminology throughout
- Add Linux support information
- Enhance technical explanations
- Update introduction for better flow
- Fix parameters section in run-ai-models-locally.mdx
2025-02-03 15:47:13 +07:00
Faisal Amir
043284f51e
chore: reasoning block (#4551)
* chore: reasoning text block

* chore: update interface support all theme

* chore: update failed test

* chore: update state collapsed based on message index

* fix: use reserve_id instead of message index

* chore: clean up

* chore: fix loading indicator

---------

Co-authored-by: Louis <louis@jan.ai>
2025-02-01 22:22:45 +07:00
eckartal
8f620b9146 docs: add comprehensive guide on running AI models locally 2025-01-31 18:46:38 +07:00
eckartal
705116c109 docs: add DeepSeek R1 local installation guide
- Add comprehensive guide for running DeepSeek R1 locally
- Include step-by-step instructions with screenshots
- Add VRAM requirements and model selection guide
- Include system prompt setup instructions
2025-01-31 16:47:38 +07:00
Faisal Amir
f2bb9c91de
chore: align item menu action error message (#4548) 2025-01-30 21:20:55 +07:00
Louis
33db5135b1
feat: auto pull models list when setting up remote engine (#4547) 2025-01-30 17:26:46 +07:00
Louis
f071497c0e
chore: rotate model hub banner on app launch until set (#4542) 2025-01-29 23:12:16 +07:00
Louis
350c9f7def
chore: maintain app distinct_id on factory reset (#4541) 2025-01-29 21:52:00 +07:00
Louis
144b836935
fix: app does not reload model when prompt template is updated (#4537)
* fix: app does not reload model when prompt template is updated

* chore: lint fix
2025-01-29 21:50:17 +07:00
Louis
0a41a2456c
chore: sync cortex engine version (#4536) 2025-01-28 23:39:50 +07:00
Faisal Amir
010802012f
fix: broken range slider ctx lenght (#4535) 2025-01-28 23:15:02 +07:00
Louis
83f090826e
feat: Jan Hub Revamp (#4491)
* feat: model hub revamp UI

* chore: model description - consistent markdown css

* chore: add model versions dropdown

* chore: integrate APIs - model sources

* chore: update model display name

* chore: lint fix

* chore: page transition animation

* feat: model search dropdown - deeplink

* chore: bump cortex version

* chore: add remote model sources

* chore: model download state

* chore: fix model metadata label

* chore: polish model detail page markdown

* test: fix test cases

* chore: initialize default Hub model sources

* chore: fix model stats

* chore: clean up click outside and inside hooks

* feat: change hub banner

* chore: lint fix

* chore: fix css long model id
2025-01-28 22:23:25 +07:00
Faisal Amir
261b44d906
feat: Standardize inline error messages (#4530) 2025-01-28 21:45:46 +07:00
Faisal Amir
c46e30d001
enhancement: unconsistent text color model name, hidden api-key field, and chat completion field under advance setting (#4532) 2025-01-28 21:45:32 +07:00
Faisal Amir
be6de587c5
enhancement: update responsive setting and my model page (#4533) 2025-01-28 21:45:20 +07:00
Louis
6dd090acc1
feat: allow users to add remote models (#4534) 2025-01-28 18:07:59 +07:00
Faisal Amir
65c9bb9fe1
enhancement: update app layout with system monitor open (#4528) 2025-01-28 12:33:03 +07:00
Faisal Amir
afae57b52b
enhancement: added space scroll remote engine setting (#4523)
* enhancement: added space scroll remote engine setting

* chore: show icon history only left panel close on thread page
2025-01-27 20:22:54 +07:00
Faisal Amir
628838442d
enhancement: create new thread with last chosen model (#4524)
* enhancement: create new thread with last chosen model

* chore: resolve setting undefined
2025-01-27 20:22:39 +07:00
Young Shung
7f6c8aa205
fix: typo on apple (#4525) 2025-01-27 20:22:29 +07:00
Faisal Amir
32436121c7
feat: remove umami (#4520) 2025-01-26 20:42:03 +07:00
Faisal Amir
cdc7d2ba47
enhancement: minor ui refinements (#4521)
* enhancement: minor ui refinements

* chore: update test case
2025-01-26 20:41:52 +07:00
Emre Can Kartal
5dc184eed9
docs: add privacy policy page and update navigation (#4472)
- Add comprehensive privacy policy page
- Hide privacy policy from navigation
- Update privacy page content
- Configure _meta.json for proper page visibility
2025-01-24 12:47:45 +07:00
Doan Bui
83550cd0d1
Feat: Allow HTTP proxy authentication inputs (#4479)
* sub dir

* setting proxy

* test useConfigurations

* fix lint

* test

* test 2

* update check
2025-01-24 09:31:26 +07:00
Ashley
8c6e6edd36
Merge pull request #4516 from janhq/chore/update-integrations-docs
chore: Update outdated integrations docs
2025-01-24 09:10:11 +07:00
Ashley
959c09dbbd Removed outdated Raycast instruction 2025-01-24 00:22:47 +07:00
Louis
3dcc8657ba
Merge pull request #4510 from janhq/release/v0.5.14
chore: sync 0.5.14 release into dev
2025-01-23 11:42:43 +07:00
Louis
3037206108
Merge pull request #4509 from janhq/release/v0.5.14
chore: sync 0.5.14 release into main
2025-01-23 11:42:21 +07:00
Louis
27a4d979f3
Merge branch 'main' into release/v0.5.14
# Conflicts:
#	extensions/inference-cortex-extension/download.bat
#	extensions/inference-cortex-extension/download.sh
#	extensions/inference-cortex-extension/rollup.config.ts
2025-01-23 11:27:31 +07:00
Nguyen Ngoc Minh
f480dd35ca
Merge pull request #4506 from janhq/chore/allow-only-internal-contributor
chore: ignore external contributors
2025-01-22 21:41:08 +07:00
Faisal Amir
53f2943b2c
fix: typo meta description (#4507)
* fix: typo meta description

* chore: fix meta desc
2025-01-22 21:39:55 +07:00
Minh141120
a59ba000c0 chore: ignore external contributors 2025-01-22 21:17:38 +07:00
Louis
a3b242c4b7
Merge pull request #4504 from janhq/fix/thread-title-summarization-constraints
fix: thread title summarization doesn't work well on reasoning models
2025-01-22 15:27:20 +07:00
Louis
156dbc21d0
fix: thread title summarization doesn't work well on reasoning models 2025-01-22 11:03:38 +07:00
Faisal Amir
a6238a22dd
fix: Correct index for Windows download button (#4500) 2025-01-21 22:06:36 +07:00
Louis
bcb016caa9
Merge pull request #4498 from janhq/chore/bump-llamacpp-version
chore: bump llama.cpp to the latest version
2025-01-21 21:25:03 +07:00
Louis
a2ca6a685f
chore: bump llama.cpp to the latest version 2025-01-21 15:43:02 +07:00
Louis
105a1c3078
Merge pull request #4486 from janhq/main
chore: sync from main into dev
2025-01-20 13:50:44 +07:00
Louis
0dd251915d
Merge pull request #4481 from janhq/chore/engines-data-cache
chore: add caching for engines to improve load time
2025-01-18 09:31:09 +07:00
Louis
9cf63f87cc
chore: fix type access 2025-01-18 09:16:32 +07:00
Louis
c7bc2eff62
chore: engines data cache - improve ux 2025-01-17 23:12:40 +07:00
2432 changed files with 165601 additions and 87057 deletions

View File

@ -0,0 +1,31 @@
---
allowed-tools: Bash(gh issue view:*), Bash(gh search:*), Bash(gh issue list:*), Bash(gh api:*), Bash(gh issue comment:*)
description: Find duplicate GitHub issues
---
Find up to 3 likely duplicate issues for a given GitHub issue.
To do this, follow these steps precisely:
1. Use an agent to check if the Github issue (a) is closed, (b) does not need to be deduped (eg. because it is broad product feedback without a specific solution, or positive feedback), or (c) already has a duplicates comment that you made earlier. If so, do not proceed.
2. Use an agent to view a Github issue, and ask the agent to return a summary of the issue
3. Then, launch 5 parallel agents to search Github for duplicates of this issue, using diverse keywords and search approaches, using the summary from #1
4. Next, feed the results from #1 and #2 into another agent, so that it can filter out false positives, that are likely not actually duplicates of the original issue. If there are no duplicates remaining, do not proceed.
5. Finally, comment back on the issue with a list of up to three duplicate issues (or zero, if there are no likely duplicates)
Notes (be sure to tell this to your agents, too):
- Use `gh` to interact with Github, rather than web fetch
- Do not use other tools, beyond `gh` (eg. don't use other MCP servers, file edit, etc.)
- Make a todo list first
- For your comment, follow the following format precisely (assuming for this example that you found 3 suspected duplicates):
---
Found 3 possible duplicate issues:
1. <link to issue>
2. <link to issue>
3. <link to issue>
---

View File

@ -1,4 +1,20 @@
{
"name": "jan",
"image": "node:20"
"name": "Jan",
"image": "mcr.microsoft.com/devcontainers/base:jammy",
"features": {
"ghcr.io/devcontainers/features/node:1": {
"version": "20"
},
"ghcr.io/devcontainers/features/rust:1": {},
"ghcr.io/devcontainers-extra/features/corepack:1": {}
},
"postCreateCommand": "./.devcontainer/postCreateCommand.sh",
// appimagekit requires fuse to package appimage, to use fuse in the container you need to enable it on the host
"runArgs": [
"--device", "/dev/fuse",
"--cap-add=SYS_ADMIN",
"--security-opt", "apparmor:unconfined"
]
}

View File

@ -0,0 +1,16 @@
#!/usr/bin/env bash
# install tauri prerequisites + xdg-utils for xdg-open + libfuse2 for using appimagekit
sudo apt update
sudo apt install -yqq libwebkit2gtk-4.1-dev \
build-essential \
curl \
wget \
file \
libxdo-dev \
libssl-dev \
libayatana-appindicator3-dev \
librsvg2-dev \
xdg-utils \
libfuse2

24
.github/ISSUE_TEMPLATE/1-bug-report.md vendored Normal file
View File

@ -0,0 +1,24 @@
---
name: 🐛 Bug Report
about: If something isn't working as expected 🤔
title: 'bug: '
type: Bug
---
**Version:** e.g. 0.5.x-xxx
## Describe the Bug
<!-- A clear & concise description of the bug -->
## Steps to Reproduce
1.
## Screenshots / Logs
<!-- You can find logs in: Setting -> General -> Data Folder -> App Logs -->
## Operating System
- [ ] MacOS
- [ ] Windows
- [ ] Linux

View File

@ -0,0 +1,12 @@
---
name: 🚀 Feature Request
about: Suggest an idea for this project 😻!
title: 'idea: '
type: Idea
---
## Problem Statement
<!-- Describe the problem you're facing -->
## Feature Idea
<!-- Describe what you want instead. Examples are welcome! -->

27
.github/ISSUE_TEMPLATE/3-epic.md vendored Normal file
View File

@ -0,0 +1,27 @@
---
name: 🌟 Epic
about: User stories and specs
title: 'epic: '
type: Epic
---
## User Stories
- As a [user type], I can [do something] so that [outcome]
## Not in scope
-
## User Flows & Designs
- Key user flows
- Figma link
- Edge cases
- Error states
## Engineering Decisions
- **Technical Approach:** Brief outline of the solution.
- **Key Trade-offs:** Whats been considered/rejected and why.
- **Dependencies:** APIs, services, libraries, teams.

24
.github/ISSUE_TEMPLATE/4-goal.md vendored Normal file
View File

@ -0,0 +1,24 @@
---
name: 🎯 Goal
about: Roadmap goals for our users
title: 'goal: '
type: Goal
---
## 🎯 Goal
<!-- Short description of our goal -->
## 📖 Context
<!-- Give a description of our current context -->
## ✅ Scope
<!-- High lever description of what we are going to deliver -->
## ❌ Out of Scope
<!-- What we are not targeting / delivering / discussing in this goal -->
## 🛠 Deliverables
<!-- What we are the tangible deliverables for this goal -->
## ❓Open questions
<!-- What are we not sure about and need to discuss more -->

View File

@ -1,43 +0,0 @@
name: "\U0001F41B Bug Report"
description: "If something isn't working as expected \U0001F914"
labels: [ "type: bug" ]
title: 'bug: [DESCRIPTION]'
body:
- type: input
validations:
required: true
attributes:
label: "Jan version"
description: "**Tip:** The version is in the app's bottom right corner"
placeholder: "e.g. 0.5.x-xxx"
- type: textarea
validations:
required: true
attributes:
label: "Describe the Bug"
description: "A clear & concise description of the bug"
- type: textarea
attributes:
label: "Steps to Reproduce"
description: |
Please list out steps to reproduce the issue
placeholder: |
1. Go to '...'
2. Click on '...'
- type: textarea
attributes:
label: "Screenshots / Logs"
description: |
You can find logs in: ~/jan/logs/app.logs
- type: checkboxes
attributes:
label: "What is your OS?"
options:
- label: MacOS
- label: Windows
- label: Linux

View File

@ -1,7 +1,5 @@
## To encourage contributors to use issue templates, we don't allow blank issues
blank_issues_enabled: true
contact_links:
- name: "\1F4AC Jan Discussions"
url: "https://github.com/orgs/janhq/discussions/categories/q-a"
about: "Get help, discuss features & roadmap, and share your projects"
- name: Jan Discussions
url: https://github.com/orgs/janhq/discussions/categories/q-a
about: Get help, discuss features & roadmap, and share your projects

View File

@ -1,20 +0,0 @@
name: "\U0001F680 Feature Request"
description: "Suggest an idea for this project \U0001F63B!"
title: 'idea: [DESCRIPTION]'
labels: 'type: feature request'
body:
- type: textarea
validations:
required: true
attributes:
label: "Problem Statement"
description: "Describe the problem you're facing"
placeholder: |
I'm always frustrated when ...
- type: textarea
validations:
required: true
attributes:
label: "Feature Idea"
description: "Describe what you want instead. Examples are welcome!"

View File

@ -1,21 +0,0 @@
name: "\U0001F929 Model Request"
description: "Request a new model to be compiled"
title: 'feat: [DESCRIPTION]'
labels: 'type: model request'
body:
- type: markdown
attributes:
value: "**Tip:** Download any HuggingFace model in app ([see guides](https://jan.ai/docs/models/manage-models#add-models)). Use this form for unsupported models only."
- type: textarea
validations:
required: true
attributes:
label: "Model Requests"
description: "If applicable, include the source URL, licenses, and any other relevant information"
- type: checkboxes
attributes:
label: "Which formats?"
options:
- label: GGUF (llama.cpp)
- label: TensorRT (TensorRT-LLM)
- label: ONNX (Onnx Runtime)

View File

@ -1,35 +0,0 @@
---
name: Roadmap
about: Plan Roadmap items with subtasks
title: 'roadmap: '
labels: 'type: planning'
assignees: ''
---
## Goal
## Tasklist
### Frontend
- [ ] link to janhq/jan epics
**Bugs**
- [ ] link to bugs
### Backend
- [ ] link to janhq/cortex.cpp epics
**Bugs**
- [ ] link to bug issues
### Infra
- [ ] link to infra issues
### Administrative / Management
- [ ] link to infra issues
### Marketing
-------
## Resources

19
.github/dependabot.yaml vendored Normal file
View File

@ -0,0 +1,19 @@
# https://docs.github.com/en/code-security/dependabot/working-with-dependabot/dependabot-options-reference#package-ecosystem-
version: 2
updates:
- package-ecosystem: 'cargo'
directory: 'src-tauri'
schedule:
interval: 'weekly'
open-pull-requests-limit: 0
- package-ecosystem: 'npm'
directories:
- '/'
- 'core'
- 'docs'
- 'extensions'
- 'extensions/*'
- 'web-app'
schedule:
interval: 'weekly'
open-pull-requests-limit: 0

BIN
.github/scripts/icon-beta.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB

BIN
.github/scripts/icon-nightly.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB

63
.github/scripts/rename-tauri-app.sh vendored Normal file
View File

@ -0,0 +1,63 @@
#!/bin/bash
# Check if the correct number of arguments is provided
if [ "$#" -ne 2 ]; then
echo "Usage: $0 <path_to_json_input_file> <channel>"
exit 1
fi
INPUT_JSON_FILE="$1"
CHANNEL="$2"
if [ "$CHANNEL" == "nightly" ]; then
UPDATER="latest"
else
UPDATER="beta"
fi
# Check if the input file exists
if [ ! -f "$INPUT_JSON_FILE" ]; then
echo "Input file not found: $INPUT_JSON_FILE"
exit 1
fi
# Use jq to transform the content
jq --arg channel "$CHANNEL" --arg updater "$UPDATER" '
.productName = "Jan-\($channel)" |
.identifier = "jan-\($channel).ai.app"
' "$INPUT_JSON_FILE" > ./tauri.conf.json.tmp
cat ./tauri.conf.json.tmp
rm $INPUT_JSON_FILE
mv ./tauri.conf.json.tmp $INPUT_JSON_FILE
# Update Info.plist if it exists
INFO_PLIST_PATH="./src-tauri/Info.plist"
if [ -f "$INFO_PLIST_PATH" ]; then
echo "Updating Info.plist..."
# Replace jan.ai.app with jan-{channel}.ai.app
sed -i '' "s|jan\.ai\.app|jan-${CHANNEL}.ai.app|g" "$INFO_PLIST_PATH"
# Replace <string>jan</string> with <string>jan-{channel}</string>
sed -i '' "s|<string>jan</string>|<string>jan-${CHANNEL}</string>|g" "$INFO_PLIST_PATH"
echo "Info.plist updated"
cat ./src-tauri/Info.plist
fi
# Update the layout file
# LAYOUT_FILE_PATH="web/app/layout.tsx"
# if [ ! -f "$LAYOUT_FILE_PATH" ]; then
# echo "File does not exist: $LAYOUT_FILE_PATH"
# exit 1
# fi
# Perform the replacements
# sed -i -e "s#Jan#Jan-$CHANNEL#g" "$LAYOUT_FILE_PATH"
# Notify completion
# echo "File has been updated: $LAYOUT_FILE_PATH"

View File

@ -6,6 +6,7 @@ on:
jobs:
assign-author:
runs-on: ubuntu-latest
if: ${{ github.event.pull_request.head.repo.full_name == github.repository }}
permissions:
pull-requests: write
steps:

View File

@ -7,6 +7,7 @@ on:
jobs:
assign_milestone:
runs-on: ubuntu-latest
if: ${{ github.event.pull_request.head.repo.full_name == github.repository }}
permissions:
pull-requests: write
issues: write

View File

@ -6,6 +6,7 @@ on:
- opened
jobs:
label_prs:
if: github.event.pull_request.head.repo.full_name == github.repository
runs-on: ubuntu-latest
permissions:
pull-requests: write

View File

@ -0,0 +1,37 @@
name: Manual trigger AutoQA Test Runner
on:
workflow_dispatch:
inputs:
jan_app_url_windows:
description: 'URL to download Jan app for Windows (.exe)'
required: true
type: string
default: 'https://delta.jan.ai/nightly/Jan-nightly_0.6.5-758_x64-setup.exe'
jan_app_url_ubuntu:
description: 'URL to download Jan app for Ubuntu (.deb)'
required: true
type: string
default: 'https://delta.jan.ai/nightly/Jan-nightly_0.6.5-758_amd64.deb'
jan_app_url_macos:
description: 'URL to download Jan app for macOS (.dmg)'
required: true
type: string
default: 'https://delta.jan.ai/nightly/Jan-nightly_0.6.5-758_universal.dmg'
is_nightly:
description: 'Is this a nightly build?'
required: true
type: boolean
default: true
jobs:
call-autoqa-template:
uses: ./.github/workflows/autoqa-template.yml
with:
jan_app_windows_source: ${{ inputs.jan_app_url_windows }}
jan_app_ubuntu_source: ${{ inputs.jan_app_url_ubuntu }}
jan_app_macos_source: ${{ inputs.jan_app_url_macos }}
is_nightly: ${{ inputs.is_nightly }}
source_type: 'url'
secrets:
RP_TOKEN: ${{ secrets.RP_TOKEN }}

330
.github/workflows/autoqa-migration.yml vendored Normal file
View File

@ -0,0 +1,330 @@
name: AutoQA Migration (Manual)
on:
workflow_dispatch:
inputs:
old_windows_installer:
description: 'Windows OLD installer URL or path (.exe)'
required: true
type: string
new_windows_installer:
description: 'Windows NEW installer URL or path (.exe)'
required: true
type: string
old_ubuntu_installer:
description: 'Ubuntu OLD installer URL or path (.deb)'
required: false
type: string
default: ''
new_ubuntu_installer:
description: 'Ubuntu NEW installer URL or path (.deb)'
required: false
type: string
default: ''
old_macos_installer:
description: 'macOS OLD installer URL or path (.dmg)'
required: false
type: string
default: ''
new_macos_installer:
description: 'macOS NEW installer URL or path (.dmg)'
required: false
type: string
default: ''
migration_test_case:
description: 'Specific migration test case key (leave empty to run all)'
required: false
type: string
default: ''
max_turns:
description: 'Maximum turns per test phase'
required: false
type: number
default: 65
jobs:
migration-windows:
runs-on: windows-11-nvidia-gpu
timeout-minutes: 60
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Python 3.13
uses: actions/setup-python@v4
with:
python-version: '3.13'
- name: Clean existing Jan installations
shell: powershell
run: |
.\autoqa\scripts\windows_cleanup.ps1 -IsNightly $false
- name: Download OLD and NEW installers
shell: powershell
run: |
# Download OLD installer using existing script
.\autoqa\scripts\windows_download.ps1 `
-WorkflowInputUrl "${{ inputs.old_windows_installer }}" `
-WorkflowInputIsNightly "false" `
-RepoVariableUrl "" `
-RepoVariableIsNightly "" `
-DefaultUrl "" `
-DefaultIsNightly ""
$oldSrc = Join-Path $env:TEMP 'jan-installer.exe'
$oldOut = Join-Path $env:TEMP 'jan-old.exe'
Copy-Item -Path $oldSrc -Destination $oldOut -Force
# Download NEW installer using existing script
.\autoqa\scripts\windows_download.ps1 `
-WorkflowInputUrl "${{ inputs.new_windows_installer }}" `
-WorkflowInputIsNightly "false" `
-RepoVariableUrl "" `
-RepoVariableIsNightly "" `
-DefaultUrl "" `
-DefaultIsNightly ""
$newSrc = Join-Path $env:TEMP 'jan-installer.exe'
$newOut = Join-Path $env:TEMP 'jan-new.exe'
Copy-Item -Path $newSrc -Destination $newOut -Force
Write-Host "OLD installer: $oldOut"
Write-Host "NEW installer: $newOut"
echo "OLD_VERSION=$oldOut" | Out-File -FilePath $env:GITHUB_ENV -Append
echo "NEW_VERSION=$newOut" | Out-File -FilePath $env:GITHUB_ENV -Append
- name: Install Python dependencies
working-directory: autoqa
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run migration tests (Windows)
working-directory: autoqa
shell: powershell
env:
RP_TOKEN: ${{ secrets.RP_TOKEN }}
ENABLE_REPORTPORTAL: 'true'
RP_ENDPOINT: 'https://reportportal.menlo.ai'
RP_PROJECT: 'default_personal'
run: |
$case = "${{ inputs.migration_test_case }}"
$caseArg = ""
if ($case -and $case.Trim() -ne "") { $caseArg = "--migration-test-case `"$case`"" }
python main.py --enable-migration-test --old-version "$env:OLD_VERSION" --new-version "$env:NEW_VERSION" --max-turns ${{ inputs.max_turns }} $caseArg
- name: Upload screen recordings
if: always()
uses: actions/upload-artifact@v4
continue-on-error: true
with:
name: migration-recordings-${{ github.run_number }}-windows
path: autoqa/recordings/
- name: Upload trajectories
if: always()
uses: actions/upload-artifact@v4
continue-on-error: true
with:
name: migration-trajectories-${{ github.run_number }}-windows
path: autoqa/trajectories/
- name: Cleanup after tests
if: always()
shell: powershell
run: |
.\autoqa\scripts\windows_post_cleanup.ps1 -IsNightly $false
migration-ubuntu:
if: inputs.old_ubuntu_installer != '' && inputs.new_ubuntu_installer != ''
runs-on: ubuntu-22-04-nvidia-gpu
timeout-minutes: 60
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Python 3.13
uses: actions/setup-python@v4
with:
python-version: '3.13'
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y \
x11-utils \
python3-tk \
python3-dev \
wmctrl \
xdotool \
libnss3-dev \
libgconf-2-4 \
libxss1 \
libasound2 \
libxtst6 \
libgtk-3-0 \
libgbm-dev \
libxshmfence1 \
libxrandr2 \
libpangocairo-1.0-0 \
libatk1.0-0 \
libcairo-gobject2 \
libgdk-pixbuf2.0-0 \
gnome-screenshot \
xvfb
- name: Setup script permissions
run: |
chmod +x autoqa/scripts/setup_permissions.sh || true
./autoqa/scripts/setup_permissions.sh || true
- name: Clean existing Jan installations
run: |
./autoqa/scripts/ubuntu_cleanup.sh
- name: Download OLD and NEW installers
run: |
set -e
# Download OLD installer using existing script
./autoqa/scripts/ubuntu_download.sh \
"${{ inputs.old_ubuntu_installer }}" \
"false" \
"" \
"" \
"" \
""
cp /tmp/jan-installer.deb /tmp/jan-old.deb
# Download NEW installer using existing script
./autoqa/scripts/ubuntu_download.sh \
"${{ inputs.new_ubuntu_installer }}" \
"false" \
"" \
"" \
"" \
""
cp /tmp/jan-installer.deb /tmp/jan-new.deb
echo "OLD_VERSION=/tmp/jan-old.deb" >> $GITHUB_ENV
echo "NEW_VERSION=/tmp/jan-new.deb" >> $GITHUB_ENV
- name: Install Python dependencies
working-directory: autoqa
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run migration tests (Ubuntu)
working-directory: autoqa
run: |
case="${{ inputs.migration_test_case }}"
caseArg=""
if [ -n "${case}" ]; then caseArg="--migration-test-case \"${case}\""; fi
xvfb-run -a python main.py --enable-migration-test --old-version "${OLD_VERSION}" --new-version "${NEW_VERSION}" --max-turns ${{ inputs.max_turns }} ${caseArg}
- name: Upload screen recordings
if: always()
uses: actions/upload-artifact@v4
continue-on-error: true
with:
name: migration-recordings-${{ github.run_number }}-ubuntu
path: autoqa/recordings/
- name: Upload trajectories
if: always()
uses: actions/upload-artifact@v4
continue-on-error: true
with:
name: migration-trajectories-${{ github.run_number }}-ubuntu
path: autoqa/trajectories/
- name: Cleanup after tests
if: always()
run: |
./autoqa/scripts/ubuntu_post_cleanup.sh "false"
migration-macos:
if: inputs.old_macos_installer != '' && inputs.new_macos_installer != ''
runs-on: macos-selfhosted-15-arm64-cua
timeout-minutes: 60
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Python 3.13
uses: actions/setup-python@v4
with:
python-version: '3.13'
- name: Setup script permissions
run: |
chmod +x autoqa/scripts/setup_permissions.sh || true
./autoqa/scripts/setup_permissions.sh || true
- name: Clean existing Jan installations
run: |
./autoqa/scripts/macos_cleanup.sh
- name: Download OLD and NEW installers
run: |
set -e
# Download OLD installer using existing script
./autoqa/scripts/macos_download.sh \
"${{ inputs.old_macos_installer }}" \
"false" \
"" \
"" \
"" \
""
cp /tmp/jan-installer.dmg /tmp/jan-old.dmg
# Download NEW installer using existing script
./autoqa/scripts/macos_download.sh \
"${{ inputs.new_macos_installer }}" \
"false" \
"" \
"" \
"" \
""
cp /tmp/jan-installer.dmg /tmp/jan-new.dmg
echo "OLD_VERSION=/tmp/jan-old.dmg" >> $GITHUB_ENV
echo "NEW_VERSION=/tmp/jan-new.dmg" >> $GITHUB_ENV
- name: Install Python dependencies
working-directory: autoqa
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run migration tests (macOS)
working-directory: autoqa
run: |
case="${{ inputs.migration_test_case }}"
caseArg=""
if [ -n "${case}" ]; then caseArg="--migration-test-case \"${case}\""; fi
python main.py --enable-migration-test --old-version "${OLD_VERSION}" --new-version "${NEW_VERSION}" --max-turns ${{ inputs.max_turns }} ${caseArg}
- name: Upload screen recordings
if: always()
uses: actions/upload-artifact@v4
continue-on-error: true
with:
name: migration-recordings-${{ github.run_number }}-macos
path: autoqa/recordings/
- name: Upload trajectories
if: always()
uses: actions/upload-artifact@v4
continue-on-error: true
with:
name: migration-trajectories-${{ github.run_number }}-macos
path: autoqa/trajectories/
- name: Cleanup after tests
if: always()
run: |
./autoqa/scripts/macos_post_cleanup.sh

121
.github/workflows/autoqa-reliability.yml vendored Normal file
View File

@ -0,0 +1,121 @@
name: AutoQA Reliability (Manual)
on:
workflow_dispatch:
inputs:
source_type:
description: 'App source type (url)'
required: true
type: choice
options: [url]
default: url
jan_app_windows_source:
description: 'Windows installer URL path (used when source_type=url or to select artifact)'
required: true
type: string
default: 'https://catalog.jan.ai/windows/Jan_0.6.8_x64-setup.exe'
jan_app_ubuntu_source:
description: 'Ubuntu .deb URL path'
required: true
type: string
default: 'https://delta.jan.ai/nightly/Jan-nightly_0.6.4-728_amd64.deb'
jan_app_macos_source:
description: 'macOS .dmg URL path'
required: true
type: string
default: 'https://delta.jan.ai/nightly/Jan-nightly_0.6.4-728_universal.dmg'
is_nightly:
description: 'Is the app a nightly build?'
required: true
type: boolean
default: true
reliability_phase:
description: 'Reliability phase'
required: true
type: choice
options: [development, deployment]
default: development
reliability_runs:
description: 'Custom runs (0 uses phase default)'
required: true
type: number
default: 0
reliability_test_path:
description: 'Test file path (relative to autoqa working directory)'
required: true
type: string
default: 'tests/base/settings/app-data.txt'
jobs:
reliability-windows:
runs-on: windows-11-nvidia-gpu
timeout-minutes: 60
env:
DEFAULT_JAN_APP_URL: 'https://catalog.jan.ai/windows/Jan_0.6.8_x64-setup.exe'
DEFAULT_IS_NIGHTLY: 'false'
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Python 3.13
uses: actions/setup-python@v4
with:
python-version: '3.13'
- name: Clean existing Jan installations
shell: powershell
run: |
.\autoqa\scripts\windows_cleanup.ps1 -IsNightly "${{ inputs.is_nightly }}"
- name: Download/Prepare Jan app
shell: powershell
run: |
.\autoqa\scripts\windows_download.ps1 `
-WorkflowInputUrl "${{ inputs.jan_app_windows_source }}" `
-WorkflowInputIsNightly "${{ inputs.is_nightly }}" `
-RepoVariableUrl "${{ vars.JAN_APP_URL }}" `
-RepoVariableIsNightly "${{ vars.IS_NIGHTLY }}" `
-DefaultUrl "$env:DEFAULT_JAN_APP_URL" `
-DefaultIsNightly "$env:DEFAULT_IS_NIGHTLY"
- name: Install Jan app
shell: powershell
run: |
.\autoqa\scripts\windows_install.ps1 -IsNightly "$env:IS_NIGHTLY"
- name: Install Python dependencies
working-directory: autoqa
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run reliability tests
working-directory: autoqa
shell: powershell
run: |
$runs = "${{ inputs.reliability_runs }}"
$runsArg = ""
if ([int]$runs -gt 0) { $runsArg = "--reliability-runs $runs" }
python main.py --enable-reliability-test --reliability-phase "${{ inputs.reliability_phase }}" --reliability-test-path "${{ inputs.reliability_test_path }}" $runsArg
- name: Upload screen recordings
if: always()
uses: actions/upload-artifact@v4
continue-on-error: true
with:
name: reliability-recordings-${{ github.run_number }}-${{ runner.os }}
path: autoqa/recordings/
- name: Upload trajectories
if: always()
uses: actions/upload-artifact@v4
continue-on-error: true
with:
name: reliability-trajectories-${{ github.run_number }}-${{ runner.os }}
path: autoqa/trajectories/
- name: Cleanup after tests
if: always()
shell: powershell
run: |
.\autoqa\scripts\windows_post_cleanup.ps1 -IsNightly "${{ inputs.is_nightly }}"

471
.github/workflows/autoqa-template.yml vendored Normal file
View File

@ -0,0 +1,471 @@
name: Auto QA Test Runner Template
on:
workflow_call:
inputs:
jan_app_windows_source:
description: 'Windows app source - can be URL or local path'
required: true
type: string
jan_app_ubuntu_source:
description: 'Ubuntu app source - can be URL or local path'
required: true
type: string
jan_app_macos_source:
description: 'macOS app source - can be URL or local path'
required: true
type: string
is_nightly:
description: 'Is this a nightly build?'
required: true
type: boolean
default: true
source_type:
description: 'Source type: url or local'
required: true
type: string
default: 'url'
artifact_name_windows:
description: 'Windows artifact name (only needed for local)'
required: false
type: string
default: ''
artifact_name_ubuntu:
description: 'Ubuntu artifact name (only needed for local)'
required: false
type: string
default: ''
artifact_name_macos:
description: 'macOS artifact name (only needed for local)'
required: false
type: string
default: ''
secrets:
RP_TOKEN:
description: 'ReportPortal API token'
required: true
jobs:
windows:
runs-on: windows-11-nvidia-gpu
timeout-minutes: 60
env:
DEFAULT_JAN_APP_URL: 'https://catalog.jan.ai/windows/Jan-nightly_0.6.5-758_x64-setup.exe'
DEFAULT_IS_NIGHTLY: 'true'
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Python 3.13
uses: actions/setup-python@v4
with:
python-version: '3.13'
- name: Download artifact (if source_type is local)
if: inputs.source_type == 'local'
uses: actions/download-artifact@v4
with:
name: ${{ inputs.artifact_name_windows }}
path: ${{ runner.temp }}/windows-artifact
- name: Clean existing Jan installations
shell: powershell
run: |
.\autoqa\scripts\windows_cleanup.ps1 -IsNightly "${{ inputs.is_nightly }}"
- name: Download/Prepare Jan app
shell: powershell
run: |
if ("${{ inputs.source_type }}" -eq "local") {
# Find the exe file in the artifact
$exeFile = Get-ChildItem -Path "${{ runner.temp }}/windows-artifact" -Recurse -Filter "*.exe" | Select-Object -First 1
if ($exeFile) {
Write-Host "[SUCCESS] Found local installer: $($exeFile.FullName)"
Copy-Item -Path $exeFile.FullName -Destination "$env:TEMP\jan-installer.exe" -Force
Write-Host "[SUCCESS] Installer copied to: $env:TEMP\jan-installer.exe"
# Don't set JAN_APP_PATH here - let the install script set it to the correct installed app path
echo "IS_NIGHTLY=${{ inputs.is_nightly }}" >> $env:GITHUB_ENV
} else {
Write-Error "[FAILED] No .exe file found in artifact"
exit 1
}
} else {
# Use the existing download script for URLs
.\autoqa\scripts\windows_download.ps1 `
-WorkflowInputUrl "${{ inputs.jan_app_windows_source }}" `
-WorkflowInputIsNightly "${{ inputs.is_nightly }}" `
-RepoVariableUrl "${{ vars.JAN_APP_URL }}" `
-RepoVariableIsNightly "${{ vars.IS_NIGHTLY }}" `
-DefaultUrl "$env:DEFAULT_JAN_APP_URL" `
-DefaultIsNightly "$env:DEFAULT_IS_NIGHTLY"
}
- name: Install Jan app
shell: powershell
run: |
.\autoqa\scripts\windows_install.ps1 -IsNightly "$env:IS_NIGHTLY"
- name: Install Python dependencies
working-directory: autoqa
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run Auto QA Tests
working-directory: autoqa
shell: powershell
env:
RP_TOKEN: ${{ secrets.RP_TOKEN }}
ENABLE_REPORTPORTAL: 'true'
RP_ENDPOINT: 'https://reportportal.menlo.ai'
RP_PROJECT: 'default_personal'
MAX_TURNS: '50'
DELAY_BETWEEN_TESTS: '3'
LAUNCH_NAME: 'CI AutoQA Run Windows - ${{ github.run_number }} - ${{ github.ref_name }}'
run: |
.\scripts\run_tests.ps1 -JanAppPath "$env:JAN_APP_PATH" -ProcessName "$env:JAN_PROCESS_NAME" -RpToken "$env:RP_TOKEN"
- name: Collect Jan logs for artifact upload
if: always()
shell: powershell
run: |
$logDirs = @(
"$env:APPDATA\Jan-nightly\data\logs",
"$env:APPDATA\Jan\data\logs"
)
$dest = "autoqa\jan-logs"
mkdir $dest -Force | Out-Null
foreach ($dir in $logDirs) {
if (Test-Path $dir) {
Copy-Item "$dir\*.log" $dest -Force -ErrorAction SilentlyContinue
}
}
- name: Upload screen recordings
if: always()
uses: actions/upload-artifact@v4
continue-on-error: true
with:
name: ${{ inputs.is_nightly && 'jan-nightly' || 'jan' }}-recordings-${{ github.run_number }}-${{ runner.os }}
path: autoqa/recordings/
- name: Upload Jan logs
if: always()
uses: actions/upload-artifact@v4
with:
name: ${{ inputs.is_nightly && 'jan-nightly' || 'jan' }}-logs-${{ github.run_number }}-${{ runner.os }}
path: autoqa/jan-logs/
- name: Cleanup after tests
if: always()
shell: powershell
run: |
.\autoqa\scripts\windows_post_cleanup.ps1 -IsNightly "${{ inputs.is_nightly }}"
ubuntu:
runs-on: ubuntu-22-04-nvidia-gpu
timeout-minutes: 60
env:
DEFAULT_JAN_APP_URL: 'https://delta.jan.ai/nightly/Jan-nightly_0.6.4-728_amd64.deb'
DEFAULT_IS_NIGHTLY: 'true'
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Python 3.13
uses: actions/setup-python@v4
with:
python-version: '3.13'
- name: Download artifact (if source_type is local)
if: inputs.source_type == 'local'
uses: actions/download-artifact@v4
with:
name: ${{ inputs.artifact_name_ubuntu }}
path: ${{ runner.temp }}/ubuntu-artifact
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y \
x11-utils \
python3-tk \
python3-dev \
wmctrl \
xdotool \
libnss3-dev \
libgconf-2-4 \
libxss1 \
libasound2 \
libxtst6 \
libgtk-3-0 \
libgbm-dev \
libxshmfence1 \
libxrandr2 \
libpangocairo-1.0-0 \
libatk1.0-0 \
libcairo-gobject2 \
libgdk-pixbuf2.0-0 \
gnome-screenshot
- name: Setup script permissions
run: |
chmod +x autoqa/scripts/setup_permissions.sh
./autoqa/scripts/setup_permissions.sh
- name: Clean existing Jan installations
run: |
./autoqa/scripts/ubuntu_cleanup.sh
- name: Download/Prepare Jan app
run: |
if [ "${{ inputs.source_type }}" = "local" ]; then
# Find the deb file in the artifact
DEB_FILE=$(find "${{ runner.temp }}/ubuntu-artifact" -name "*.deb" -type f | head -1)
if [ -n "$DEB_FILE" ]; then
echo "[SUCCESS] Found local installer: $DEB_FILE"
cp "$DEB_FILE" "/tmp/jan-installer.deb"
echo "[SUCCESS] Installer copied to: /tmp/jan-installer.deb"
echo "JAN_APP_PATH=/tmp/jan-installer.deb" >> $GITHUB_ENV
echo "IS_NIGHTLY=${{ inputs.is_nightly }}" >> $GITHUB_ENV
if [ "${{ inputs.is_nightly }}" = "true" ]; then
echo "JAN_PROCESS_NAME=Jan-nightly" >> $GITHUB_ENV
else
echo "JAN_PROCESS_NAME=Jan" >> $GITHUB_ENV
fi
else
echo "[FAILED] No .deb file found in artifact"
exit 1
fi
else
# Use the existing download script for URLs
./autoqa/scripts/ubuntu_download.sh \
"${{ inputs.jan_app_ubuntu_source }}" \
"${{ inputs.is_nightly }}" \
"${{ vars.JAN_APP_URL_LINUX }}" \
"${{ vars.IS_NIGHTLY }}" \
"$DEFAULT_JAN_APP_URL" \
"$DEFAULT_IS_NIGHTLY"
# Set the correct environment variables for the test runner
echo "JAN_APP_PATH=/tmp/jan-installer.deb" >> $GITHUB_ENV
if [ "${{ inputs.is_nightly }}" = "true" ]; then
echo "JAN_PROCESS_NAME=Jan-nightly" >> $GITHUB_ENV
else
echo "JAN_PROCESS_NAME=Jan" >> $GITHUB_ENV
fi
fi
- name: Install Jan app
run: |
./autoqa/scripts/ubuntu_install.sh "$IS_NIGHTLY"
- name: Install Python dependencies
working-directory: autoqa
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run Auto QA Tests
working-directory: autoqa
env:
RP_TOKEN: ${{ secrets.RP_TOKEN }}
ENABLE_REPORTPORTAL: 'true'
RP_ENDPOINT: 'https://reportportal.menlo.ai'
RP_PROJECT: 'default_personal'
MAX_TURNS: '50'
DELAY_BETWEEN_TESTS: '3'
LAUNCH_NAME: 'CI AutoQA Run Ubuntu - ${{ github.run_number }} - ${{ github.ref_name }}'
run: |
./scripts/run_tests.sh "$JAN_APP_PATH" "$JAN_PROCESS_NAME" "$RP_TOKEN" "ubuntu"
- name: Collect Jan logs for artifact upload
if: always()
run: |
mkdir -p autoqa/jan-logs
cp ~/.local/share/Jan-nightly/data/logs/*.log autoqa/jan-logs/ 2>/dev/null || true
cp ~/.local/share/Jan/data/logs/*.log autoqa/jan-logs/ 2>/dev/null || true
- name: Upload screen recordings
if: always()
uses: actions/upload-artifact@v4
continue-on-error: true
with:
name: ${{ inputs.is_nightly && 'jan-nightly' || 'jan' }}-recordings-${{ github.run_number }}-${{ runner.os }}
path: autoqa/recordings/
- name: Upload Jan logs
if: always()
uses: actions/upload-artifact@v4
with:
name: ${{ inputs.is_nightly && 'jan-nightly' || 'jan' }}-logs-${{ github.run_number }}-${{ runner.os }}
path: autoqa/jan-logs/
- name: Cleanup after tests
if: always()
run: |
./autoqa/scripts/ubuntu_post_cleanup.sh "$IS_NIGHTLY"
macos:
runs-on: macos-selfhosted-15-arm64-cua
timeout-minutes: 60
env:
DEFAULT_JAN_APP_URL: 'https://delta.jan.ai/nightly/Jan-nightly_0.6.4-728_universal.dmg'
DEFAULT_IS_NIGHTLY: 'true'
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Python 3.13
uses: actions/setup-python@v4
with:
python-version: '3.13'
- name: Download artifact (if source_type is local)
if: inputs.source_type == 'local'
uses: actions/download-artifact@v4
with:
name: ${{ inputs.artifact_name_macos }}
path: ${{ runner.temp }}/macos-artifact
- name: Setup script permissions
run: |
chmod +x autoqa/scripts/setup_permissions.sh
./autoqa/scripts/setup_permissions.sh
- name: Clean existing Jan installations
run: |
./autoqa/scripts/macos_cleanup.sh
- name: Download/Prepare Jan app
run: |
if [ "${{ inputs.source_type }}" = "local" ]; then
# Find the dmg file in the artifact
DMG_FILE=$(find "${{ runner.temp }}/macos-artifact" -name "*.dmg" -type f | head -1)
if [ -n "$DMG_FILE" ]; then
echo "[SUCCESS] Found local installer: $DMG_FILE"
cp "$DMG_FILE" "/tmp/jan-installer.dmg"
echo "[SUCCESS] Installer copied to: /tmp/jan-installer.dmg"
echo "JAN_APP_PATH=/tmp/jan-installer.dmg" >> $GITHUB_ENV
echo "IS_NIGHTLY=${{ inputs.is_nightly }}" >> $GITHUB_ENV
if [ "${{ inputs.is_nightly }}" = "true" ]; then
echo "PROCESS_NAME=Jan-nightly" >> $GITHUB_ENV
else
echo "PROCESS_NAME=Jan" >> $GITHUB_ENV
fi
else
echo "[FAILED] No .dmg file found in artifact"
exit 1
fi
else
# Use the existing download script for URLs
./autoqa/scripts/macos_download.sh \
"${{ inputs.jan_app_macos_source }}" \
"${{ inputs.is_nightly }}" \
"${{ vars.JAN_APP_URL }}" \
"${{ vars.IS_NIGHTLY }}" \
"$DEFAULT_JAN_APP_URL" \
"$DEFAULT_IS_NIGHTLY"
# Set the correct environment variables for the test runner
echo "JAN_APP_PATH=/tmp/jan-installer.dmg" >> $GITHUB_ENV
if [ "${{ inputs.is_nightly }}" = "true" ]; then
echo "PROCESS_NAME=Jan-nightly" >> $GITHUB_ENV
else
echo "PROCESS_NAME=Jan" >> $GITHUB_ENV
fi
fi
- name: Install Jan app
run: |
./autoqa/scripts/macos_install.sh
- name: Install system dependencies
run: |
echo "Installing system dependencies for macOS..."
# Check if Homebrew is available
if command -v brew >/dev/null 2>&1; then
echo "Homebrew is available"
# Install python-tk if not available
python3 -c "import tkinter" 2>/dev/null || {
echo "Installing python-tk via Homebrew..."
brew install python-tk || true
}
else
echo "Homebrew not available, checking if tkinter works..."
python3 -c "import tkinter" || {
echo "[WARNING] tkinter not available and Homebrew not found"
echo "This may cause issues with mouse control"
}
fi
echo "System dependencies check completed"
- name: Install Python dependencies
run: |
cd autoqa
echo "Installing Python dependencies..."
pip install --upgrade pip
pip install -r requirements.txt
echo "[SUCCESS] Python dependencies installed"
- name: Setup ReportPortal environment
run: |
echo "Setting up ReportPortal environment..."
echo "RP_TOKEN=${{ secrets.RP_TOKEN }}" >> $GITHUB_ENV
echo "ReportPortal environment configured"
- name: Run E2E tests
env:
RP_TOKEN: ${{ secrets.RP_TOKEN }}
ENABLE_REPORTPORTAL: 'true'
RP_ENDPOINT: 'https://reportportal.menlo.ai'
RP_PROJECT: 'default_personal'
MAX_TURNS: '50'
DELAY_BETWEEN_TESTS: '3'
LAUNCH_NAME: 'CI AutoQA Run Macos - ${{ github.run_number }} - ${{ github.ref_name }}'
run: |
cd autoqa
echo "Starting E2E test execution..."
echo "Environment variables:"
echo "JAN_APP_PATH: $JAN_APP_PATH"
echo "PROCESS_NAME: $PROCESS_NAME"
echo "IS_NIGHTLY: $IS_NIGHTLY"
./scripts/run_tests.sh "$JAN_APP_PATH" "$PROCESS_NAME" "$RP_TOKEN" "macos"
- name: Collect Jan logs for artifact upload
if: always()
run: |
mkdir -p autoqa/jan-logs
cp ~/Library/Application\ Support/Jan-nightly/data/logs/*.log autoqa/jan-logs/ 2>/dev/null || true
cp ~/Library/Application\ Support/Jan/data/logs/*.log autoqa/jan-logs/ 2>/dev/null || true
- name: Upload screen recordings
if: always()
uses: actions/upload-artifact@v4
continue-on-error: true
with:
name: ${{ inputs.is_nightly && 'jan-nightly' || 'jan' }}-recordings-${{ github.run_number }}-${{ runner.os }}
path: autoqa/recordings/
- name: Upload Jan logs
if: always()
uses: actions/upload-artifact@v4
with:
name: ${{ inputs.is_nightly && 'jan-nightly' || 'jan' }}-logs-${{ github.run_number }}-${{ runner.os }}
path: autoqa/jan-logs/
- name: Cleanup after tests
if: always()
run: |
./autoqa/scripts/macos_post_cleanup.sh

View File

@ -0,0 +1,31 @@
name: Claude Issue Dedupe
description: Automatically dedupe GitHub issues using Claude Code
on:
issues:
types: [opened]
workflow_dispatch:
inputs:
issue_number:
description: 'Issue number to process for duplicate detection'
required: true
type: string
jobs:
claude-dedupe-issues:
runs-on: ubuntu-latest
timeout-minutes: 10
permissions:
contents: read
issues: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Run Claude Code dedupe
uses: anthropics/claude-code-base-action@beta
with:
prompt: "/dedupe ${{ github.repository }}/issues/${{ github.event.issue.number || inputs.issue_number }}"
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
claude_env: |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

16
.github/workflows/issues.yaml vendored Normal file
View File

@ -0,0 +1,16 @@
name: Adds all issues to project board
on:
issues:
types:
- opened
jobs:
add-to-project:
name: Add issue to project
runs-on: ubuntu-latest
steps:
- uses: actions/add-to-project@v1.0.2
with:
project-url: https://github.com/orgs/${{ vars.ORG_NAME }}/projects/${{ vars.JAN_PROJECT_NUMBER }}
github-token: ${{ secrets.AUTO_ADD_TICKET_PAT }}

145
.github/workflows/jan-astro-docs.yml vendored Normal file
View File

@ -0,0 +1,145 @@
name: Jan Astro Docs
on:
push:
branches:
- dev
paths:
- 'website/**'
- '.github/workflows/jan-astro-docs.yml'
pull_request:
paths:
- 'website/**'
- '.github/workflows/jan-astro-docs.yml'
# Review gh actions docs if you want to further define triggers, paths, etc
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on
workflow_dispatch:
inputs:
update_cloud_spec:
description: 'Update Jan Server API specification'
required: false
default: 'false'
type: choice
options:
- 'true'
- 'false'
schedule:
# Run daily at 2 AM UTC to sync with Jan Server updates
- cron: '0 2 * * *'
jobs:
deploy:
name: Deploy to CloudFlare Pages
env:
CLOUDFLARE_PROJECT_NAME: astro-docs # docs.jan.ai
runs-on: ubuntu-latest
permissions:
contents: write
deployments: write
pull-requests: write
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 20
- uses: oven-sh/setup-bun@v2
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Fill env vars
continue-on-error: true
working-directory: website
run: |
env_example_file=".env.example"
touch .env
while IFS= read -r line || [[ -n "$line" ]]; do
if [[ "$line" == *"="* ]]; then
var_name=$(echo $line | cut -d '=' -f 1)
echo $var_name
var_value="$(jq -r --arg key "$var_name" '.[$key]' <<< "$SECRETS")"
echo "$var_name=$var_value" >> .env
fi
done < "$env_example_file"
env:
SECRETS: '${{ toJson(secrets) }}'
- name: Install dependencies
working-directory: website
run: bun install
- name: Update Jan Server API Spec (Scheduled/Manual)
if: github.event_name == 'schedule' || (github.event_name == 'workflow_dispatch' && github.event.inputs.update_cloud_spec == 'true')
working-directory: website
continue-on-error: true
run: |
echo "📡 Updating Jan Server API specification..."
bun run generate:cloud-spec
# Check if the spec file was updated
if git diff --quiet public/openapi/cloud-openapi.json; then
echo "✅ No changes to API specification"
else
echo "📝 API specification updated"
# Commit the changes if this is a scheduled run on main branch
if [ "${{ github.event_name }}" = "schedule" ] && [ "${{ github.ref }}" = "refs/heads/dev" ]; then
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git add public/openapi/cloud-openapi.json
git commit -m "chore: update Jan Server API specification [skip ci]"
git push
fi
fi
env:
JAN_SERVER_SPEC_URL: ${{ secrets.JAN_SERVER_SPEC_URL || 'https://api.jan.ai/api/swagger/doc.json' }}
JAN_SERVER_PROD_URL: ${{ secrets.JAN_SERVER_PROD_URL || 'https://api.jan.ai/v1' }}
- name: Build website
working-directory: website
run: |
# For PR and regular pushes, skip cloud spec generation in prebuild
# It will use the existing committed spec or fallback
if [ "${{ github.event_name }}" = "pull_request" ] || [ "${{ github.event_name }}" = "push" ]; then
echo "Using existing cloud spec for build"
export SKIP_CLOUD_SPEC_UPDATE=true
fi
bun run build
env:
SKIP_CLOUD_SPEC_UPDATE: ${{ github.event_name == 'pull_request' || github.event_name == 'push' }}
- name: copy redirects and headers
continue-on-error: true
working-directory: website
run: |
cp _redirects dist/_redirects
cp _headers dist/_headers
- name: Publish to Cloudflare Pages PR Preview and Staging
if: github.event_name == 'pull_request'
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: ${{ env.CLOUDFLARE_PROJECT_NAME }}
directory: ./website/dist
# Optional: Enable this if you want to have GitHub Deployments triggered
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
id: deployCloudflarePages
- uses: mshick/add-pr-comment@v2
if: github.event_name == 'pull_request'
with:
message: |
Preview URL Astro Docs: ${{ steps.deployCloudflarePages.outputs.url }}
- name: Publish to Cloudflare Pages Production
if: (github.event_name == 'push' && github.ref == 'refs/heads/dev') || (github.event_name == 'workflow_dispatch' && github.ref == 'refs/heads/dev')
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: ${{ env.CLOUDFLARE_PROJECT_NAME }}
directory: ./website/dist
branch: main
# Optional: Enable this if you want to have GitHub Deployments triggered
gitHubToken: ${{ secrets.GITHUB_TOKEN }}

View File

@ -1,63 +0,0 @@
name: Deploy Docs on new release
on:
release:
types:
- published
- edited
- released
jobs:
deploy:
name: Deploy to CloudFlare Pages
env:
CLOUDFLARE_PROJECT_NAME: docs
runs-on: ubuntu-latest
permissions:
contents: write
deployments: write
pull-requests: write
steps:
- uses: actions/checkout@v4
with:
ref: dev
- uses: actions/setup-node@v3
with:
node-version: 18
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Fill env vars
working-directory: docs
run: |
env_example_file=".env.example"
touch .env
while IFS= read -r line || [[ -n "$line" ]]; do
if [[ "$line" == *"="* ]]; then
var_name=$(echo $line | cut -d '=' -f 1)
echo $var_name
var_value="$(jq -r --arg key "$var_name" '.[$key]' <<< "$SECRETS")"
echo "$var_name=$var_value" >> .env
fi
done < "$env_example_file"
env:
SECRETS: '${{ toJson(secrets) }}'
- name: Install dependencies
working-directory: docs
run: yarn install
- name: Build website
working-directory: docs
run: export NODE_ENV=production && yarn build && cp _redirects out/_redirects
- name: Publish to Cloudflare Pages Production
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: ${{ env.CLOUDFLARE_PROJECT_NAME }}
directory: ./docs/out
branch: main
# Optional: Enable this if you want to have GitHub Deployments triggered
gitHubToken: ${{ secrets.GITHUB_TOKEN }}

View File

@ -26,10 +26,10 @@ jobs:
deployments: write
pull-requests: write
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version: 18
node-version: 20
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
@ -53,9 +53,12 @@ jobs:
- name: Install dependencies
working-directory: docs
run: yarn install
- name: Clean output directory
working-directory: docs
run: rm -rf out/* .next/*
- name: Build website
working-directory: docs
run: export NODE_ENV=production && yarn build && cp _redirects out/_redirects
run: export NODE_ENV=production && yarn build && cp _redirects out/_redirects && cp _headers out/_headers
- name: Publish to Cloudflare Pages PR Preview and Staging
if: github.event_name == 'pull_request'
@ -76,7 +79,7 @@ jobs:
Preview URL: ${{ steps.deployCloudflarePages.outputs.url }}
- name: Publish to Cloudflare Pages Production
if: (github.event_name == 'push' && github.ref == 'refs/heads/dev') || (github.event_name == 'workflow_dispatch' && github.ref == 'refs/heads/dev')
if: (github.event_name == 'push' && github.ref == 'refs/heads/dev') || (github.event_name == 'workflow_dispatch' && github.ref == 'refs/heads/dev') || (github.event_name == 'workflow_dispatch' && startsWith(github.ref, 'refs/heads/release/'))
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}

View File

@ -1,110 +0,0 @@
name: Electron Builder - Beta Build
on:
push:
tags: ["v[0-9]+.[0-9]+.[0-9]+-rc[0-9]+-beta"]
jobs:
# Job create Update app version based on latest release tag with build number and save to output
get-update-version:
uses: ./.github/workflows/template-get-update-version.yml
create-draft-release:
runs-on: ubuntu-latest
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
outputs:
upload_url: ${{ steps.create_release.outputs.upload_url }}
version: ${{ steps.get_version.outputs.version }}
permissions:
contents: write
steps:
- name: Extract tag name without v prefix
id: get_version
run: echo "VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV && echo "::set-output name=version::${GITHUB_REF#refs/tags/v}"
env:
GITHUB_REF: ${{ github.ref }}
- name: Create Draft Release
id: create_release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.ref_name }}
token: ${{ secrets.GITHUB_TOKEN }}
name: "${{ env.VERSION }}"
draft: true
prerelease: false
generate_release_notes: true
build-macos:
uses: ./.github/workflows/template-build-macos.yml
secrets: inherit
needs: [get-update-version]
with:
ref: ${{ github.ref }}
public_provider: github
new_version: ${{ needs.get-update-version.outputs.new_version }}
beta: true
build-windows-x64:
uses: ./.github/workflows/template-build-windows-x64.yml
secrets: inherit
needs: [get-update-version]
with:
ref: ${{ github.ref }}
public_provider: github
new_version: ${{ needs.get-update-version.outputs.new_version }}
beta: true
build-linux-x64:
uses: ./.github/workflows/template-build-linux-x64.yml
secrets: inherit
needs: [get-update-version]
with:
ref: ${{ github.ref }}
public_provider: github
new_version: ${{ needs.get-update-version.outputs.new_version }}
beta: true
sync-temp-to-latest:
needs: [build-macos, create-draft-release, build-windows-x64, build-linux-x64]
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Getting the repo
uses: actions/checkout@v3
- name: Sync temp to latest
run: |
# sync temp-beta to beta by copy files that are different or new
aws s3 sync "s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-beta/" "s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/beta/"
env:
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: ${{ secrets.DELTA_AWS_REGION }}
AWS_EC2_METADATA_DISABLED: "true"
- name: set release to prerelease
run: |
gh release edit v${{ needs.create-draft-release.outputs.version }} --draft=false --prerelease
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
noti-discord-and-update-url-readme:
needs: [build-macos, create-draft-release, build-windows-x64, build-linux-x64, sync-temp-to-latest]
runs-on: ubuntu-latest
steps:
- name: Set version to environment variable
run: |
echo "VERSION=${{ needs.create-draft-release.outputs.version }}" >> $GITHUB_ENV
- name: Notify Discord
uses: Ilshidur/action-discord@master
with:
args: |
Jan-beta App version {{ VERSION }}, has been released, use the following links to download the app with faster speed or visit the Github release page for more information:
- Windows: https://delta.jan.ai/beta/jan-beta-win-x64-{{ VERSION }}.exe
- macOS Universal: https://delta.jan.ai/beta/jan-beta-mac-universal-{{ VERSION }}.dmg
- Linux Deb: https://delta.jan.ai/beta/jan-beta-linux-amd64-{{ VERSION }}.deb
- Linux AppImage: https://delta.jan.ai/beta/jan-beta-linux-x86_64-{{ VERSION }}.AppImage
- Github Release URL: https://github.com/janhq/jan/releases/tag/v{{ VERSION }}
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK_JAN_BETA }}

View File

@ -1,144 +0,0 @@
name: Electron Builder - Nightly / Manual
on:
schedule:
- cron: '0 20 * * 1,2,3' # At 8 PM UTC on Monday, Tuesday, and Wednesday which is 3 AM UTC+7 Tuesday, Wednesday, and Thursday
workflow_dispatch:
inputs:
public_provider:
type: choice
description: 'Public Provider'
options:
- none
- aws-s3
default: none
pull_request_review:
types: [submitted]
jobs:
set-public-provider:
runs-on: ubuntu-latest
outputs:
public_provider: ${{ steps.set-public-provider.outputs.public_provider }}
ref: ${{ steps.set-public-provider.outputs.ref }}
steps:
- name: Set public provider
id: set-public-provider
run: |
if [ "${{ github.event_name }}" == "workflow_dispatch" ]; then
echo "::set-output name=public_provider::${{ github.event.inputs.public_provider }}"
echo "::set-output name=ref::${{ github.ref }}"
else
if [ "${{ github.event_name }}" == "schedule" ]; then
echo "::set-output name=public_provider::aws-s3"
echo "::set-output name=ref::refs/heads/dev"
elif [ "${{ github.event_name }}" == "push" ]; then
echo "::set-output name=public_provider::aws-s3"
echo "::set-output name=ref::${{ github.ref }}"
elif [ "${{ github.event_name }}" == "pull_request_review" ]; then
echo "::set-output name=public_provider::none"
echo "::set-output name=ref::${{ github.ref }}"
else
echo "::set-output name=public_provider::none"
echo "::set-output name=ref::${{ github.ref }}"
fi
fi
# Job create Update app version based on latest release tag with build number and save to output
get-update-version:
uses: ./.github/workflows/template-get-update-version.yml
build-macos:
uses: ./.github/workflows/template-build-macos.yml
needs: [get-update-version, set-public-provider]
secrets: inherit
with:
ref: ${{ needs.set-public-provider.outputs.ref }}
public_provider: ${{ needs.set-public-provider.outputs.public_provider }}
new_version: ${{ needs.get-update-version.outputs.new_version }}
build-windows-x64:
uses: ./.github/workflows/template-build-windows-x64.yml
secrets: inherit
needs: [get-update-version, set-public-provider]
with:
ref: ${{ needs.set-public-provider.outputs.ref }}
public_provider: ${{ needs.set-public-provider.outputs.public_provider }}
new_version: ${{ needs.get-update-version.outputs.new_version }}
build-linux-x64:
uses: ./.github/workflows/template-build-linux-x64.yml
secrets: inherit
needs: [get-update-version, set-public-provider]
with:
ref: ${{ needs.set-public-provider.outputs.ref }}
public_provider: ${{ needs.set-public-provider.outputs.public_provider }}
new_version: ${{ needs.get-update-version.outputs.new_version }}
sync-temp-to-latest:
needs: [set-public-provider, build-windows-x64, build-linux-x64, build-macos]
runs-on: ubuntu-latest
steps:
- name: Sync temp to latest
if: ${{ needs.set-public-provider.outputs.public_provider == 'aws-s3' }}
run: |
aws s3 sync s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-nightly/ s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/nightly/
env:
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: ${{ secrets.DELTA_AWS_REGION }}
AWS_EC2_METADATA_DISABLED: "true"
noti-discord-nightly-and-update-url-readme:
needs: [build-macos, build-windows-x64, build-linux-x64, get-update-version, set-public-provider, sync-temp-to-latest]
secrets: inherit
if: github.event_name == 'schedule'
uses: ./.github/workflows/template-noti-discord-and-update-url-readme.yml
with:
ref: refs/heads/dev
build_reason: Nightly
push_to_branch: dev
new_version: ${{ needs.get-update-version.outputs.new_version }}
noti-discord-pre-release-and-update-url-readme:
needs: [build-macos, build-windows-x64, build-linux-x64, get-update-version, set-public-provider, sync-temp-to-latest]
secrets: inherit
if: github.event_name == 'push'
uses: ./.github/workflows/template-noti-discord-and-update-url-readme.yml
with:
ref: refs/heads/dev
build_reason: Pre-release
push_to_branch: dev
new_version: ${{ needs.get-update-version.outputs.new_version }}
noti-discord-manual-and-update-url-readme:
needs: [build-macos, build-windows-x64, build-linux-x64, get-update-version, set-public-provider, sync-temp-to-latest]
secrets: inherit
if: github.event_name == 'workflow_dispatch' && github.event.inputs.public_provider == 'aws-s3'
uses: ./.github/workflows/template-noti-discord-and-update-url-readme.yml
with:
ref: refs/heads/dev
build_reason: Manual
push_to_branch: dev
new_version: ${{ needs.get-update-version.outputs.new_version }}
comment-pr-build-url:
needs: [build-macos, build-windows-x64, build-linux-x64, get-update-version, set-public-provider, sync-temp-to-latest]
runs-on: ubuntu-latest
if: github.event_name == 'pull_request_review'
steps:
- name: Set up GitHub CLI
run: |
curl -sSL https://github.com/cli/cli/releases/download/v2.33.0/gh_2.33.0_linux_amd64.tar.gz | tar xz
sudo cp gh_2.33.0_linux_amd64/bin/gh /usr/local/bin/
- name: Comment build URL on PR
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
PR_URL=${{ github.event.pull_request.html_url }}
RUN_ID=${{ github.run_id }}
COMMENT="This is the build for this pull request. You can download it from the Artifacts section here: [Build URL](https://github.com/${{ github.repository }}/actions/runs/${RUN_ID})."
gh pr comment $PR_URL --body "$COMMENT"

View File

@ -1,85 +0,0 @@
name: Electron Builder - Tag
on:
push:
tags: ["v[0-9]+.[0-9]+.[0-9]+"]
jobs:
# Job create Update app version based on latest release tag with build number and save to output
get-update-version:
uses: ./.github/workflows/template-get-update-version.yml
create-draft-release:
runs-on: ubuntu-latest
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
outputs:
upload_url: ${{ steps.create_release.outputs.upload_url }}
version: ${{ steps.get_version.outputs.version }}
permissions:
contents: write
steps:
- name: Extract tag name without v prefix
id: get_version
run: echo "VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV && echo "::set-output name=version::${GITHUB_REF#refs/tags/v}"
env:
GITHUB_REF: ${{ github.ref }}
- name: Create Draft Release
id: create_release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.ref_name }}
token: ${{ secrets.GITHUB_TOKEN }}
name: "${{ env.VERSION }}"
draft: true
prerelease: false
build-macos:
uses: ./.github/workflows/template-build-macos.yml
secrets: inherit
needs: [get-update-version]
with:
ref: ${{ github.ref }}
public_provider: github
new_version: ${{ needs.get-update-version.outputs.new_version }}
build-windows-x64:
uses: ./.github/workflows/template-build-windows-x64.yml
secrets: inherit
needs: [get-update-version]
with:
ref: ${{ github.ref }}
public_provider: github
new_version: ${{ needs.get-update-version.outputs.new_version }}
build-linux-x64:
uses: ./.github/workflows/template-build-linux-x64.yml
secrets: inherit
needs: [get-update-version]
with:
ref: ${{ github.ref }}
public_provider: github
new_version: ${{ needs.get-update-version.outputs.new_version }}
update_release_draft:
needs: [build-macos, build-windows-x64, build-linux-x64]
permissions:
# write permission is required to create a github release
contents: write
# write permission is required for autolabeler
# otherwise, read permission is required at least
pull-requests: write
runs-on: ubuntu-latest
steps:
# (Optional) GitHub Enterprise requires GHE_HOST variable set
#- name: Set GHE_HOST
# run: |
# echo "GHE_HOST=${GITHUB_SERVER_URL##https:\/\/}" >> $GITHUB_ENV
# Drafts your next Release notes as Pull Requests are merged into "master"
- uses: release-drafter/release-drafter@v5
# (Optional) specify config name to use, relative to .github/. Default: release-drafter.yml
# with:
# config-name: my-config.yml
# disable-autolabeler: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

View File

@ -1,379 +0,0 @@
name: Test - Linter & Playwright
on:
workflow_dispatch:
push:
branches:
- main
- dev
paths:
- 'electron/**'
- .github/workflows/jan-electron-linter-and-test.yml
- 'web/**'
- 'joi/**'
- 'package.json'
- 'node_modules/**'
- 'yarn.lock'
- 'core/**'
- 'extensions/**'
- '!README.md'
- 'Makefile'
pull_request:
branches:
- main
- dev
- release/**
paths:
- 'electron/**'
- .github/workflows/jan-electron-linter-and-test.yml
- 'web/**'
- 'joi/**'
- 'package.json'
- 'node_modules/**'
- 'yarn.lock'
- 'Makefile'
- 'extensions/**'
- 'core/**'
- '!README.md'
jobs:
base_branch_cov:
runs-on: ubuntu-latest
continue-on-error: true
steps:
- uses: actions/checkout@v3
with:
ref: ${{ github.base_ref }}
- name: Use Node.js 20.x
uses: actions/setup-node@v3
with:
node-version: 20
- name: Install dependencies
run: |
make config-yarn
yarn
yarn build:joi
yarn build:core
- name: Run test coverage
run: yarn test:coverage
- name: Upload code coverage for ref branch
uses: actions/upload-artifact@v4
with:
name: ref-lcov.info
path: ./coverage/lcov.info
test-on-macos:
if: (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) || github.event_name == 'push' || github.event_name == 'workflow_dispatch'
runs-on: macos-latest
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Installing node
uses: actions/setup-node@v3
with:
node-version: 20
- name: Set IS_TEST environment variable
run: |
echo "IS_TEST=true" >> $GITHUB_ENV
- name: 'Cleanup cache'
continue-on-error: true
run: |
rm -rf ~/jan
make clean
- name: Get Commit Message for PR
if: github.event_name == 'pull_request'
run: |
echo "REPORT_PORTAL_DESCRIPTION=${{github.event.after}})" >> $GITHUB_ENV
- name: Get Commit Message for push event
if: github.event_name == 'push'
run: |
echo "REPORT_PORTAL_DESCRIPTION=${{github.sha}})" >> $GITHUB_ENV
# - name: 'Config report portal'
# run: |
# make update-playwright-config REPORT_PORTAL_URL=${{ secrets.REPORT_PORTAL_URL }} REPORT_PORTAL_API_KEY=${{ secrets.REPORT_PORTAL_API_KEY }} REPORT_PORTAL_PROJECT_NAME=${{ secrets.REPORT_PORTAL_PROJECT_NAME }} REPORT_PORTAL_LAUNCH_NAME="Jan App macos" REPORT_PORTAL_DESCRIPTION="${{env.REPORT_PORTAL_DESCRIPTION}}"
- name: Linter and test
run: |
make test
env:
CSC_IDENTITY_AUTO_DISCOVERY: 'false'
test-on-macos-pr-target:
if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository
runs-on: macos-latest
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Installing node
uses: actions/setup-node@v3
with:
node-version: 20
- name: 'Cleanup cache'
continue-on-error: true
run: |
rm -rf ~/jan
make clean
- name: Linter and test
run: |
make test
env:
CSC_IDENTITY_AUTO_DISCOVERY: 'false'
test-on-windows:
if: github.event_name == 'push'
strategy:
fail-fast: false
matrix:
antivirus-tools: ['mcafee', 'default-windows-security', 'bit-defender']
runs-on: windows-desktop-${{ matrix.antivirus-tools }}
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Installing node
uses: actions/setup-node@v3
with:
node-version: 20
# Clean cache, continue on error
- name: 'Cleanup cache'
shell: powershell
continue-on-error: true
run: |
$path = "$Env:APPDATA\jan"
if (Test-Path $path) {
Remove-Item "\\?\$path" -Recurse -Force
} else {
Write-Output "Folder does not exist."
}
make clean
- name: Get Commit Message for push event
if: github.event_name == 'push'
shell: bash
run: |
echo "REPORT_PORTAL_DESCRIPTION=${{github.sha}}" >> $GITHUB_ENV
# - name: 'Config report portal'
# shell: bash
# run: |
# make update-playwright-config REPORT_PORTAL_URL=${{ secrets.REPORT_PORTAL_URL }} REPORT_PORTAL_API_KEY=${{ secrets.REPORT_PORTAL_API_KEY }} REPORT_PORTAL_PROJECT_NAME=${{ secrets.REPORT_PORTAL_PROJECT_NAME }} REPORT_PORTAL_LAUNCH_NAME="Jan App Windows ${{ matrix.antivirus-tools }}" REPORT_PORTAL_DESCRIPTION="${{env.REPORT_PORTAL_DESCRIPTION}}"
- name: Linter and test
shell: powershell
run: |
make test
test-on-windows-pr:
if: (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) || github.event_name == 'workflow_dispatch'
runs-on: windows-latest
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Installing node
uses: actions/setup-node@v3
with:
node-version: 20
# Clean cache, continue on error
- name: 'Cleanup cache'
shell: powershell
continue-on-error: true
run: |
$path = "$Env:APPDATA\jan"
if (Test-Path $path) {
Remove-Item "\\?\$path" -Recurse -Force
} else {
Write-Output "Folder does not exist."
}
make clean
- name: Get Commit Message for PR
if: github.event_name == 'pull_request'
shell: bash
run: |
echo "REPORT_PORTAL_DESCRIPTION=${{github.event.after}}" >> $GITHUB_ENV
# - name: 'Config report portal'
# shell: bash
# run: |
# make update-playwright-config REPORT_PORTAL_URL=${{ secrets.REPORT_PORTAL_URL }} REPORT_PORTAL_API_KEY=${{ secrets.REPORT_PORTAL_API_KEY }} REPORT_PORTAL_PROJECT_NAME=${{ secrets.REPORT_PORTAL_PROJECT_NAME }} REPORT_PORTAL_LAUNCH_NAME="Jan App Windows" REPORT_PORTAL_DESCRIPTION="${{env.REPORT_PORTAL_DESCRIPTION}}"
- name: Linter and test
shell: powershell
run: |
make test
test-on-windows-pr-target:
if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository
runs-on: windows-latest
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Installing node
uses: actions/setup-node@v1
with:
node-version: 20
# Clean cache, continue on error
- name: 'Cleanup cache'
shell: powershell
continue-on-error: true
run: |
$path = "$Env:APPDATA\jan"
if (Test-Path $path) {
Remove-Item "\\?\$path" -Recurse -Force
} else {
Write-Output "Folder does not exist."
}
make clean
- name: Linter and test
shell: powershell
run: |
make test
test-on-ubuntu:
runs-on: ubuntu-latest
if: (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) || github.event_name == 'push' || github.event_name == 'workflow_dispatch'
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Installing node
uses: actions/setup-node@v3
with:
node-version: 20
- name: 'Cleanup cache'
continue-on-error: true
run: |
rm -rf ~/jan
make clean
- name: Get Commit Message for PR
if: github.event_name == 'pull_request'
run: |
echo "REPORT_PORTAL_DESCRIPTION=${{github.event.after}}" >> $GITHUB_ENV
- name: Get Commit Message for push event
if: github.event_name == 'push'
run: |
echo "REPORT_PORTAL_DESCRIPTION=${{github.sha}}" >> $GITHUB_ENV
# - name: 'Config report portal'
# shell: bash
# run: |
# make update-playwright-config REPORT_PORTAL_URL=${{ secrets.REPORT_PORTAL_URL }} REPORT_PORTAL_API_KEY=${{ secrets.REPORT_PORTAL_API_KEY }} REPORT_PORTAL_PROJECT_NAME=${{ secrets.REPORT_PORTAL_PROJECT_NAME }} REPORT_PORTAL_LAUNCH_NAME="Jan App Linux" REPORT_PORTAL_DESCRIPTION="${{env.REPORT_PORTAL_DESCRIPTION}}"
- name: Linter and test
run: |
export DISPLAY=$(w -h | awk 'NR==1 {print $2}')
echo -e "Display ID: $DISPLAY"
make test
- uses: actions/upload-artifact@v4
if: always()
with:
name: playwright-report
path: electron/playwright-report/
retention-days: 2
coverage-check:
runs-on: ubuntu-latest
needs: base_branch_cov
if: (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) || github.event_name == 'push' || github.event_name == 'workflow_dispatch'
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Installing node
uses: actions/setup-node@v3
with:
node-version: 20
- name: Install yarn
run: npm install -g yarn
- name: 'Cleanup cache'
continue-on-error: true
run: |
rm -rf ~/jan
make clean
- name: Download code coverage report from base branch
uses: actions/download-artifact@v4
with:
name: ref-lcov.info
- name: Linter and test coverage
run: |
export DISPLAY=$(w -h | awk 'NR==1 {print $2}')
echo -e "Display ID: $DISPLAY"
make lint
yarn build:test
yarn test:coverage
- name: Generate Code Coverage report
id: code-coverage
uses: barecheck/code-coverage-action@v1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
lcov-file: './coverage/lcov.info'
base-lcov-file: './lcov.info'
send-summary-comment: true
show-annotations: 'warning'
test-on-ubuntu-pr-target:
runs-on: ubuntu-latest
if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Installing node
uses: actions/setup-node@v3
with:
node-version: 20
- name: 'Cleanup cache'
continue-on-error: true
run: |
rm -rf ~/jan
make clean
- name: Linter and test
run: |
export DISPLAY=$(w -h | awk 'NR==1 {print $2}')
echo -e "Display ID: $DISPLAY"
make test

View File

@ -0,0 +1,257 @@
name: Linter & Test
on:
workflow_dispatch:
push:
branches:
- main
- dev
paths:
- .github/workflows/jan-linter-and-test.yml
- 'web/**'
- 'joi/**'
- 'package.json'
- 'node_modules/**'
- 'yarn.lock'
- 'core/**'
- 'extensions/**'
- '!README.md'
- 'Makefile'
pull_request:
branches:
- main
- dev
- release/**
paths:
- .github/workflows/jan-linter-and-test.yml
- 'web/**'
- 'joi/**'
- 'package.json'
- 'node_modules/**'
- 'yarn.lock'
- 'Makefile'
- 'extensions/**'
- 'core/**'
- 'src-tauri/**'
- 'web-app/**'
- '!README.md'
jobs:
base_branch_cov:
if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository
runs-on: ubuntu-latest
continue-on-error: true
steps:
- uses: actions/checkout@v3
with:
ref: ${{ github.base_ref }}
- name: Use Node.js 20.x
uses: actions/setup-node@v3
with:
node-version: 20
- name: 'Cleanup cache'
continue-on-error: true
run: |
rm -rf ~/jan
make clean
- name: Install dependencies
run: |
make lint
- name: Run test coverage
run: |
yarn test:coverage
- name: Upload code coverage for ref branch
uses: actions/upload-artifact@v4
with:
name: ref-lcov.info
path: coverage/lcov.info
test-on-macos:
runs-on: ${{ (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository) && 'macos-latest' || 'macos-selfhosted-15-arm64' }}
if: github.event_name == 'pull_request' || github.event_name == 'push' || github.event_name == 'workflow_dispatch'
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Installing node
uses: actions/setup-node@v3
with:
node-version: 20
- name: 'Cleanup cache'
continue-on-error: true
run: |
rm -rf ~/jan
make clean
- name: Linter and test
run: |
make test
env:
CSC_IDENTITY_AUTO_DISCOVERY: 'false'
test-on-windows:
if: github.event_name == 'push'
strategy:
fail-fast: false
matrix:
antivirus-tools: ['mcafee', 'default-windows-security', 'bit-defender']
runs-on: windows-desktop-${{ matrix.antivirus-tools }}
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Installing node
uses: actions/setup-node@v3
with:
node-version: 20
# Clean cache, continue on error
- name: 'Cleanup cache'
shell: powershell
continue-on-error: true
run: |
$path = "$Env:APPDATA\jan"
if (Test-Path $path) {
Remove-Item "\\?\$path" -Recurse -Force
} else {
Write-Output "Folder does not exist."
}
make clean
- name: Linter and test
shell: powershell
run: |
make test
test-on-windows-pr:
if: github.event_name == 'pull_request' || github.event_name == 'workflow_dispatch'
runs-on: 'windows-latest'
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: install dependencies
run: |
choco install --yes --no-progress make
- name: Installing node
uses: actions/setup-node@v3
with:
node-version: 20
- name: 'Cleanup cache'
shell: powershell
continue-on-error: true
run: |
$path = "$Env:APPDATA\jan"
if (Test-Path $path) {
Remove-Item "\\?\$path" -Recurse -Force
} else {
Write-Output "Folder does not exist."
}
make clean
- name: Install WebView2 Runtime (Bootstrapper)
shell: powershell
run: |
Invoke-WebRequest -Uri 'https://go.microsoft.com/fwlink/p/?LinkId=2124703' -OutFile 'setup.exe'
Start-Process -FilePath setup.exe -Verb RunAs -Wait
- name: Linter and test
shell: powershell
run: |
make test
env:
NODE_OPTIONS: '--max-old-space-size=2048'
test-on-ubuntu:
runs-on: ${{ (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository) && 'ubuntu-latest' || 'ubuntu-latest' }}
if: github.event_name == 'pull_request' || github.event_name == 'push' || github.event_name == 'workflow_dispatch'
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Installing node
uses: actions/setup-node@v3
with:
node-version: 20
- name: Install Tauri dependencies
run: |
sudo apt update
sudo apt install -y libglib2.0-dev libatk1.0-dev libpango1.0-dev libgtk-3-dev libsoup-3.0-dev libwebkit2gtk-4.1-dev librsvg2-dev libfuse2 webkit2gtk-driver
- name: 'Cleanup cache'
continue-on-error: true
run: |
rm -rf ~/jan
make clean
- name: Linter and test
run: |
export DISPLAY=$(w -h | awk 'NR==1 {print $2}')
echo -e "Display ID: $DISPLAY"
make test
- uses: actions/upload-artifact@v4
if: always()
with:
name: playwright-report
path: electron/playwright-report/
retention-days: 2
coverage-check:
if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository
runs-on: ubuntu-latest
needs: base_branch_cov
continue-on-error: true
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Installing node
uses: actions/setup-node@v3
with:
node-version: 20
- name: 'Cleanup cache'
continue-on-error: true
run: |
rm -rf ~/jan
make clean
- name: Install dependencies
run: |
make lint
- name: Run test coverage
run: |
yarn test:coverage
- name: Download code coverage report from base branch
uses: actions/download-artifact@v4
with:
name: ref-lcov.info
- name: Generate Code Coverage report
id: code-coverage
uses: barecheck/code-coverage-action@v1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
lcov-file: './coverage/lcov.info'
base-lcov-file: './lcov.info'
send-summary-comment: true
show-annotations: 'warning'

View File

@ -0,0 +1,60 @@
name: Jan Web Server build image and push to Harbor Registry
on:
push:
branches:
- dev-web
pull_request:
branches:
- dev-web
jobs:
build-and-preview:
runs-on: [ubuntu-24-04-docker]
env:
MENLO_PLATFORM_BASE_URL: "https://api-dev.jan.ai/v1"
permissions:
pull-requests: write
contents: write
steps:
- name: Checkout source repo
uses: actions/checkout@v4
- name: Login to Harbor Registry
uses: docker/login-action@v3
with:
registry: registry.menlo.ai
username: ${{ secrets.HARBOR_USERNAME }}
password: ${{ secrets.HARBOR_PASSWORD }}
- name: Install dependencies
run: |
(type -p wget >/dev/null || (sudo apt update && sudo apt install wget -y)) \
&& sudo mkdir -p -m 755 /etc/apt/keyrings \
&& out=$(mktemp) && wget -nv -O$out https://cli.github.com/packages/githubcli-archive-keyring.gpg \
&& cat $out | sudo tee /etc/apt/keyrings/githubcli-archive-keyring.gpg > /dev/null \
&& sudo chmod go+r /etc/apt/keyrings/githubcli-archive-keyring.gpg \
&& sudo mkdir -p -m 755 /etc/apt/sources.list.d \
&& echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | sudo tee /etc/apt/sources.list.d/github-cli.list > /dev/null \
&& sudo apt update
sudo apt-get install -y jq gettext
- name: Set image tag
id: vars
run: |
if [[ "${{ github.event_name }}" == "pull_request" ]]; then
IMAGE_TAG="web:preview-${{ github.sha }}"
else
IMAGE_TAG="web:dev-${{ github.sha }}"
fi
echo "IMAGE_TAG=${IMAGE_TAG}" >> $GITHUB_OUTPUT
echo "FULL_IMAGE=registry.menlo.ai/jan-server/${IMAGE_TAG}" >> $GITHUB_OUTPUT
- name: Build docker image
run: |
docker build --build-arg MENLO_PLATFORM_BASE_URL=${{ env.MENLO_PLATFORM_BASE_URL }} -t ${{ steps.vars.outputs.FULL_IMAGE }} .
- name: Push docker image
if: github.event_name == 'push'
run: |
docker push ${{ steps.vars.outputs.FULL_IMAGE }}

View File

@ -0,0 +1,58 @@
name: Jan Web Server deploy to production
on:
push:
branches:
- prod-web
jobs:
build-and-deploy:
runs-on: ubuntu-latest
permissions:
contents: write
deployments: write
pull-requests: write
env:
MENLO_PLATFORM_BASE_URL: "https://api.jan.ai/v1"
GA_MEASUREMENT_ID: "G-YK53MX8M8M"
CLOUDFLARE_PROJECT_NAME: "jan-server-web"
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version: 20
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
# - name: Fill env vars
# run: |
# env_example_file=".env.example"
# touch .env
# while IFS= read -r line || [[ -n "$line" ]]; do
# if [[ "$line" == *"="* ]]; then
# var_name=$(echo $line | cut -d '=' -f 1)
# echo $var_name
# var_value="$(jq -r --arg key "$var_name" '.[$key]' <<< "$SECRETS")"
# echo "$var_name=$var_value" >> .env
# fi
# done < "$env_example_file"
# env:
# SECRETS: '${{ toJson(secrets) }}'
- name: Install dependencies
run: make config-yarn && yarn install && yarn build:core && make build-web-app
env:
MENLO_PLATFORM_BASE_URL: ${{ env.MENLO_PLATFORM_BASE_URL }}
GA_MEASUREMENT_ID: ${{ env.GA_MEASUREMENT_ID }}
- name: Publish to Cloudflare Pages Production
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: ${{ env.CLOUDFLARE_PROJECT_NAME }}
directory: ./web-app/dist-web
branch: main
# Optional: Enable this if you want to have GitHub Deployments triggered
gitHubToken: ${{ secrets.GITHUB_TOKEN }}

View File

@ -0,0 +1,60 @@
name: Jan Web Server build image and push to Harbor Registry
on:
push:
branches:
- stag-web
pull_request:
branches:
- stag-web
jobs:
build-and-preview:
runs-on: [ubuntu-24-04-docker]
env:
MENLO_PLATFORM_BASE_URL: "https://api-stag.jan.ai/v1"
permissions:
pull-requests: write
contents: write
steps:
- name: Checkout source repo
uses: actions/checkout@v4
- name: Login to Harbor Registry
uses: docker/login-action@v3
with:
registry: registry.menlo.ai
username: ${{ secrets.HARBOR_USERNAME }}
password: ${{ secrets.HARBOR_PASSWORD }}
- name: Install dependencies
run: |
(type -p wget >/dev/null || (sudo apt update && sudo apt install wget -y)) \
&& sudo mkdir -p -m 755 /etc/apt/keyrings \
&& out=$(mktemp) && wget -nv -O$out https://cli.github.com/packages/githubcli-archive-keyring.gpg \
&& cat $out | sudo tee /etc/apt/keyrings/githubcli-archive-keyring.gpg > /dev/null \
&& sudo chmod go+r /etc/apt/keyrings/githubcli-archive-keyring.gpg \
&& sudo mkdir -p -m 755 /etc/apt/sources.list.d \
&& echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | sudo tee /etc/apt/sources.list.d/github-cli.list > /dev/null \
&& sudo apt update
sudo apt-get install -y jq gettext
- name: Set image tag
id: vars
run: |
if [[ "${{ github.event_name }}" == "pull_request" ]]; then
IMAGE_TAG="web:preview-${{ github.sha }}"
else
IMAGE_TAG="web:stag-${{ github.sha }}"
fi
echo "IMAGE_TAG=${IMAGE_TAG}" >> $GITHUB_OUTPUT
echo "FULL_IMAGE=registry.menlo.ai/jan-server/${IMAGE_TAG}" >> $GITHUB_OUTPUT
- name: Build docker image
run: |
docker build --build-arg MENLO_PLATFORM_BASE_URL=${{ env.MENLO_PLATFORM_BASE_URL }} -t ${{ steps.vars.outputs.FULL_IMAGE }} .
- name: Push docker image
if: github.event_name == 'push'
run: |
docker push ${{ steps.vars.outputs.FULL_IMAGE }}

View File

@ -0,0 +1,156 @@
name: Tauri Builder - Beta Build
on:
push:
tags: ["v[0-9]+.[0-9]+.[0-9]+-rc[0-9]+-beta"]
jobs:
# Job create Update app version based on latest release tag with build number and save to output
get-update-version:
uses: ./.github/workflows/template-get-update-version.yml
create-draft-release:
runs-on: ubuntu-latest
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
outputs:
upload_url: ${{ steps.create_release.outputs.upload_url }}
version: ${{ steps.get_version.outputs.version }}
permissions:
contents: write
steps:
- name: Extract tag name without v prefix
id: get_version
run: echo "VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV && echo "::set-output name=version::${GITHUB_REF#refs/tags/v}"
env:
GITHUB_REF: ${{ github.ref }}
- name: Create Draft Release
id: create_release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.ref_name }}
token: ${{ secrets.GITHUB_TOKEN }}
name: "${{ env.VERSION }}"
draft: true
prerelease: false
generate_release_notes: true
build-macos:
uses: ./.github/workflows/template-tauri-build-macos.yml
secrets: inherit
needs: [get-update-version, create-draft-release]
with:
ref: ${{ github.ref }}
public_provider: github
new_version: ${{ needs.get-update-version.outputs.new_version }}
channel: beta
cortex_api_port: "39271"
upload_url: ${{ needs.create-draft-release.outputs.upload_url }}
build-windows-x64:
uses: ./.github/workflows/template-tauri-build-windows-x64.yml
secrets: inherit
needs: [get-update-version, create-draft-release]
with:
ref: ${{ github.ref }}
public_provider: github
new_version: ${{ needs.get-update-version.outputs.new_version }}
channel: beta
cortex_api_port: "39271"
upload_url: ${{ needs.create-draft-release.outputs.upload_url }}
build-linux-x64:
uses: ./.github/workflows/template-tauri-build-linux-x64.yml
secrets: inherit
needs: [get-update-version, create-draft-release]
with:
ref: ${{ github.ref }}
public_provider: github
new_version: ${{ needs.get-update-version.outputs.new_version }}
channel: beta
cortex_api_port: "39271"
upload_url: ${{ needs.create-draft-release.outputs.upload_url }}
sync-temp-to-latest:
needs: [create-draft-release, get-update-version, build-macos, build-windows-x64, build-linux-x64]
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Getting the repo
uses: actions/checkout@v3
- name: create latest.json file
run: |
VERSION=${{ needs.get-update-version.outputs.new_version }}
PUB_DATE=$(date -u +"%Y-%m-%dT%H:%M:%S.%3NZ")
LINUX_SIGNATURE="${{ needs.build-linux-x64.outputs.APPIMAGE_SIG }}"
LINUX_URL="https://delta.jan.ai/beta/${{ needs.build-linux-x64.outputs.APPIMAGE_FILE_NAME }}"
WINDOWS_SIGNATURE="${{ needs.build-windows-x64.outputs.WIN_SIG }}"
WINDOWS_URL="https://delta.jan.ai/beta/${{ needs.build-windows-x64.outputs.FILE_NAME }}"
DARWIN_SIGNATURE="${{ needs.build-macos.outputs.MAC_UNIVERSAL_SIG }}"
DARWIN_URL="https://delta.jan.ai/beta/Jan-beta_${{ needs.get-update-version.outputs.new_version }}.app.tar.gz"
jq --arg version "$VERSION" \
--arg pub_date "$PUB_DATE" \
--arg linux_signature "$LINUX_SIGNATURE" \
--arg linux_url "$LINUX_URL" \
--arg windows_signature "$WINDOWS_SIGNATURE" \
--arg windows_url "$WINDOWS_URL" \
--arg darwin_arm_signature "$DARWIN_SIGNATURE" \
--arg darwin_arm_url "$DARWIN_URL" \
--arg darwin_amd_signature "$DARWIN_SIGNATURE" \
--arg darwin_amd_url "$DARWIN_URL" \
'.version = $version
| .pub_date = $pub_date
| .platforms["linux-x86_64"].signature = $linux_signature
| .platforms["linux-x86_64"].url = $linux_url
| .platforms["windows-x86_64"].signature = $windows_signature
| .platforms["windows-x86_64"].url = $windows_url
| .platforms["darwin-aarch64"].signature = $darwin_arm_signature
| .platforms["darwin-aarch64"].url = $darwin_arm_url
| .platforms["darwin-x86_64"].signature = $darwin_amd_signature
| .platforms["darwin-x86_64"].url = $darwin_amd_url' \
src-tauri/latest.json.template > latest.json
cat latest.json
- name: Sync temp to latest
run: |
# sync temp-beta to beta by copy files that are different or new
aws s3 cp ./latest.json s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-beta/latest.json
aws s3 sync "s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-beta/" "s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/beta/"
env:
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: ${{ secrets.DELTA_AWS_REGION }}
AWS_EC2_METADATA_DISABLED: "true"
- name: Upload release assert if public provider is github
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
uses: actions/upload-release-asset@v1.0.1
with:
upload_url: ${{ needs.create-draft-release.outputs.upload_url }}
asset_path: ./latest.json
asset_name: latest.json
asset_content_type: text/json
noti-discord-and-update-url-readme:
needs: [build-macos, get-update-version, build-windows-x64, build-linux-x64, sync-temp-to-latest]
runs-on: ubuntu-latest
steps:
- name: Set version to environment variable
run: |
VERSION=${{ needs.get-update-version.outputs.new_version }}
VERSION="${VERSION#v}"
echo "VERSION=$VERSION" >> $GITHUB_ENV
- name: Notify Discord
uses: Ilshidur/action-discord@master
with:
args: |
Jan-beta App version {{ VERSION }}, has been released, use the following links to download the app with faster speed or visit the Github release page for more information:
- Windows: https://delta.jan.ai/beta/Jan-beta_{{ VERSION }}_x64-setup.exe
- macOS Universal: https://delta.jan.ai/beta/Jan-beta_{{ VERSION }}_universal.dmg
- Linux Deb: https://delta.jan.ai/beta/Jan-beta_{{ VERSION }}_amd64.deb
- Linux AppImage: https://delta.jan.ai/beta/Jan-beta_{{ VERSION }}_amd64.AppImage
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK_JAN_BETA }}

View File

@ -0,0 +1,20 @@
name: Tauri Builder Flatpak
on:
workflow_dispatch:
inputs:
version:
description: 'Version to build. For example: 0.6.8'
required: false
jobs:
build-linux-x64:
uses: ./.github/workflows/template-tauri-build-linux-x64-flatpak.yml
secrets: inherit
with:
ref: ${{ github.ref }}
public_provider: none
channel: stable
new_version: ${{ inputs.version }}
disable_updater: true

View File

@ -0,0 +1,46 @@
name: Tauri Builder - Nightly / External PRs
on:
pull_request:
branches:
- dev
paths:
- '.github/workflows/jan-tauri-build-nightly-external.yaml'
- '.github/workflows/template-tauri-build-*-external.yml'
- 'src-tauri/**'
- 'core/**'
- 'web-app/**'
- 'extensions/**'
- 'scripts/**'
- 'pre-install/**'
- 'Makefile'
- 'package.json'
jobs:
get-update-version:
uses: ./.github/workflows/template-get-update-version.yml
build-macos:
uses: ./.github/workflows/template-tauri-build-macos-external.yml
needs: [get-update-version]
with:
ref: ${{ github.ref }}
new_version: ${{ needs.get-update-version.outputs.new_version }}
channel: nightly
build-windows-x64:
uses: ./.github/workflows/template-tauri-build-windows-x64-external.yml
needs: [get-update-version]
with:
ref: ${{ github.ref }}
new_version: ${{ needs.get-update-version.outputs.new_version }}
channel: nightly
build-linux-x64:
uses: ./.github/workflows/template-tauri-build-linux-x64-external.yml
needs: [get-update-version]
with:
ref: ${{ github.ref }}
new_version: ${{ needs.get-update-version.outputs.new_version }}
channel: nightly
disable_updater: false

View File

@ -0,0 +1,253 @@
name: Tauri Builder - Nightly / Manual
on:
schedule:
- cron: '0 20 * * 1,2,3' # At 8 PM UTC on Monday, Tuesday, and Wednesday which is 3 AM UTC+7 Tuesday, Wednesday, and Thursday
workflow_dispatch:
inputs:
public_provider:
type: choice
description: 'Public Provider'
options:
- none
- aws-s3
default: none
disable_updater:
type: boolean
description: 'If true, builds both .deb and .appimage but disables auto-updater'
default: false
pull_request:
branches:
- release/**
- dev
paths:
- '.github/workflows/jan-tauri-build-nightly.yaml'
- '.github/workflows/template-get-update-version.yml'
- '.github/workflows/template-tauri-build-macos.yml'
- '.github/workflows/template-tauri-build-windows-x64.yml'
- '.github/workflows/template-tauri-build-linux-x64.yml'
- '.github/workflows/template-noti-discord-and-update-url-readme.yml'
- 'src-tauri/**'
- 'core/**'
- 'web-app/**'
- 'extensions/**'
- 'scripts/**'
- 'pre-install/**'
- 'Makefile'
- 'package.json'
jobs:
set-public-provider:
runs-on: ubuntu-latest
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository
outputs:
public_provider: ${{ steps.set-public-provider.outputs.public_provider }}
ref: ${{ steps.set-public-provider.outputs.ref }}
steps:
- name: Set public provider
id: set-public-provider
run: |
if [ "${{ github.event_name }}" == "workflow_dispatch" ]; then
echo "::set-output name=public_provider::${{ github.event.inputs.public_provider }}"
echo "::set-output name=ref::${{ github.ref }}"
else
if [ "${{ github.event_name }}" == "schedule" ]; then
echo "::set-output name=public_provider::aws-s3"
echo "::set-output name=ref::refs/heads/dev"
elif [ "${{ github.event_name }}" == "push" ]; then
echo "::set-output name=public_provider::aws-s3"
echo "::set-output name=ref::${{ github.ref }}"
elif [ "${{ github.event_name }}" == "pull_request_review" ]; then
echo "::set-output name=public_provider::none"
echo "::set-output name=ref::${{ github.ref }}"
else
echo "::set-output name=public_provider::none"
echo "::set-output name=ref::${{ github.ref }}"
fi
fi
# Job create Update app version based on latest release tag with build number and save to output
get-update-version:
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository
uses: ./.github/workflows/template-get-update-version.yml
build-macos:
uses: ./.github/workflows/template-tauri-build-macos.yml
needs: [get-update-version, set-public-provider]
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository
secrets: inherit
with:
ref: ${{ needs.set-public-provider.outputs.ref }}
public_provider: ${{ needs.set-public-provider.outputs.public_provider }}
new_version: ${{ needs.get-update-version.outputs.new_version }}
channel: nightly
cortex_api_port: '39261'
build-windows-x64:
uses: ./.github/workflows/template-tauri-build-windows-x64.yml
secrets: inherit
needs: [get-update-version, set-public-provider]
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository
with:
ref: ${{ needs.set-public-provider.outputs.ref }}
public_provider: ${{ needs.set-public-provider.outputs.public_provider }}
new_version: ${{ needs.get-update-version.outputs.new_version }}
channel: nightly
cortex_api_port: '39261'
build-linux-x64:
uses: ./.github/workflows/template-tauri-build-linux-x64.yml
secrets: inherit
needs: [get-update-version, set-public-provider]
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository
with:
ref: ${{ needs.set-public-provider.outputs.ref }}
public_provider: ${{ needs.set-public-provider.outputs.public_provider }}
new_version: ${{ needs.get-update-version.outputs.new_version }}
channel: nightly
cortex_api_port: '39261'
disable_updater: ${{ github.event.inputs.disable_updater == 'true' }}
sync-temp-to-latest:
needs:
[
get-update-version,
set-public-provider,
build-windows-x64,
build-linux-x64,
build-macos,
]
runs-on: ubuntu-latest
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository
steps:
- name: Getting the repo
uses: actions/checkout@v3
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: create latest.json file
run: |
VERSION=${{ needs.get-update-version.outputs.new_version }}
PUB_DATE=$(date -u +"%Y-%m-%dT%H:%M:%S.%3NZ")
LINUX_SIGNATURE="${{ needs.build-linux-x64.outputs.APPIMAGE_SIG }}"
LINUX_URL="https://delta.jan.ai/nightly/${{ needs.build-linux-x64.outputs.APPIMAGE_FILE_NAME }}"
WINDOWS_SIGNATURE="${{ needs.build-windows-x64.outputs.WIN_SIG }}"
WINDOWS_URL="https://delta.jan.ai/nightly/${{ needs.build-windows-x64.outputs.FILE_NAME }}"
DARWIN_SIGNATURE="${{ needs.build-macos.outputs.MAC_UNIVERSAL_SIG }}"
DARWIN_URL="https://delta.jan.ai/nightly/Jan-nightly_${{ needs.get-update-version.outputs.new_version }}.app.tar.gz"
jq --arg version "$VERSION" \
--arg pub_date "$PUB_DATE" \
--arg linux_signature "$LINUX_SIGNATURE" \
--arg linux_url "$LINUX_URL" \
--arg windows_signature "$WINDOWS_SIGNATURE" \
--arg windows_url "$WINDOWS_URL" \
--arg darwin_arm_signature "$DARWIN_SIGNATURE" \
--arg darwin_arm_url "$DARWIN_URL" \
--arg darwin_amd_signature "$DARWIN_SIGNATURE" \
--arg darwin_amd_url "$DARWIN_URL" \
'.version = $version
| .pub_date = $pub_date
| .platforms["linux-x86_64"].signature = $linux_signature
| .platforms["linux-x86_64"].url = $linux_url
| .platforms["windows-x86_64"].signature = $windows_signature
| .platforms["windows-x86_64"].url = $windows_url
| .platforms["darwin-aarch64"].signature = $darwin_arm_signature
| .platforms["darwin-aarch64"].url = $darwin_arm_url
| .platforms["darwin-x86_64"].signature = $darwin_amd_signature
| .platforms["darwin-x86_64"].url = $darwin_amd_url' \
src-tauri/latest.json.template > latest.json
cat latest.json
- name: Sync temp to latest
if: ${{ needs.set-public-provider.outputs.public_provider == 'aws-s3' }}
run: |
aws s3 cp ./latest.json s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-nightly/latest.json
aws s3 sync s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-nightly/ s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/nightly/
env:
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: ${{ secrets.DELTA_AWS_REGION }}
AWS_EC2_METADATA_DISABLED: 'true'
# noti-discord-nightly-and-update-url-readme:
# needs:
# [
# build-macos,
# build-windows-x64,
# build-linux-x64,
# get-update-version,
# set-public-provider,
# sync-temp-to-latest,
# ]
# secrets: inherit
# if: github.event_name == 'schedule'
# uses: ./.github/workflows/template-noti-discord-and-update-url-readme.yml
# with:
# ref: refs/heads/dev
# build_reason: Nightly
# push_to_branch: dev
# new_version: ${{ needs.get-update-version.outputs.new_version }}
# noti-discord-pre-release-and-update-url-readme:
# needs:
# [
# build-macos,
# build-windows-x64,
# build-linux-x64,
# get-update-version,
# set-public-provider,
# sync-temp-to-latest,
# ]
# secrets: inherit
# if: github.event_name == 'push'
# uses: ./.github/workflows/template-noti-discord-and-update-url-readme.yml
# with:
# ref: refs/heads/dev
# build_reason: Pre-release
# push_to_branch: dev
# new_version: ${{ needs.get-update-version.outputs.new_version }}
# noti-discord-manual-and-update-url-readme:
# needs:
# [
# build-macos,
# build-windows-x64,
# build-linux-x64,
# get-update-version,
# set-public-provider,
# sync-temp-to-latest,
# ]
# secrets: inherit
# if: github.event_name == 'workflow_dispatch' && github.event.inputs.public_provider == 'aws-s3'
# uses: ./.github/workflows/template-noti-discord-and-update-url-readme.yml
# with:
# ref: refs/heads/dev
# build_reason: Manual
# push_to_branch: dev
# new_version: ${{ needs.get-update-version.outputs.new_version }}
comment-pr-build-url:
needs:
[
build-macos,
build-windows-x64,
build-linux-x64,
get-update-version,
set-public-provider,
sync-temp-to-latest,
]
runs-on: ubuntu-latest
if: github.event_name == 'pull_request_review'
steps:
- name: Set up GitHub CLI
run: |
curl -sSL https://github.com/cli/cli/releases/download/v2.33.0/gh_2.33.0_linux_amd64.tar.gz | tar xz
sudo cp gh_2.33.0_linux_amd64/bin/gh /usr/local/bin/
- name: Comment build URL on PR
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
PR_URL=${{ github.event.pull_request.html_url }}
RUN_ID=${{ github.run_id }}
COMMENT="This is the build for this pull request. You can download it from the Artifacts section here: [Build URL](https://github.com/${{ github.repository }}/actions/runs/${RUN_ID})."
gh pr comment $PR_URL --body "$COMMENT"

122
.github/workflows/jan-tauri-build.yaml vendored Normal file
View File

@ -0,0 +1,122 @@
name: Tauri Builder - Tag
on:
push:
tags: ["v[0-9]+.[0-9]+.[0-9]+"]
jobs:
# Job create Update app version based on latest release tag with build number and save to output
get-update-version:
uses: ./.github/workflows/template-get-update-version.yml
create-draft-release:
runs-on: ubuntu-latest
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
outputs:
upload_url: ${{ steps.create_release.outputs.upload_url }}
version: ${{ steps.get_version.outputs.version }}
permissions:
contents: write
steps:
- name: Extract tag name without v prefix
id: get_version
run: echo "VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV && echo "::set-output name=version::${GITHUB_REF#refs/tags/v}"
env:
GITHUB_REF: ${{ github.ref }}
- name: Create Draft Release
id: create_release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.ref_name }}
token: ${{ secrets.GITHUB_TOKEN }}
name: "${{ env.VERSION }}"
draft: true
prerelease: false
generate_release_notes: true
build-macos:
uses: ./.github/workflows/template-tauri-build-macos.yml
secrets: inherit
needs: [get-update-version, create-draft-release]
with:
ref: ${{ github.ref }}
public_provider: github
channel: stable
new_version: ${{ needs.get-update-version.outputs.new_version }}
upload_url: ${{ needs.create-draft-release.outputs.upload_url }}
build-windows-x64:
uses: ./.github/workflows/template-tauri-build-windows-x64.yml
secrets: inherit
needs: [get-update-version, create-draft-release]
with:
ref: ${{ github.ref }}
public_provider: github
channel: stable
new_version: ${{ needs.get-update-version.outputs.new_version }}
upload_url: ${{ needs.create-draft-release.outputs.upload_url }}
build-linux-x64:
uses: ./.github/workflows/template-tauri-build-linux-x64.yml
secrets: inherit
needs: [get-update-version, create-draft-release]
with:
ref: ${{ github.ref }}
public_provider: github
channel: stable
new_version: ${{ needs.get-update-version.outputs.new_version }}
upload_url: ${{ needs.create-draft-release.outputs.upload_url }}
sync-temp-to-latest:
needs: [create-draft-release, get-update-version, build-macos, build-windows-x64, build-linux-x64]
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Getting the repo
uses: actions/checkout@v3
- name: create latest.json file
run: |
VERSION=${{ needs.get-update-version.outputs.new_version }}
PUB_DATE=$(date -u +"%Y-%m-%dT%H:%M:%S.%3NZ")
LINUX_SIGNATURE="${{ needs.build-linux-x64.outputs.APPIMAGE_SIG }}"
LINUX_URL="https://github.com/janhq/jan/releases/download/v${{ needs.get-update-version.outputs.new_version }}/${{ needs.build-linux-x64.outputs.APPIMAGE_FILE_NAME }}"
WINDOWS_SIGNATURE="${{ needs.build-windows-x64.outputs.WIN_SIG }}"
WINDOWS_URL="https://github.com/janhq/jan/releases/download/v${{ needs.get-update-version.outputs.new_version }}/${{ needs.build-windows-x64.outputs.FILE_NAME }}"
DARWIN_SIGNATURE="${{ needs.build-macos.outputs.MAC_UNIVERSAL_SIG }}"
DARWIN_URL="https://github.com/janhq/jan/releases/download/v${{ needs.get-update-version.outputs.new_version }}/${{ needs.build-macos.outputs.TAR_NAME }}"
jq --arg version "$VERSION" \
--arg pub_date "$PUB_DATE" \
--arg linux_signature "$LINUX_SIGNATURE" \
--arg linux_url "$LINUX_URL" \
--arg windows_signature "$WINDOWS_SIGNATURE" \
--arg windows_url "$WINDOWS_URL" \
--arg darwin_arm_signature "$DARWIN_SIGNATURE" \
--arg darwin_arm_url "$DARWIN_URL" \
--arg darwin_amd_signature "$DARWIN_SIGNATURE" \
--arg darwin_amd_url "$DARWIN_URL" \
'.version = $version
| .pub_date = $pub_date
| .platforms["linux-x86_64"].signature = $linux_signature
| .platforms["linux-x86_64"].url = $linux_url
| .platforms["windows-x86_64"].signature = $windows_signature
| .platforms["windows-x86_64"].url = $windows_url
| .platforms["darwin-aarch64"].signature = $darwin_arm_signature
| .platforms["darwin-aarch64"].url = $darwin_arm_url
| .platforms["darwin-x86_64"].signature = $darwin_amd_signature
| .platforms["darwin-x86_64"].url = $darwin_amd_url' \
src-tauri/latest.json.template > latest.json
cat latest.json
- name: Upload release assert if public provider is github
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
uses: actions/upload-release-asset@v1.0.1
with:
upload_url: ${{ needs.create-draft-release.outputs.upload_url }}
asset_path: ./latest.json
asset_name: latest.json
asset_content_type: text/json

View File

@ -1,127 +0,0 @@
name: Nightly Update cortex cpp
on:
schedule:
- cron: '30 19 * * 1-5' # At 01:30 on every day-of-week from Monday through Friday UTC +7
workflow_dispatch:
jobs:
update-submodule:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
actions: write
outputs:
pr_number: ${{ steps.check-update.outputs.pr_number }}
pr_created: ${{ steps.check-update.outputs.pr_created }}
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
submodules: recursive
ref: dev
fetch-depth: 0
token: ${{ secrets.PAT_SERVICE_ACCOUNT }}
- name: Configure Git
run: |
git config --global user.name 'github-actions[bot]'
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
- name: Update submodule to latest release
id: check-update
env:
GITHUB_TOKEN: ${{ secrets.PAT_SERVICE_ACCOUNT }}
run: |
curl -s https://api.github.com/repos/janhq/cortex/releases > /tmp/github_api_releases.json
latest_prerelease_name=$(cat /tmp/github_api_releases.json | jq -r '.[] | select(.prerelease) | .name' | head -n 1)
get_asset_count() {
local version_name=$1
cat /tmp/github_api_releases.json | jq -r --arg version_name "$version_name" '.[] | select(.name == $version_name) | .assets | length'
}
cortex_cpp_version_file_path="extensions/inference-nitro-extension/bin/version.txt"
current_version_name=$(cat "$cortex_cpp_version_file_path" | head -n 1)
current_version_asset_count=$(get_asset_count "$current_version_name")
latest_prerelease_asset_count=$(get_asset_count "$latest_prerelease_name")
if [ "$current_version_name" = "$latest_prerelease_name" ]; then
echo "cortex cpp remote repo doesn't have update today, skip update cortex.cpp for today nightly build"
echo "::set-output name=pr_created::false"
exit 0
fi
if [ "$current_version_asset_count" != "$latest_prerelease_asset_count" ]; then
echo "Latest prerelease version has different number of assets, somethink went wrong, skip update cortex.cpp for today nightly build"
echo "::set-output name=pr_created::false"
exit 1
fi
echo $latest_prerelease_name > $cortex_cpp_version_file_path
echo "Updated version from $current_version_name to $latest_prerelease_name."
echo "::set-output name=pr_created::true"
git add -f $cortex_cpp_version_file_path
git commit -m "Update cortex cpp nightly to version $latest_prerelease_name"
branch_name="update-nightly-$(date +'%Y-%m-%d-%H-%M')"
git checkout -b $branch_name
git push origin $branch_name
pr_title="Update cortex cpp nightly to version $latest_prerelease_name"
pr_body="This PR updates the Update cortex cpp nightly to version $latest_prerelease_name"
gh pr create --title "$pr_title" --body "$pr_body" --head $branch_name --base dev --reviewer Van-QA
pr_number=$(gh pr list --head $branch_name --json number --jq '.[0].number')
echo "::set-output name=pr_number::$pr_number"
check-and-merge-pr:
needs: update-submodule
if: needs.update-submodule.outputs.pr_created == 'true'
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
submodules: recursive
fetch-depth: 0
token: ${{ secrets.PAT_SERVICE_ACCOUNT }}
- name: Wait for CI to pass
env:
GITHUB_TOKEN: ${{ secrets.PAT_SERVICE_ACCOUNT }}
run: |
pr_number=${{ needs.update-submodule.outputs.pr_number }}
while true; do
ci_completed=$(gh pr checks $pr_number --json completedAt --jq '.[].completedAt')
if echo "$ci_completed" | grep -q "0001-01-01T00:00:00Z"; then
echo "CI is still running, waiting..."
sleep 60
else
echo "CI has completed, checking states..."
ci_states=$(gh pr checks $pr_number --json state --jq '.[].state')
if echo "$ci_states" | grep -vqE "SUCCESS|SKIPPED"; then
echo "CI failed, exiting..."
exit 1
else
echo "CI passed, merging PR..."
break
fi
fi
done
- name: Merge the PR
env:
GITHUB_TOKEN: ${{ secrets.PAT_SERVICE_ACCOUNT }}
run: |
pr_number=${{ needs.update-submodule.outputs.pr_number }}
gh pr merge $pr_number --merge --admin

View File

@ -1,18 +1,16 @@
name: Publish core Package to npmjs
on:
push:
tags: ["v[0-9]+.[0-9]+.[0-9]+-core"]
paths: ["core/**", ".github/workflows/publish-npm-core.yml"]
pull_request:
paths: ["core/**", ".github/workflows/publish-npm-core.yml"]
tags: ['v[0-9]+.[0-9]+.[0-9]+-core']
paths: ['core/**', '.github/workflows/publish-npm-core.yml']
workflow_dispatch:
jobs:
build-and-publish-plugins:
environment: production
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: "0"
fetch-depth: '0'
token: ${{ secrets.PAT_SERVICE_ACCOUNT }}
- name: Install jq
@ -24,7 +22,7 @@ jobs:
env:
GITHUB_REF: ${{ github.ref }}
- name: "Get Semantic Version from tag"
- name: 'Get Semantic Version from tag'
if: github.event_name == 'push'
run: |
# Get the tag from the event
@ -42,8 +40,8 @@ jobs:
# Setup .npmrc file to publish to npm
- uses: actions/setup-node@v3
with:
node-version: "20.x"
registry-url: "https://registry.npmjs.org"
node-version: '20.x'
registry-url: 'https://registry.npmjs.org'
- run: cd core && corepack enable && corepack prepare yarn@4.5.3 --activate && yarn --version && yarn config set -H enableImmutableInstalls false && yarn install && yarn build

View File

@ -1,53 +0,0 @@
name: Publish joi Package to npmjs
on:
push:
tags: ["v[0-9]+.[0-9]+.[0-9]+-joi"]
paths: ["joi/**", ".github/workflows/publish-npm-joi.yml"]
pull_request:
paths: ["joi/**", ".github/workflows/publish-npm-joi.yml"]
jobs:
build-and-publish-plugins:
environment: production
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: "0"
token: ${{ secrets.PAT_SERVICE_ACCOUNT }}
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Extract tag name without v prefix
id: get_version
run: echo "VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV && echo "::set-output name=version::${GITHUB_REF#refs/tags/v}"
env:
GITHUB_REF: ${{ github.ref }}
- name: "Get Semantic Version from tag"
if: github.event_name == 'push'
run: |
# Get the tag from the event
tag=${GITHUB_REF#refs/tags/v}
# remove the -joi suffix
new_version=$(echo $tag | sed -n 's/-joi//p')
echo $new_version
# Replace the old version with the new version in package.json
jq --arg version "$new_version" '.version = $version' joi/package.json > /tmp/package.json && mv /tmp/package.json joi/package.json
# Print the new version
echo "Updated package.json version to: $new_version"
cat joi/package.json
# Setup .npmrc file to publish to npm
- uses: actions/setup-node@v3
with:
node-version: "20.x"
registry-url: "https://registry.npmjs.org"
- run: cd joi && corepack enable && corepack prepare yarn@4.5.3 --activate && yarn --version && yarn config set -H enableImmutableInstalls false && yarn install && yarn build
- run: cd joi && yarn publish --access public
if: github.event_name == 'push'
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

View File

@ -1,39 +0,0 @@
name: build-jan-server
on:
workflow_call:
inputs:
dockerfile_path:
required: false
type: string
default: './Dockerfile'
docker_image_tag:
required: true
type: string
default: 'ghcr.io/janhq/jan-server:dev-latest'
jobs:
build:
runs-on: ubuntu-latest
env:
REGISTRY: ghcr.io
IMAGE_NAME: janhq/jan-server
permissions:
packages: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Log in to the Container registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push Docker image
uses: docker/build-push-action@v3
with:
context: .
file: ${{ inputs.dockerfile_path }}
push: true
tags: ${{ inputs.docker_image_tag }}

View File

@ -1,155 +0,0 @@
name: build-linux-x64
on:
workflow_call:
inputs:
ref:
required: true
type: string
default: 'refs/heads/main'
public_provider:
required: true
type: string
default: none
description: 'none: build only, github: build and publish to github, aws s3: build and publish to aws s3'
new_version:
required: true
type: string
default: ''
aws_s3_prefix:
required: false
type: string
default: '/latest/'
beta:
required: false
type: boolean
default: false
secrets:
DELTA_AWS_S3_BUCKET_NAME:
required: false
DELTA_AWS_ACCESS_KEY_ID:
required: false
DELTA_AWS_SECRET_ACCESS_KEY:
required: false
jobs:
build-linux-x64:
runs-on: ubuntu-latest
environment: production
permissions:
contents: write
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Installing node
uses: actions/setup-node@v1
with:
node-version: 20
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Update app version base public_provider
if: inputs.public_provider != 'github'
run: |
echo "Version: ${{ inputs.new_version }}"
# Update the version in electron/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' web/package.json > /tmp/package.json
mv /tmp/package.json web/package.json
jq '.build.publish = [{"provider": "generic", "url": "https://delta.jan.ai/nightly", "channel": "latest"}, {"provider": "s3", "acl": null, "bucket": "${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}", "region": "${{ secrets.DELTA_AWS_REGION}}", "path": "temp-nightly", "channel": "latest"}]' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
cat electron/package.json
chmod +x .github/scripts/rename-app.sh
.github/scripts/rename-app.sh ./electron/package.json nightly
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json nightly
echo "------------------------"
cat ./electron/package.json
echo "------------------------"
- name: Change App Name for beta version
if: inputs.beta == true
shell: bash
run: |
chmod +x .github/scripts/rename-app.sh
.github/scripts/rename-app.sh ./electron/package.json beta
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json beta
echo "------------------------"
cat ./electron/package.json
echo "------------------------"
cat ./package.json
jq '.build.publish = [{"provider": "generic", "url": "https://delta.jan.ai/beta", "channel": "beta"}, {"provider": "github", "owner": "janhq", "repo": "jan", "channel": "beta"}, {"provider": "s3", "acl": null, "bucket": "${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}", "region": "${{ secrets.DELTA_AWS_REGION}}", "path": "temp-beta", "channel": "beta"}]' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
cat electron/package.json
- name: Update app version base on tag
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') && inputs.public_provider == 'github'
run: |
jq --arg version "${VERSION_TAG#v}" '.version = $version' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
jq --arg version "${VERSION_TAG#v}" '.version = $version' web/package.json > /tmp/package.json
mv /tmp/package.json web/package.json
env:
VERSION_TAG: ${{ inputs.new_version }}
- name: Build and publish app to aws s3 r2 or github artifactory
if: inputs.public_provider != 'github'
run: |
# check public_provider is true or not
echo "public_provider is ${{ inputs.public_provider }}"
if [ "${{ inputs.public_provider }}" == "none" ]; then
make build
else
make build-and-publish
fi
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_EC2_METADATA_DISABLED: 'true'
AWS_MAX_ATTEMPTS: '5'
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
- name: Build and publish app to github
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') && inputs.public_provider == 'github' && inputs.beta == false
run: |
make build-and-publish
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
ANALYTICS_ID: ${{ secrets.JAN_APP_UMAMI_PROJECT_API_KEY }}
ANALYTICS_HOST: ${{ secrets.JAN_APP_UMAMI_URL }}
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
- name: Build and publish app to github
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') && inputs.public_provider == 'github' && inputs.beta == true
run: |
make build-and-publish
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_EC2_METADATA_DISABLED: 'true'
AWS_MAX_ATTEMPTS: '5'
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
- name: Upload Artifact .deb file
if: inputs.public_provider != 'github'
uses: actions/upload-artifact@v4
with:
name: jan-linux-amd64-${{ inputs.new_version }}-deb
path: ./electron/dist/*.deb
- name: Upload Artifact .AppImage file
if: inputs.public_provider != 'github'
uses: actions/upload-artifact@v4
with:
name: jan-linux-amd64-${{ inputs.new_version }}-AppImage
path: ./electron/dist/*.AppImage

View File

@ -1,202 +0,0 @@
name: build-macos
on:
workflow_call:
inputs:
ref:
required: true
type: string
default: 'refs/heads/main'
public_provider:
required: true
type: string
default: none
description: 'none: build only, github: build and publish to github, aws s3: build and publish to aws s3'
new_version:
required: true
type: string
default: ''
aws_s3_prefix:
required: false
type: string
default: '/latest/'
beta:
required: false
type: boolean
default: false
secrets:
DELTA_AWS_S3_BUCKET_NAME:
required: false
DELTA_AWS_ACCESS_KEY_ID:
required: false
DELTA_AWS_SECRET_ACCESS_KEY:
required: false
CODE_SIGN_P12_BASE64:
required: false
CODE_SIGN_P12_PASSWORD:
required: false
APPLE_ID:
required: false
APPLE_APP_SPECIFIC_PASSWORD:
required: false
DEVELOPER_ID:
required: false
jobs:
build-macos:
runs-on: macos-latest
environment: production
permissions:
contents: write
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Installing node
uses: actions/setup-node@v1
with:
node-version: 20
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Update app version based on latest release tag with build number
if: inputs.public_provider != 'github'
run: |
echo "Version: ${{ inputs.new_version }}"
# Update the version in electron/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' web/package.json > /tmp/package.json
mv /tmp/package.json web/package.json
jq '.build.publish = [{"provider": "generic", "url": "https://delta.jan.ai/nightly", "channel": "latest"}, {"provider": "s3", "acl": null, "bucket": "${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}", "region": "${{ secrets.DELTA_AWS_REGION}}", "path": "temp-nightly", "channel": "latest"}]' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
jq --arg teamid "${{ secrets.APPLE_TEAM_ID }}" '.build.mac.notarize.teamId = $teamid' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
# cat electron/package.json
chmod +x .github/scripts/rename-app.sh
.github/scripts/rename-app.sh ./electron/package.json nightly
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json nightly
echo "------------------------"
cat ./electron/package.json
echo "------------------------"
- name: Change App Name for beta version
if: inputs.beta == true
shell: bash
run: |
chmod +x .github/scripts/rename-app.sh
.github/scripts/rename-app.sh ./electron/package.json beta
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json beta
echo "------------------------"
cat ./electron/package.json
echo "------------------------"
cat ./package.json
jq '.build.publish = [{"provider": "generic", "url": "https://delta.jan.ai/beta", "channel": "beta"}, {"provider": "github", "owner": "janhq", "repo": "jan", "channel": "beta"}, {"provider": "s3", "acl": null, "bucket": "${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}", "region": "${{ secrets.DELTA_AWS_REGION}}", "path": "temp-beta", "channel": "beta"}]' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
cat electron/package.json
- name: Update app version base on tag
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') && inputs.public_provider == 'github'
run: |
jq --arg version "${VERSION_TAG#v}" '.version = $version' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
jq --arg version "${VERSION_TAG#v}" '.version = $version' web/package.json > /tmp/package.json
mv /tmp/package.json web/package.json
jq --arg teamid "${{ secrets.APPLE_TEAM_ID }}" '.build.mac.notarize.teamId = $teamid' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
cat electron/package.json
env:
VERSION_TAG: ${{ inputs.new_version }}
- name: Get Cer for code signing
run: base64 -d <<< "$CODE_SIGN_P12_BASE64" > /tmp/codesign.p12
shell: bash
env:
CODE_SIGN_P12_BASE64: ${{ secrets.CODE_SIGN_P12_BASE64 }}
- uses: apple-actions/import-codesign-certs@v2
continue-on-error: true
with:
p12-file-base64: ${{ secrets.CODE_SIGN_P12_BASE64 }}
p12-password: ${{ secrets.CODE_SIGN_P12_PASSWORD }}
- name: Build and publish app to aws s3 r2 or github artifactory
if: inputs.public_provider != 'github'
run: |
# check public_provider is true or not
echo "public_provider is ${{ inputs.public_provider }}"
if [ "${{ inputs.public_provider }}" == "none" ]; then
make build
else
make build-and-publish
fi
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CSC_LINK: '/tmp/codesign.p12'
CSC_KEY_PASSWORD: ${{ secrets.CODE_SIGN_P12_PASSWORD }}
CSC_IDENTITY_AUTO_DISCOVERY: 'true'
APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.APPLE_APP_SPECIFIC_PASSWORD }}
APP_PATH: '.'
DEVELOPER_ID: ${{ secrets.DEVELOPER_ID }}
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: auto
AWS_EC2_METADATA_DISABLED: 'true'
AWS_MAX_ATTEMPTS: '5'
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
- name: Build and publish app to github
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') && inputs.public_provider == 'github' && inputs.beta == false
run: |
make build-and-publish
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CSC_LINK: '/tmp/codesign.p12'
CSC_KEY_PASSWORD: ${{ secrets.CODE_SIGN_P12_PASSWORD }}
CSC_IDENTITY_AUTO_DISCOVERY: 'true'
APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.APPLE_APP_SPECIFIC_PASSWORD }}
APP_PATH: '.'
DEVELOPER_ID: ${{ secrets.DEVELOPER_ID }}
ANALYTICS_ID: ${{ secrets.JAN_APP_UMAMI_PROJECT_API_KEY }}
ANALYTICS_HOST: ${{ secrets.JAN_APP_UMAMI_URL }}
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
- name: Build and publish app to github
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') && inputs.public_provider == 'github' && inputs.beta == true
run: |
make build-and-publish
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CSC_LINK: '/tmp/codesign.p12'
CSC_KEY_PASSWORD: ${{ secrets.CODE_SIGN_P12_PASSWORD }}
CSC_IDENTITY_AUTO_DISCOVERY: 'true'
APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.APPLE_APP_SPECIFIC_PASSWORD }}
APP_PATH: '.'
DEVELOPER_ID: ${{ secrets.DEVELOPER_ID }}
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: auto
AWS_EC2_METADATA_DISABLED: 'true'
AWS_MAX_ATTEMPTS: '5'
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
- name: Upload Artifact
if: inputs.public_provider != 'github'
uses: actions/upload-artifact@v4
with:
name: jan-mac-universal-${{ inputs.new_version }}
path: ./electron/dist/*.dmg

View File

@ -1,198 +0,0 @@
name: build-windows-x64
on:
workflow_call:
inputs:
ref:
required: true
type: string
default: 'refs/heads/main'
public_provider:
required: true
type: string
default: none
description: 'none: build only, github: build and publish to github, aws s3: build and publish to aws s3'
new_version:
required: true
type: string
default: ''
aws_s3_prefix:
required: false
type: string
default: '/latest/'
beta:
required: false
type: boolean
default: false
secrets:
DELTA_AWS_S3_BUCKET_NAME:
required: false
DELTA_AWS_ACCESS_KEY_ID:
required: false
DELTA_AWS_SECRET_ACCESS_KEY:
required: false
AZURE_KEY_VAULT_URI:
required: false
AZURE_CLIENT_ID:
required: false
AZURE_TENANT_ID:
required: false
AZURE_CLIENT_SECRET:
required: false
AZURE_CERT_NAME:
required: false
jobs:
build-windows-x64:
runs-on: windows-latest
permissions:
contents: write
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Installing node
uses: actions/setup-node@v1
with:
node-version: 20
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Update app version base on tag
if: inputs.public_provider != 'github'
id: version_update
shell: bash
run: |
echo "Version: ${{ inputs.new_version }}"
# Update the version in electron/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' web/package.json > /tmp/package.json
mv /tmp/package.json web/package.json
jq '.build.publish = [{"provider": "generic", "url": "https://delta.jan.ai/nightly", "channel": "latest"}, {"provider": "s3", "acl": null, "bucket": "${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}", "region": "${{ secrets.DELTA_AWS_REGION}}", "path": "temp-nightly", "channel": "latest"}]' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
jq '.build.win.sign = "./sign.js"' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
cat electron/package.json
chmod +x .github/scripts/rename-app.sh
.github/scripts/rename-app.sh ./electron/package.json nightly
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json nightly
chmod +x .github/scripts/rename-uninstaller.sh
.github/scripts/rename-uninstaller.sh nightly
echo "------------------------"
cat ./electron/package.json
echo "------------------------"
cat ./package.json
echo "------------------------"
- name: Change App Name for beta version
if: inputs.beta == true
shell: bash
run: |
chmod +x .github/scripts/rename-app.sh
.github/scripts/rename-app.sh ./electron/package.json beta
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json beta
chmod +x .github/scripts/rename-uninstaller.sh
.github/scripts/rename-uninstaller.sh beta
echo "------------------------"
cat ./electron/package.json
echo "------------------------"
cat ./package.json
echo "------------------------"
cat ./electron/scripts/uninstaller.nsh
jq '.build.publish = [{"provider": "generic", "url": "https://delta.jan.ai/beta", "channel": "beta"}, {"provider": "github", "owner": "janhq", "repo": "jan", "channel": "beta"}, {"provider": "s3", "acl": null, "bucket": "${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}", "region": "${{ secrets.DELTA_AWS_REGION}}", "path": "temp-beta", "channel": "beta"}]' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
cat electron/package.json
- name: Update app version base on tag
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') && inputs.public_provider == 'github'
shell: bash
run: |
jq --arg version "${VERSION_TAG#v}" '.version = $version' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
jq --arg version "${VERSION_TAG#v}" '.version = $version' web/package.json > /tmp/package.json
mv /tmp/package.json web/package.json
jq '.build.win.sign = "./sign.js"' electron/package.json > /tmp/package.json
mv /tmp/package.json electron/package.json
env:
VERSION_TAG: ${{ inputs.new_version }}
- name: Install AzureSignTool
run: |
dotnet tool install --global AzureSignTool
- name: Build and publish app to aws s3 r2 or github artifactory
shell: bash
if: inputs.public_provider != 'github'
run: |
# check public_provider is true or not
echo "public_provider is ${{ inputs.public_provider }}"
if [ "${{ inputs.public_provider }}" == "none" ]; then
make build
else
make build-and-publish
fi
env:
AZURE_KEY_VAULT_URI: ${{ secrets.AZURE_KEY_VAULT_URI }}
AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }}
AZURE_CERT_NAME: homebrewltd
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: auto
AWS_EC2_METADATA_DISABLED: 'true'
AWS_MAX_ATTEMPTS: '5'
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
- name: Build app and publish app to github
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') && inputs.public_provider == 'github' && inputs.beta == false
run: |
make build-and-publish
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
ANALYTICS_ID: ${{ secrets.JAN_APP_UMAMI_PROJECT_API_KEY }}
ANALYTICS_HOST: ${{ secrets.JAN_APP_UMAMI_URL }}
AZURE_KEY_VAULT_URI: ${{ secrets.AZURE_KEY_VAULT_URI }}
AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }}
AZURE_CERT_NAME: homebrewltd
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
- name: Build app and publish app to github
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') && inputs.public_provider == 'github' && inputs.beta == true
run: |
make build-and-publish
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: auto
AWS_EC2_METADATA_DISABLED: 'true'
AWS_MAX_ATTEMPTS: '5'
AZURE_KEY_VAULT_URI: ${{ secrets.AZURE_KEY_VAULT_URI }}
AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }}
# AZURE_CERT_NAME: ${{ secrets.AZURE_CERT_NAME }}
AZURE_CERT_NAME: homebrewltd
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
- name: Upload Artifact
if: inputs.public_provider != 'github'
uses: actions/upload-artifact@v4
with:
name: jan-win-x64-${{ inputs.new_version }}
path: ./electron/dist/*.exe

View File

@ -9,50 +9,52 @@ on:
jobs:
get-update-version:
runs-on: ubuntu-latest
environment: production
outputs:
new_version: ${{ steps.version_update.outputs.new_version }}
steps:
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Get tag
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
id: tag
uses: dawidd6/action-get-tag@v1
- name: Get tag
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
id: tag
uses: dawidd6/action-get-tag@v1
- name: Update app version based on latest release tag with build number
id: version_update
run: |
# Function to get the latest release tag
get_latest_tag() {
local retries=0
local max_retries=3
local tag
while [ $retries -lt $max_retries ]; do
tag=$(curl -s https://api.github.com/repos/janhq/jan/releases/latest | jq -r .tag_name)
if [ -n "$tag" ] && [ "$tag" != "null" ]; then
echo $tag
return
else
let retries++
echo "Retrying... ($retries/$max_retries)"
sleep 2
fi
done
echo "Failed to fetch latest tag after $max_retries attempts."
exit 1
}
- name: Update app version based on latest release tag with build number
id: version_update
run: |
# Function to get the latest release tag
get_latest_tag() {
local retries=0
local max_retries=3
local tag
while [ $retries -lt $max_retries ]; do
tag=$(curl -s https://api.github.com/repos/janhq/jan/releases/latest | jq -r .tag_name)
if [ -n "$tag" ] && [ "$tag" != "null" ]; then
echo $tag
return
else
let retries++
echo "Retrying... ($retries/$max_retries)"
sleep 2
fi
done
echo "Failed to fetch latest tag after $max_retries attempts."
exit 1
}
if ${{ github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') }}; then
echo "Tag detected, set output follow tag"
echo "::set-output name=new_version::${{ steps.tag.outputs.tag }}"
else
# Get the latest release tag from GitHub API
LATEST_TAG=$(get_latest_tag)
# Remove the 'v' and append the build number to the version
new_version="${LATEST_TAG#v}-${GITHUB_RUN_NUMBER}"
echo "New version: $new_version"
echo "::set-output name=new_version::$new_version"
fi
if ${{ github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') }}; then
echo "Tag detected, set output follow tag"
sanitized_tag="${{ steps.tag.outputs.tag }}"
# Remove the 'v' prefix if it exists
sanitized_tag="${sanitized_tag#v}"
echo "::set-output name=new_version::$sanitized_tag"
else
# Get the latest release tag from GitHub API
LATEST_TAG=$(get_latest_tag)
# Remove the 'v' and append the build number to the version
new_version="${LATEST_TAG#v}-${GITHUB_RUN_NUMBER}"
echo "New version: $new_version"
echo "::set-output name=new_version::$new_version"
fi

View File

@ -26,7 +26,6 @@ on:
jobs:
noti-discord-and-update-url-readme:
environment: production
runs-on: ubuntu-latest
permissions:
contents: write
@ -34,7 +33,7 @@ jobs:
- name: Checkout code
uses: actions/checkout@v3
with:
fetch-depth: "0"
fetch-depth: '0'
token: ${{ secrets.PAT_SERVICE_ACCOUNT }}
ref: ${{ inputs.ref }}
@ -47,10 +46,10 @@ jobs:
with:
args: |
Jan App ${{ inputs.build_reason }} build artifact version {{ VERSION }}:
- Windows: https://delta.jan.ai/nightly/jan-nightly-win-x64-{{ VERSION }}.exe
- macOS Universal: https://delta.jan.ai/nightly/jan-nightly-mac-universal-{{ VERSION }}.dmg
- Linux Deb: https://delta.jan.ai/nightly/jan-nightly-linux-amd64-{{ VERSION }}.deb
- Linux AppImage: https://delta.jan.ai/nightly/jan-nightly-linux-x86_64-{{ VERSION }}.AppImage
- Windows: https://delta.jan.ai/nightly/Jan-nightly_{{ VERSION }}_x64-setup.exe
- macOS Universal: https://delta.jan.ai/nightly/Jan-nightly_{{ VERSION }}_universal.dmg
- Linux Deb: https://delta.jan.ai/nightly/Jan-nightly_{{ VERSION }}_amd64.deb
- Linux AppImage: https://delta.jan.ai/nightly/Jan-nightly_{{ VERSION }}_amd64.AppImage
- Github action run: https://github.com/janhq/jan/actions/runs/{{ GITHUB_RUN_ID }}
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}

View File

@ -0,0 +1,138 @@
name: tauri-build-linux-x64-external
on:
workflow_call:
inputs:
ref:
required: true
type: string
default: 'refs/heads/main'
new_version:
required: true
type: string
default: ''
channel:
required: true
type: string
default: 'nightly'
description: 'The channel to use for this job'
disable_updater:
required: false
type: boolean
default: false
description: 'If true, builds both .deb and .appimage but disables auto-updater'
jobs:
build-linux-x64-external:
runs-on: ubuntu-latest
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Free Disk Space Before Build
run: |
echo "Disk space before cleanup:"
df -h
sudo rm -rf /usr/local/.ghcup
sudo rm -rf /opt/hostedtoolcache/CodeQL
sudo rm -rf /usr/local/lib/android/sdk/ndk
sudo rm -rf /usr/share/dotnet
sudo rm -rf /opt/ghc
sudo rm -rf /usr/local/share/boost
sudo apt-get clean
echo "Disk space after cleanup:"
df -h
- name: Replace Icons for Beta Build
if: inputs.channel != 'stable'
shell: bash
run: |
cp .github/scripts/icon-${{ inputs.channel }}.png src-tauri/icons/icon.png
- name: Installing node
uses: actions/setup-node@v1
with:
node-version: 20
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Install ctoml
run: |
cargo install ctoml
- name: Install Tauri dependencies
run: |
sudo apt update
sudo apt install -y libglib2.0-dev libatk1.0-dev libpango1.0-dev libgtk-3-dev libsoup-3.0-dev libwebkit2gtk-4.1-dev librsvg2-dev libfuse2 libayatana-appindicator3-dev
- name: Update app version
run: |
echo "Version: ${{ inputs.new_version }}"
jq --arg version "${{ inputs.new_version }}" '.version = $version | .bundle.createUpdaterArtifacts = false' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
if [ "${{ inputs.channel }}" != "stable" ]; then
jq '.bundle.linux.deb.files = {"usr/bin/bun": "resources/bin/bun"}' ./src-tauri/tauri.linux.conf.json > /tmp/tauri.linux.conf.json
mv /tmp/tauri.linux.conf.json ./src-tauri/tauri.linux.conf.json
fi
jq --arg version "${{ inputs.new_version }}" '.version = $version' web-app/package.json > /tmp/package.json
mv /tmp/package.json web-app/package.json
# Update tauri plugin versions
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-hardware/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-hardware/package.json
echo "---------./src-tauri/plugins/tauri-plugin-hardware/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-llamacpp/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
ctoml ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml
ctoml ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml
ctoml ./src-tauri/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/Cargo.toml---------"
cat ./src-tauri/Cargo.toml
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
if [ "${{ inputs.channel }}" != "stable" ]; then
jq '.plugins.updater.endpoints = ["https://delta.jan.ai/${{ inputs.channel }}/latest.json"]' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
chmod +x .github/scripts/rename-tauri-app.sh
.github/scripts/rename-tauri-app.sh ./src-tauri/tauri.conf.json ${{ inputs.channel }}
ctoml ./src-tauri/Cargo.toml package.name "Jan-${{ inputs.channel }}"
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json ${{ inputs.channel }}
fi
- name: Build app
run: |
make build
env:
RELEASE_CHANNEL: '${{ inputs.channel }}'
AUTO_UPDATER_DISABLED: ${{ inputs.disable_updater && 'true' || 'false' }}
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: jan-linux-amd64-${{ inputs.new_version }}-deb
path: ./src-tauri/target/release/bundle/deb/*.deb
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: jan-linux-amd64-${{ inputs.new_version }}-AppImage
path: ./src-tauri/target/release/bundle/appimage/*.AppImage

View File

@ -0,0 +1,185 @@
name: tauri-build-linux-x64-flatpak
on:
workflow_call:
inputs:
ref:
required: true
type: string
default: 'refs/heads/main'
public_provider:
required: true
type: string
default: none
description: 'none: build only, github: build and publish to github, aws s3: build and publish to aws s3'
new_version:
required: true
type: string
default: ''
cortex_api_port:
required: false
type: string
default: ''
upload_url:
required: false
type: string
default: ''
channel:
required: true
type: string
default: 'nightly'
description: 'The channel to use for this job'
disable_updater:
required: false
type: boolean
default: false
description: 'If true, builds both .deb and .appimage but disables auto-updater'
secrets:
DELTA_AWS_S3_BUCKET_NAME:
required: false
DELTA_AWS_ACCESS_KEY_ID:
required: false
DELTA_AWS_SECRET_ACCESS_KEY:
required: false
TAURI_SIGNING_PRIVATE_KEY:
required: false
TAURI_SIGNING_PRIVATE_KEY_PASSWORD:
required: false
jobs:
build-linux-x64:
runs-on: ubuntu-22.04
permissions:
contents: write
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Free Disk Space Before Build
run: |
echo "Disk space before cleanup:"
df -h
sudo rm -rf /usr/local/.ghcup
sudo rm -rf /opt/hostedtoolcache/CodeQL
sudo rm -rf /usr/local/lib/android/sdk/ndk
sudo rm -rf /usr/share/dotnet
sudo rm -rf /opt/ghc
sudo rm -rf /usr/local/share/boost
sudo apt-get clean
echo "Disk space after cleanup:"
df -h
- name: Installing node
uses: actions/setup-node@v1
with:
node-version: 20
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Install ctoml
run: |
cargo install ctoml
- name: Install Tauri dependencies
run: |
sudo apt update
sudo apt install -y libglib2.0-dev libatk1.0-dev libpango1.0-dev libgtk-3-dev libsoup-3.0-dev libwebkit2gtk-4.1-dev librsvg2-dev libfuse2
- name: Update app version base public_provider
run: |
echo "Version: ${{ inputs.new_version }}"
# Update tauri.conf.json
jq --arg version "${{ inputs.new_version }}" '.version = $version | .bundle.createUpdaterArtifacts = true' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
if [ "${{ inputs.channel }}" != "stable" ]; then
jq '.bundle.linux.deb.files = {"usr/bin/bun": "resources/bin/bun"}' ./src-tauri/tauri.linux.conf.json > /tmp/tauri.linux.conf.json
mv /tmp/tauri.linux.conf.json ./src-tauri/tauri.linux.conf.json
fi
jq --arg version "${{ inputs.new_version }}" '.version = $version' web-app/package.json > /tmp/package.json
mv /tmp/package.json web-app/package.json
# Update tauri plugin versions
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-hardware/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-hardware/package.json
echo "---------./src-tauri/plugins/tauri-plugin-hardware/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-llamacpp/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
ctoml ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml
ctoml ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml
ctoml ./src-tauri/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/Cargo.toml---------"
cat ./src-tauri/Cargo.toml
# Temporarily enable devtool on prod build
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
cat ./src-tauri/Cargo.toml
# Change app name for beta and nightly builds
if [ "${{ inputs.channel }}" != "stable" ]; then
jq '.plugins.updater.endpoints = ["https://delta.jan.ai/${{ inputs.channel }}/latest.json"]' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
chmod +x .github/scripts/rename-tauri-app.sh
.github/scripts/rename-tauri-app.sh ./src-tauri/tauri.conf.json ${{ inputs.channel }}
cat ./src-tauri/tauri.conf.json
# Update Cargo.toml
ctoml ./src-tauri/Cargo.toml package.name "Jan-${{ inputs.channel }}"
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
echo "------------------"
cat ./src-tauri/Cargo.toml
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json ${{ inputs.channel }}
cat ./package.json
fi
- name: Build app
run: |
make build
APP_IMAGE=./src-tauri/target/release/bundle/appimage/$(ls ./src-tauri/target/release/bundle/appimage/ | grep AppImage | head -1)
yarn tauri signer sign \
--private-key "$TAURI_SIGNING_PRIVATE_KEY" \
--password "$TAURI_SIGNING_PRIVATE_KEY_PASSWORD" \
"$APP_IMAGE"
env:
RELEASE_CHANNEL: '${{ inputs.channel }}'
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
AUTO_UPDATER_DISABLED: ${{ inputs.disable_updater && 'true' || 'false' }}
# Publish app
## Artifacts, for dev and test
- name: Upload Artifact
if: inputs.public_provider != 'github'
uses: actions/upload-artifact@v4
with:
name: jan-linux-amd64-flatpak-${{ inputs.new_version }}-deb
path: ./src-tauri/target/release/bundle/deb/*.deb
- name: Upload Artifact
if: inputs.public_provider != 'github'
uses: actions/upload-artifact@v4
with:
name: jan-linux-amd64-flatpak-${{ inputs.new_version }}-AppImage
path: ./src-tauri/target/release/bundle/appimage/*.AppImage

View File

@ -0,0 +1,264 @@
name: tauri-build-linux-x64
on:
workflow_call:
inputs:
ref:
required: true
type: string
default: 'refs/heads/main'
public_provider:
required: true
type: string
default: none
description: 'none: build only, github: build and publish to github, aws s3: build and publish to aws s3'
new_version:
required: true
type: string
default: ''
cortex_api_port:
required: false
type: string
default: ''
upload_url:
required: false
type: string
default: ''
channel:
required: true
type: string
default: 'nightly'
description: 'The channel to use for this job'
disable_updater:
required: false
type: boolean
default: false
description: 'If true, builds both .deb and .appimage but disables auto-updater'
secrets:
DELTA_AWS_S3_BUCKET_NAME:
required: false
DELTA_AWS_ACCESS_KEY_ID:
required: false
DELTA_AWS_SECRET_ACCESS_KEY:
required: false
TAURI_SIGNING_PRIVATE_KEY:
required: false
TAURI_SIGNING_PRIVATE_KEY_PASSWORD:
required: false
outputs:
DEB_SIG:
value: ${{ jobs.build-linux-x64.outputs.DEB_SIG }}
APPIMAGE_SIG:
value: ${{ jobs.build-linux-x64.outputs.APPIMAGE_SIG }}
APPIMAGE_FILE_NAME:
value: ${{ jobs.build-linux-x64.outputs.APPIMAGE_FILE_NAME }}
jobs:
build-linux-x64:
runs-on: ubuntu-latest
outputs:
DEB_SIG: ${{ steps.packageinfo.outputs.DEB_SIG }}
APPIMAGE_SIG: ${{ steps.packageinfo.outputs.APPIMAGE_SIG }}
APPIMAGE_FILE_NAME: ${{ steps.packageinfo.outputs.APPIMAGE_FILE_NAME }}
permissions:
contents: write
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Free Disk Space Before Build
run: |
echo "Disk space before cleanup:"
df -h
sudo rm -rf /usr/local/.ghcup
sudo rm -rf /opt/hostedtoolcache/CodeQL
sudo rm -rf /usr/local/lib/android/sdk/ndk
sudo rm -rf /usr/share/dotnet
sudo rm -rf /opt/ghc
sudo rm -rf /usr/local/share/boost
sudo apt-get clean
echo "Disk space after cleanup:"
df -h
- name: Replace Icons for Beta Build
if: inputs.channel != 'stable'
shell: bash
run: |
cp .github/scripts/icon-${{ inputs.channel }}.png src-tauri/icons/icon.png
- name: Installing node
uses: actions/setup-node@v1
with:
node-version: 20
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Install ctoml
run: |
cargo install ctoml
- name: Install Tauri dependencies
run: |
sudo apt update
sudo apt install -y libglib2.0-dev libatk1.0-dev libpango1.0-dev libgtk-3-dev libsoup-3.0-dev libwebkit2gtk-4.1-dev librsvg2-dev libfuse2 libayatana-appindicator3-dev
- name: Update app version base public_provider
run: |
echo "Version: ${{ inputs.new_version }}"
# Update tauri.conf.json
jq --arg version "${{ inputs.new_version }}" '.version = $version | .bundle.createUpdaterArtifacts = true' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
if [ "${{ inputs.channel }}" != "stable" ]; then
jq '.bundle.linux.deb.files = {"usr/bin/bun": "resources/bin/bun"}' ./src-tauri/tauri.linux.conf.json > /tmp/tauri.linux.conf.json
mv /tmp/tauri.linux.conf.json ./src-tauri/tauri.linux.conf.json
fi
jq --arg version "${{ inputs.new_version }}" '.version = $version' web-app/package.json > /tmp/package.json
mv /tmp/package.json web-app/package.json
# Update tauri plugin versions
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-hardware/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-hardware/package.json
echo "---------./src-tauri/plugins/tauri-plugin-hardware/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-llamacpp/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
ctoml ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml
ctoml ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml
ctoml ./src-tauri/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/Cargo.toml---------"
cat ./src-tauri/Cargo.toml
# Temporarily enable devtool on prod build
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
cat ./src-tauri/Cargo.toml
# Change app name for beta and nightly builds
if [ "${{ inputs.channel }}" != "stable" ]; then
jq '.plugins.updater.endpoints = ["https://delta.jan.ai/${{ inputs.channel }}/latest.json"]' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
chmod +x .github/scripts/rename-tauri-app.sh
.github/scripts/rename-tauri-app.sh ./src-tauri/tauri.conf.json ${{ inputs.channel }}
cat ./src-tauri/tauri.conf.json
# Update Cargo.toml
ctoml ./src-tauri/Cargo.toml package.name "Jan-${{ inputs.channel }}"
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
echo "------------------"
cat ./src-tauri/Cargo.toml
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json ${{ inputs.channel }}
cat ./package.json
fi
- name: Build app
run: |
make build
APP_IMAGE=./src-tauri/target/release/bundle/appimage/$(ls ./src-tauri/target/release/bundle/appimage/ | grep AppImage | head -1)
yarn tauri signer sign \
--private-key "$TAURI_SIGNING_PRIVATE_KEY" \
--password "$TAURI_SIGNING_PRIVATE_KEY_PASSWORD" \
"$APP_IMAGE"
env:
RELEASE_CHANNEL: '${{ inputs.channel }}'
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
AUTO_UPDATER_DISABLED: ${{ inputs.disable_updater && 'true' || 'false' }}
# Publish app
## Artifacts, for dev and test
- name: Upload Artifact
if: inputs.public_provider != 'github'
uses: actions/upload-artifact@v4
with:
name: jan-linux-amd64-${{ inputs.new_version }}-deb
path: ./src-tauri/target/release/bundle/deb/*.deb
- name: Upload Artifact
if: inputs.public_provider != 'github'
uses: actions/upload-artifact@v4
with:
name: jan-linux-amd64-${{ inputs.new_version }}-AppImage
path: ./src-tauri/target/release/bundle/appimage/*.AppImage
## Set output filename for linux
- name: Set output filename for linux
id: packageinfo
run: |
cd ./src-tauri/target/release/bundle
if [ "${{ inputs.channel }}" != "stable" ]; then
DEB_FILE_NAME=Jan-${{ inputs.channel }}_${{ inputs.new_version }}_amd64.deb
APPIMAGE_FILE_NAME=Jan-${{ inputs.channel }}_${{ inputs.new_version }}_amd64.AppImage
DEB_SIG=$(cat deb/Jan-${{ inputs.channel }}_${{ inputs.new_version }}_amd64.deb.sig)
APPIMAGE_SIG=$(cat appimage/Jan-${{ inputs.channel }}_${{ inputs.new_version }}_amd64.AppImage.sig)
else
DEB_FILE_NAME=Jan_${{ inputs.new_version }}_amd64.deb
APPIMAGE_FILE_NAME=Jan_${{ inputs.new_version }}_amd64.AppImage
DEB_SIG=$(cat deb/Jan_${{ inputs.new_version }}_amd64.deb.sig)
APPIMAGE_SIG=$(cat appimage/Jan_${{ inputs.new_version }}_amd64.AppImage.sig)
fi
echo "DEB_SIG=$DEB_SIG" >> $GITHUB_OUTPUT
echo "APPIMAGE_SIG=$APPIMAGE_SIG" >> $GITHUB_OUTPUT
echo "DEB_FILE_NAME=$DEB_FILE_NAME" >> $GITHUB_OUTPUT
echo "APPIMAGE_FILE_NAME=$APPIMAGE_FILE_NAME" >> $GITHUB_OUTPUT
## Upload to s3 for nightly and beta
- name: upload to aws s3 if public provider is aws
if: inputs.public_provider == 'aws-s3' || inputs.channel == 'beta'
run: |
cd ./src-tauri/target/release/bundle
# Upload for tauri updater
aws s3 cp ./appimage/Jan-${{ inputs.channel }}_${{ inputs.new_version }}_amd64.AppImage s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-${{ inputs.channel }}/Jan-${{ inputs.channel }}_${{ inputs.new_version }}_amd64.AppImage
aws s3 cp ./deb/Jan-${{ inputs.channel }}_${{ inputs.new_version }}_amd64.deb s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-${{ inputs.channel }}/Jan-${{ inputs.channel }}_${{ inputs.new_version }}_amd64.deb
aws s3 cp ./appimage/Jan-${{ inputs.channel }}_${{ inputs.new_version }}_amd64.AppImage.sig s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-${{ inputs.channel }}/Jan-${{ inputs.channel }}_${{ inputs.new_version }}_amd64.AppImage.sig
aws s3 cp ./deb/Jan-${{ inputs.channel }}_${{ inputs.new_version }}_amd64.deb.sig s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-${{ inputs.channel }}/Jan-${{ inputs.channel }}_${{ inputs.new_version }}_amd64.deb.sig
env:
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: ${{ secrets.DELTA_AWS_REGION }}
AWS_EC2_METADATA_DISABLED: 'true'
- name: Upload release assert if public provider is github
if: inputs.public_provider == 'github'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
uses: actions/upload-release-asset@v1.0.1
with:
upload_url: ${{ inputs.upload_url }}
asset_path: ./src-tauri/target/release/bundle/appimage/${{ steps.packageinfo.outputs.APPIMAGE_FILE_NAME }}
asset_name: ${{ steps.packageinfo.outputs.APPIMAGE_FILE_NAME }}
asset_content_type: application/octet-stream
- name: Upload release assert if public provider is github
if: inputs.public_provider == 'github'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
uses: actions/upload-release-asset@v1.0.1
with:
upload_url: ${{ inputs.upload_url }}
asset_path: ./src-tauri/target/release/bundle/deb/${{ steps.packageinfo.outputs.DEB_FILE_NAME }}
asset_name: ${{ steps.packageinfo.outputs.DEB_FILE_NAME }}
asset_content_type: application/octet-stream

View File

@ -0,0 +1,103 @@
name: tauri-build-macos-external
on:
workflow_call:
inputs:
ref:
required: true
type: string
default: 'refs/heads/main'
new_version:
required: true
type: string
default: ''
channel:
required: true
type: string
default: 'nightly'
description: 'The channel to use for this job'
jobs:
build-macos-external:
runs-on: macos-latest
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Replace Icons for Beta Build
if: inputs.channel != 'stable'
shell: bash
run: |
cp .github/scripts/icon-${{ inputs.channel }}.png src-tauri/icons/icon.png
- name: Installing node
uses: actions/setup-node@v1
with:
node-version: 20
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Install ctoml
run: |
cargo install ctoml
- name: Update app version
run: |
echo "Version: ${{ inputs.new_version }}"
jq --arg version "${{ inputs.new_version }}" '.version = $version | .bundle.createUpdaterArtifacts = false' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' web-app/package.json > /tmp/package.json
mv /tmp/package.json web-app/package.json
# Update tauri plugin versions
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-hardware/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-hardware/package.json
echo "---------./src-tauri/plugins/tauri-plugin-hardware/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-llamacpp/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
ctoml ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml
ctoml ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml
ctoml ./src-tauri/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/Cargo.toml---------"
cat ./src-tauri/Cargo.toml
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
if [ "${{ inputs.channel }}" != "stable" ]; then
jq '.plugins.updater.endpoints = ["https://delta.jan.ai/${{ inputs.channel }}/latest.json"]' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
chmod +x .github/scripts/rename-tauri-app.sh
.github/scripts/rename-tauri-app.sh ./src-tauri/tauri.conf.json ${{ inputs.channel }}
ctoml ./src-tauri/Cargo.toml package.name "Jan-${{ inputs.channel }}"
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json ${{ inputs.channel }}
fi
- name: Build app
run: |
make build
env:
APP_PATH: '.'
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: jan-${{ inputs.channel }}-mac-universal-${{ inputs.new_version }}.dmg
path: |
./src-tauri/target/universal-apple-darwin/release/bundle/dmg/*.dmg

View File

@ -0,0 +1,264 @@
name: tauri-build-macos
on:
workflow_call:
inputs:
ref:
required: true
type: string
default: 'refs/heads/main'
public_provider:
required: true
type: string
default: none
description: 'none: build only, github: build and publish to github, aws s3: build and publish to aws s3'
new_version:
required: true
type: string
default: ''
cortex_api_port:
required: false
type: string
default: ''
upload_url:
required: false
type: string
default: ''
channel:
required: true
type: string
default: 'nightly'
description: 'The channel to use for this job'
secrets:
DELTA_AWS_S3_BUCKET_NAME:
required: false
DELTA_AWS_ACCESS_KEY_ID:
required: false
DELTA_AWS_SECRET_ACCESS_KEY:
required: false
CODE_SIGN_P12_BASE64:
required: false
CODE_SIGN_P12_PASSWORD:
required: false
APPLE_ID:
required: false
APPLE_APP_SPECIFIC_PASSWORD:
required: false
DEVELOPER_ID:
required: false
TAURI_SIGNING_PRIVATE_KEY:
required: false
TAURI_SIGNING_PRIVATE_KEY_PASSWORD:
required: false
outputs:
MAC_UNIVERSAL_SIG:
value: ${{ jobs.build-macos.outputs.MAC_UNIVERSAL_SIG }}
FILE_NAME:
value: ${{ jobs.build-macos.outputs.FILE_NAME }}
DMG_NAME:
value: ${{ jobs.build-macos.outputs.DMG_NAME }}
TAR_NAME:
value: ${{ jobs.build-macos.outputs.TAR_NAME }}
jobs:
build-macos:
runs-on: macos-latest
outputs:
MAC_UNIVERSAL_SIG: ${{ steps.metadata.outputs.MAC_UNIVERSAL_SIG }}
FILE_NAME: ${{ steps.metadata.outputs.FILE_NAME }}
DMG_NAME: ${{ steps.metadata.outputs.DMG_NAME }}
TAR_NAME: ${{ steps.metadata.outputs.TAR_NAME }}
permissions:
contents: write
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Replace Icons for Beta Build
if: inputs.channel != 'stable'
shell: bash
run: |
cp .github/scripts/icon-${{ inputs.channel }}.png src-tauri/icons/icon.png
- name: Installing node
uses: actions/setup-node@v1
with:
node-version: 20
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Install ctoml
run: |
cargo install ctoml
- name: Update app version based on latest release tag with build number
run: |
echo "Version: ${{ inputs.new_version }}"
# Update tauri.conf.json
jq --arg version "${{ inputs.new_version }}" '.version = $version | .bundle.createUpdaterArtifacts = true' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' web-app/package.json > /tmp/package.json
mv /tmp/package.json web-app/package.json
# Update tauri plugin versions
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-hardware/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-hardware/package.json
echo "---------./src-tauri/plugins/tauri-plugin-hardware/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-llamacpp/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
ctoml ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml
ctoml ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml
ctoml ./src-tauri/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/Cargo.toml---------"
cat ./src-tauri/Cargo.toml
# Temporarily enable devtool on prod build
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
cat ./src-tauri/Cargo.toml
# Change app name for beta and nightly builds
if [ "${{ inputs.channel }}" != "stable" ]; then
jq '.plugins.updater.endpoints = ["https://delta.jan.ai/${{ inputs.channel }}/latest.json"]' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
chmod +x .github/scripts/rename-tauri-app.sh
.github/scripts/rename-tauri-app.sh ./src-tauri/tauri.conf.json ${{ inputs.channel }}
cat ./src-tauri/tauri.conf.json
# Update Cargo.toml
ctoml ./src-tauri/Cargo.toml package.name "Jan-${{ inputs.channel }}"
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
echo "------------------"
cat ./src-tauri/Cargo.toml
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json ${{ inputs.channel }}
cat ./package.json
fi
- name: Get key for notarize
run: base64 -d <<< "$NOTARIZE_P8_BASE64" > /tmp/notary-key.p8
shell: bash
env:
NOTARIZE_P8_BASE64: ${{ secrets.NOTARIZE_P8_BASE64 }}
- uses: apple-actions/import-codesign-certs@v2
continue-on-error: true
with:
p12-file-base64: ${{ secrets.CODE_SIGN_P12_BASE64 }}
p12-password: ${{ secrets.CODE_SIGN_P12_PASSWORD }}
- name: Build app
run: |
make build
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
APP_PATH: '.'
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
APPLE_CERTIFICATE: ${{ secrets.CODE_SIGN_P12_BASE64 }}
APPLE_CERTIFICATE_PASSWORD: ${{ secrets.CODE_SIGN_P12_PASSWORD }}
APPLE_API_ISSUER: ${{ secrets.NOTARY_ISSUER }}
APPLE_API_KEY: ${{ secrets.NOTARY_KEY_ID }}
APPLE_API_KEY_PATH: /tmp/notary-key.p8
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
# Publish app
## Artifacts, for dev and test
- name: Upload Artifact
if: inputs.public_provider != 'github'
uses: actions/upload-artifact@v4
with:
name: jan-${{ inputs.channel }}-mac-universal-${{ inputs.new_version }}.dmg
path: |
./src-tauri/target/universal-apple-darwin/release/bundle/dmg/*.dmg
## Set output filename for mac
- name: Set output filename for mac
run: |
cd ./src-tauri/target/universal-apple-darwin/release/bundle/macos
if [ "${{ inputs.channel }}" != "stable" ]; then
zip -r jan-${{ inputs.channel }}-mac-universal-${{ inputs.new_version }}.zip Jan-${{ inputs.channel }}.app
FILE_NAME=jan-${{ inputs.channel }}-mac-universal-${{ inputs.new_version }}.zip
DMG_NAME=Jan-${{ inputs.channel }}_${{ inputs.new_version }}_universal.dmg
MAC_UNIVERSAL_SIG=$(cat Jan-${{ inputs.channel }}.app.tar.gz.sig)
TAR_NAME=Jan-${{ inputs.channel }}.app.tar.gz
else
zip -r jan-mac-universal-${{ inputs.new_version }}.zip Jan.app
FILE_NAME=jan-mac-universal-${{ inputs.new_version }}.zip
MAC_UNIVERSAL_SIG=$(cat Jan.app.tar.gz.sig)
DMG_NAME=Jan_${{ inputs.new_version }}_universal.dmg
TAR_NAME=Jan.app.tar.gz
fi
echo "::set-output name=MAC_UNIVERSAL_SIG::$MAC_UNIVERSAL_SIG"
echo "::set-output name=FILE_NAME::$FILE_NAME"
echo "::set-output name=DMG_NAME::$DMG_NAME"
echo "::set-output name=TAR_NAME::$TAR_NAME"
id: metadata
## Upload to s3 for nightly and beta
- name: upload to aws s3 if public provider is aws
if: inputs.public_provider == 'aws-s3' || inputs.channel == 'beta'
run: |
cd ./src-tauri/target/universal-apple-darwin/release/bundle
# Upload for tauri updater
aws s3 cp ./dmg/Jan-${{ inputs.channel }}_${{ inputs.new_version }}_universal.dmg s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-${{ inputs.channel }}/Jan-${{ inputs.channel }}_${{ inputs.new_version }}_universal.dmg
aws s3 cp ./macos/Jan-${{ inputs.channel }}.app.tar.gz s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-${{ inputs.channel }}/Jan-${{ inputs.channel }}_${{ inputs.new_version }}.app.tar.gz
aws s3 cp ./macos/Jan-${{ inputs.channel }}.app.tar.gz.sig s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-${{ inputs.channel }}/Jan-${{ inputs.channel }}_${{ inputs.new_version }}.app.tar.gz.sig
env:
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: ${{ secrets.DELTA_AWS_REGION }}
AWS_EC2_METADATA_DISABLED: 'true'
- name: Upload release assert if public provider is github
if: inputs.public_provider == 'github'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
uses: actions/upload-release-asset@v1.0.1
with:
upload_url: ${{ inputs.upload_url }}
asset_path: ./src-tauri/target/universal-apple-darwin/release/bundle/macos/${{ steps.metadata.outputs.FILE_NAME }}
asset_name: ${{ steps.metadata.outputs.FILE_NAME }}
asset_content_type: application/gzip
- name: Upload release assert if public provider is github
if: inputs.public_provider == 'github'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
uses: actions/upload-release-asset@v1.0.1
with:
upload_url: ${{ inputs.upload_url }}
asset_path: ./src-tauri/target/universal-apple-darwin/release/bundle/dmg/${{ steps.metadata.outputs.DMG_NAME }}
asset_name: ${{ steps.metadata.outputs.DMG_NAME }}
asset_content_type: application/octet-stream
- name: Upload release assert if public provider is github
if: inputs.public_provider == 'github'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
uses: actions/upload-release-asset@v1.0.1
with:
upload_url: ${{ inputs.upload_url }}
asset_path: ./src-tauri/target/universal-apple-darwin/release/bundle/macos/${{ steps.metadata.outputs.TAR_NAME }}
asset_name: ${{ steps.metadata.outputs.TAR_NAME }}
asset_content_type: application/gzip

View File

@ -0,0 +1,156 @@
name: tauri-build-windows-x64-external
on:
workflow_call:
inputs:
ref:
required: true
type: string
default: 'refs/heads/main'
new_version:
required: true
type: string
default: ''
channel:
required: true
type: string
default: 'nightly'
description: 'The channel to use for this job'
jobs:
build-windows-x64-external:
runs-on: windows-latest
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Replace Icons for Beta Build
if: inputs.channel != 'stable'
shell: bash
run: |
cp .github/scripts/icon-${{ inputs.channel }}.png src-tauri/icons/icon.png
- name: Installing node
uses: actions/setup-node@v1
with:
node-version: 20
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Install ctoml
run: |
cargo install ctoml
- name: Update app version
shell: bash
run: |
echo "Version: ${{ inputs.new_version }}"
# Update tauri.conf.json
jq --arg version "${{ inputs.new_version }}" '.version = $version | .bundle.createUpdaterArtifacts = false' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
jq '.bundle.windows.nsis.template = "tauri.bundle.windows.nsis.template"' ./src-tauri/tauri.windows.conf.json > /tmp/tauri.windows.conf.json
mv /tmp/tauri.windows.conf.json ./src-tauri/tauri.windows.conf.json
jq '.bundle.windows.signCommand = "echo External build - skipping signature: %1"' ./src-tauri/tauri.windows.conf.json > /tmp/tauri.windows.conf.json
mv /tmp/tauri.windows.conf.json ./src-tauri/tauri.windows.conf.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' web-app/package.json > /tmp/package.json
mv /tmp/package.json web-app/package.json
# Update tauri plugin versions
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-hardware/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-hardware/package.json
echo "---------./src-tauri/plugins/tauri-plugin-hardware/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-llamacpp/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
ctoml ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml
ctoml ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml
ctoml ./src-tauri/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/Cargo.toml---------"
cat ./src-tauri/Cargo.toml
generate_build_version() {
### Examble
### input 0.5.6 output will be 0.5.6 and 0.5.6.0
### input 0.5.6-rc2-beta output will be 0.5.6 and 0.5.6.2
### input 0.5.6-1213 output will be 0.5.6 and and 0.5.6.1213
local new_version="$1"
local base_version
local t_value
# Check if it has a "-"
if [[ "$new_version" == *-* ]]; then
base_version="${new_version%%-*}" # part before -
suffix="${new_version#*-}" # part after -
# Check if it is rcX-beta
if [[ "$suffix" =~ ^rc([0-9]+)-beta$ ]]; then
t_value="${BASH_REMATCH[1]}"
else
t_value="$suffix"
fi
else
base_version="$new_version"
t_value="0"
fi
# Export two values
new_base_version="$base_version"
new_build_version="${base_version}.${t_value}"
}
generate_build_version ${{ inputs.new_version }}
sed -i "s/jan_version/$new_base_version/g" ./src-tauri/tauri.bundle.windows.nsis.template
sed -i "s/jan_build/$new_build_version/g" ./src-tauri/tauri.bundle.windows.nsis.template
if [ "${{ inputs.channel }}" != "stable" ]; then
jq '.plugins.updater.endpoints = ["https://delta.jan.ai/${{ inputs.channel }}/latest.json"]' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
# Update product name
jq --arg name "Jan-${{ inputs.channel }}" '.productName = $name' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
chmod +x .github/scripts/rename-tauri-app.sh
.github/scripts/rename-tauri-app.sh ./src-tauri/tauri.conf.json ${{ inputs.channel }}
echo "---------tauri.conf.json---------"
cat ./src-tauri/tauri.conf.json
# Update Cargo.toml
ctoml ./src-tauri/Cargo.toml package.name "Jan-${{ inputs.channel }}"
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
echo "------------------"
cat ./src-tauri/Cargo.toml
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json ${{ inputs.channel }}
cat ./package.json
sed -i "s/jan_productname/Jan-${{ inputs.channel }}/g" ./src-tauri/tauri.bundle.windows.nsis.template
sed -i "s/jan_mainbinaryname/jan-${{ inputs.channel }}/g" ./src-tauri/tauri.bundle.windows.nsis.template
else
sed -i "s/jan_productname/Jan/g" ./src-tauri/tauri.bundle.windows.nsis.template
sed -i "s/jan_mainbinaryname/jan/g" ./src-tauri/tauri.bundle.windows.nsis.template
fi
echo "---------nsis.template---------"
cat ./src-tauri/tauri.bundle.windows.nsis.template
- name: Build app
shell: bash
run: |
make build
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: jan-windows-${{ inputs.new_version }}
path: |
./src-tauri/target/release/bundle/nsis/*.exe

View File

@ -0,0 +1,291 @@
name: tauri-build-windows-x64
on:
workflow_call:
inputs:
ref:
required: true
type: string
default: 'refs/heads/main'
public_provider:
required: true
type: string
default: none
description: 'none: build only, github: build and publish to github, aws s3: build and publish to aws s3'
new_version:
required: true
type: string
default: ''
cortex_api_port:
required: false
type: string
default: ''
upload_url:
required: false
type: string
default: ''
channel:
required: true
type: string
default: 'nightly'
description: 'The channel to use for this job'
secrets:
DELTA_AWS_S3_BUCKET_NAME:
required: false
DELTA_AWS_ACCESS_KEY_ID:
required: false
DELTA_AWS_SECRET_ACCESS_KEY:
required: false
AZURE_KEY_VAULT_URI:
required: false
AZURE_CLIENT_ID:
required: false
AZURE_TENANT_ID:
required: false
AZURE_CLIENT_SECRET:
required: false
AZURE_CERT_NAME:
required: false
TAURI_SIGNING_PRIVATE_KEY:
required: false
TAURI_SIGNING_PRIVATE_KEY_PASSWORD:
required: false
outputs:
WIN_SIG:
value: ${{ jobs.build-windows-x64.outputs.WIN_SIG }}
FILE_NAME:
value: ${{ jobs.build-windows-x64.outputs.FILE_NAME }}
MSI_FILE_NAME:
value: ${{ jobs.build-windows-x64.outputs.MSI_FILE_NAME }}
jobs:
build-windows-x64:
runs-on: windows-latest
outputs:
WIN_SIG: ${{ steps.metadata.outputs.WIN_SIG }}
FILE_NAME: ${{ steps.metadata.outputs.FILE_NAME }}
MSI_FILE_NAME: ${{ steps.metadata.outputs.MSI_FILE_NAME }}
permissions:
contents: write
steps:
- name: Getting the repo
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Replace Icons for Beta Build
if: inputs.channel != 'stable'
shell: bash
run: |
cp .github/scripts/icon-${{ inputs.channel }}.png src-tauri/icons/icon.png
- name: Installing node
uses: actions/setup-node@v1
with:
node-version: 20
- name: Install jq
uses: dcarbone/install-jq-action@v2.0.1
- name: Install ctoml
run: |
cargo install ctoml
- name: Update app version base on tag
id: version_update
shell: bash
run: |
echo "Version: ${{ inputs.new_version }}"
# Update tauri.conf.json
jq --arg version "${{ inputs.new_version }}" '.version = $version | .bundle.createUpdaterArtifacts = true' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
jq '.bundle.windows.nsis.template = "tauri.bundle.windows.nsis.template"' ./src-tauri/tauri.windows.conf.json > /tmp/tauri.windows.conf.json
mv /tmp/tauri.windows.conf.json ./src-tauri/tauri.windows.conf.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' web-app/package.json > /tmp/package.json
mv /tmp/package.json web-app/package.json
# Add sign commands to tauri.windows.conf.json
jq '.bundle.windows.signCommand = "powershell -ExecutionPolicy Bypass -File ./sign.ps1 %1"' ./src-tauri/tauri.windows.conf.json > /tmp/tauri.windows.conf.json
mv /tmp/tauri.windows.conf.json ./src-tauri/tauri.windows.conf.json
# Update tauri plugin versions
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-hardware/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-hardware/package.json
echo "---------./src-tauri/plugins/tauri-plugin-hardware/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/package.json
jq --arg version "${{ inputs.new_version }}" '.version = $version' ./src-tauri/plugins/tauri-plugin-llamacpp/package.json > /tmp/package.json
mv /tmp/package.json ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/package.json---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/package.json
ctoml ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-hardware/Cargo.toml
ctoml ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml---------"
cat ./src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml
ctoml ./src-tauri/Cargo.toml package.version "${{ inputs.new_version }}"
echo "---------./src-tauri/Cargo.toml---------"
cat ./src-tauri/Cargo.toml
generate_build_version() {
### Example
### input 0.5.6 output will be 0.5.6 and 0.5.6.0
### input 0.5.6-rc2-beta output will be 0.5.6 and 0.5.6.2
### input 0.5.6-1213 output will be 0.5.6 and and 0.5.6.1213
local new_version="$1"
local base_version
local t_value
# Check if it has a "-"
if [[ "$new_version" == *-* ]]; then
base_version="${new_version%%-*}" # part before -
suffix="${new_version#*-}" # part after -
# Check if it is rcX-beta
if [[ "$suffix" =~ ^rc([0-9]+)-beta$ ]]; then
t_value="${BASH_REMATCH[1]}"
else
t_value="$suffix"
fi
else
base_version="$new_version"
t_value="0"
fi
# Export two values
new_base_version="$base_version"
new_build_version="${base_version}.${t_value}"
}
generate_build_version ${{ inputs.new_version }}
sed -i "s/jan_version/$new_base_version/g" ./src-tauri/tauri.bundle.windows.nsis.template
sed -i "s/jan_build/$new_build_version/g" ./src-tauri/tauri.bundle.windows.nsis.template
echo "---------tauri.windows.conf.json---------"
cat ./src-tauri/tauri.windows.conf.json
# Temporarily enable devtool on prod build
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
cat ./src-tauri/Cargo.toml
# Change app name for beta and nightly builds
if [ "${{ inputs.channel }}" != "stable" ]; then
# Update updater endpoint
jq '.plugins.updater.endpoints = ["https://delta.jan.ai/${{ inputs.channel }}/latest.json"]' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
# Update product name
jq --arg name "Jan-${{ inputs.channel }}" '.productName = $name' ./src-tauri/tauri.conf.json > /tmp/tauri.conf.json
mv /tmp/tauri.conf.json ./src-tauri/tauri.conf.json
chmod +x .github/scripts/rename-tauri-app.sh
.github/scripts/rename-tauri-app.sh ./src-tauri/tauri.conf.json ${{ inputs.channel }}
echo "---------tauri.conf.json---------"
cat ./src-tauri/tauri.conf.json
# Update Cargo.toml
ctoml ./src-tauri/Cargo.toml package.name "Jan-${{ inputs.channel }}"
ctoml ./src-tauri/Cargo.toml dependencies.tauri.features[] "devtools"
echo "------------------"
cat ./src-tauri/Cargo.toml
chmod +x .github/scripts/rename-workspace.sh
.github/scripts/rename-workspace.sh ./package.json ${{ inputs.channel }}
cat ./package.json
sed -i "s/jan_productname/Jan-${{ inputs.channel }}/g" ./src-tauri/tauri.bundle.windows.nsis.template
sed -i "s/jan_mainbinaryname/jan-${{ inputs.channel }}/g" ./src-tauri/tauri.bundle.windows.nsis.template
else
sed -i "s/jan_productname/Jan/g" ./src-tauri/tauri.bundle.windows.nsis.template
sed -i "s/jan_mainbinaryname/jan/g" ./src-tauri/tauri.bundle.windows.nsis.template
fi
echo "---------nsis.template---------"
cat ./src-tauri/tauri.bundle.windows.nsis.template
- name: Install AzureSignTool
run: |
dotnet tool install --global --version 6.0.0 AzureSignTool
- name: Build app
shell: bash
run: |
make build
env:
AZURE_KEY_VAULT_URI: ${{ secrets.AZURE_KEY_VAULT_URI }}
AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }}
AZURE_CERT_NAME: ${{ secrets.AZURE_CERT_NAME }}
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: auto
AWS_EC2_METADATA_DISABLED: 'true'
AWS_MAX_ATTEMPTS: '5'
POSTHOG_KEY: ${{ secrets.POSTHOG_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: jan-windows-exe-${{ inputs.new_version }}
path: |
./src-tauri/target/release/bundle/nsis/*.exe
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: jan-windows-msi-${{ inputs.new_version }}
path: |
./src-tauri/target/release/bundle/msi/*.msi
## Set output filename for windows
- name: Set output filename for windows
shell: bash
run: |
cd ./src-tauri/target/release/bundle/nsis
if [ "${{ inputs.channel }}" != "stable" ]; then
FILE_NAME=Jan-${{ inputs.channel }}_${{ inputs.new_version }}_x64-setup.exe
WIN_SIG=$(cat Jan-${{ inputs.channel }}_${{ inputs.new_version }}_x64-setup.exe.sig)
MSI_FILE="Jan-${{ inputs.channel }}_${{ inputs.new_version }}_x64_en-US.msi"
else
FILE_NAME=Jan_${{ inputs.new_version }}_x64-setup.exe
WIN_SIG=$(cat Jan_${{ inputs.new_version }}_x64-setup.exe.sig)
MSI_FILE="Jan_${{ inputs.new_version }}_x64_en-US.msi"
fi
echo "::set-output name=WIN_SIG::$WIN_SIG"
echo "::set-output name=FILE_NAME::$FILE_NAME"
echo "::set-output name=MSI_FILE_NAME::$MSI_FILE"
id: metadata
## Upload to s3 for nightly and beta
- name: upload to aws s3 if public provider is aws
shell: bash
if: inputs.public_provider == 'aws-s3' || inputs.channel == 'beta'
run: |
cd ./src-tauri/target/release/bundle/nsis
# Upload for tauri updater
aws s3 cp ./${{ steps.metadata.outputs.FILE_NAME }} s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-${{ inputs.channel }}/${{ steps.metadata.outputs.FILE_NAME }}
aws s3 cp ./${{ steps.metadata.outputs.FILE_NAME }}.sig s3://${{ secrets.DELTA_AWS_S3_BUCKET_NAME }}/temp-${{ inputs.channel }}/${{ steps.metadata.outputs.FILE_NAME }}.sig
env:
AWS_ACCESS_KEY_ID: ${{ secrets.DELTA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DELTA_AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: ${{ secrets.DELTA_AWS_REGION }}
AWS_EC2_METADATA_DISABLED: 'true'
- name: Upload release assert if public provider is github
if: inputs.public_provider == 'github'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
uses: actions/upload-release-asset@v1.0.1
with:
upload_url: ${{ inputs.upload_url }}
asset_path: ./src-tauri/target/release/bundle/nsis/${{ steps.metadata.outputs.FILE_NAME }}
asset_name: ${{ steps.metadata.outputs.FILE_NAME }}
asset_content_type: application/octet-stream

84
.gitignore vendored
View File

@ -1,53 +1,65 @@
.vscode
.idea
.env
.idea
# Jan inference
error.log
node_modules
*.tgz
!charts/server/charts/*.tgz
dist
build
.DS_Store
electron/renderer
electron/models
electron/docs
electron/engines
electron/themes
electron/playwright-report
server/pre-install
package-lock.json
coverage
*.log
core/lib/**
# Nitro binary files
extensions/*-extension/bin/*/nitro
extensions/*-extension/bin/*/*.metal
extensions/*-extension/bin/*/*.exe
extensions/*-extension/bin/*/*.dll
extensions/*-extension/bin/*/*.exp
extensions/*-extension/bin/*/*.lib
extensions/*-extension/bin/saved-*
extensions/*-extension/bin/*.tar.gz
extensions/*-extension/bin/vulkaninfoSDK.exe
extensions/*-extension/bin/vulkaninfo
# Turborepo
.turbo
electron/test-data
electron/test-results
core/test_results.html
coverage
.yarn
.yarnrc
test_results.html
*.tsbuildinfo
electron/shared/**
test_results.html
pre-install
# docs
docs/yarn.lock
electron/.version.bak
src-tauri/resources/lib
src-tauri/icons
!src-tauri/icons/icon.png
src-tauri/gen/apple
src-tauri/gen/android
src-tauri/resources/bin
# Helper tools
.opencode
OpenCode.md
Claude.md
archive/
.cache/
# auto qa
autoqa/trajectories
autoqa/recordings
autoqa/__pycache__
# Astro / Starlight specific
website/dist/
website/.astro/
website/src/content/config.ts.timestamp-*
# Nextra specific
docs/out/
docs/.next/
# General Node.js
**/node_modules
**/.env
**/.env.*
**/npm-debug.log*
**/yarn-debug.log*
**/yarn-error.log*
**/pnpm-debug.log*
## cargo
target
Cargo.lock
src-tauri/resources/
## test
test-data
llm-docs
.claude/agents

View File

@ -1 +1 @@
npx oxlint@latest --fix
yarn lint --fix --quiet

View File

@ -1,32 +1,252 @@
# Contributing to jan
# Contributing to Jan
First off, thank you for considering contributing to jan. It's people like you that make jan such an amazing project.
First off, thank you for considering contributing to Jan. It's people like you that make Jan such an amazing project.
Jan is an AI assistant that can run 100% offline on your device. Think ChatGPT, but private, local, and under your complete control. If you're thinking about contributing, you're already awesome - let's make AI accessible to everyone, one commit at a time.
## Quick Links to Component Guides
- **[Web App](./web-app/CONTRIBUTING.md)** - React UI and logic
- **[Core SDK](./core/CONTRIBUTING.md)** - TypeScript SDK and extension system
- **[Extensions](./extensions/CONTRIBUTING.md)** - Supportive modules for the frontend
- **[Tauri Backend](./src-tauri/CONTRIBUTING.md)** - Rust native integration
- **[Tauri Plugins](./src-tauri/plugins/CONTRIBUTING.md)** - Hardware and system plugins
## How Jan Actually Works
Jan is a desktop app that runs local AI models. Here's how the components actually connect:
```
┌──────────────────────────────────────────────────────────┐
│ Web App (Frontend) │
│ (web-app/) │
│ • React UI │
│ • Chat Interface │
│ • Settings Pages │
│ • Model Hub │
└────────────┬─────────────────────────────┬───────────────┘
│ │
│ imports │ imports
▼ ▼
┌──────────────────────┐ ┌──────────────────────┐
│ Core SDK │ │ Extensions │
│ (core/) │ │ (extensions/) │
│ │ │ │
│ • TypeScript APIs │◄─────│ • Assistant Mgmt │
│ • Extension System │ uses │ • Conversations │
│ • Event Bus │ │ • Downloads │
│ • Type Definitions │ │ • LlamaCPP │
└──────────┬───────────┘ └───────────┬──────────┘
│ │
│ ┌──────────────────────┐ │
│ │ Web App │ │
│ └──────────┬───────────┘ │
│ │ │
└──────────────┼───────────────┘
Tauri IPC
(invoke commands)
┌───────────────────────────────────────────────────────────┐
│ Tauri Backend (Rust) │
│ (src-tauri/) │
│ │
│ • Window Management • File System Access │
│ • Process Control • System Integration │
│ • IPC Command Handler • Security & Permissions │
└───────────────────────────┬───────────────────────────────┘
┌───────────────────────────────────────────────────────────┐
│ Tauri Plugins (Rust) │
│ (src-tauri/plugins/) │
│ │
│ ┌──────────────────┐ ┌──────────────────┐ │
│ │ Hardware Plugin │ │ LlamaCPP Plugin │ │
│ │ │ │ │ │
│ │ • CPU/GPU Info │ │ • Process Mgmt │ │
│ │ • Memory Stats │ │ • Model Loading │ │
│ │ • System Info │ │ • Inference │ │
│ └──────────────────┘ └──────────────────┘ │
└───────────────────────────────────────────────────────────┘
```
### The Communication Flow
1. **JavaScript Layer Relationships**:
- Web App imports Core SDK and Extensions as JavaScript modules
- Extensions use Core SDK for shared functionality
- All run in the browser/webview context
2. **All Three → Backend**: Through Tauri IPC
- **Web App** → Backend: `await invoke('app_command', data)`
- **Core SDK** → Backend: `await invoke('core_command', data)`
- **Extensions** → Backend: `await invoke('ext_command', data)`
- Each component can independently call backend commands
3. **Backend → Plugins**: Native Rust integration
- Backend loads plugins as Rust libraries
- Direct function calls, no IPC overhead
4. **Response Flow**:
- Plugin → Backend → IPC → Requester (Web App/Core/Extension) → UI updates
### Real-World Example: Loading a Model
Here's what actually happens when you click "Download Llama 3":
1. **Web App** (`web-app/`) - User clicks download button
2. **Extension** (`extensions/download-extension`) - Handles the download logic
3. **Tauri Backend** (`src-tauri/`) - Actually downloads the file to disk
4. **Extension** (`extensions/llamacpp-extension`) - Prepares model for loading
5. **Tauri Plugin** (`src-tauri/plugins/llamacpp`) - Starts llama.cpp process
6. **Hardware Plugin** (`src-tauri/plugins/hardware`) - Detects GPU, optimizes settings
7. **Model ready!** - User can start chatting
## Project Structure
```
jan/
├── web-app/ # React frontend (what users see)
├── src-tauri/ # Rust backend (system integration)
│ ├── src/core/ # Core Tauri commands
│ └── plugins/ # Tauri plugins (hardware, llamacpp)
├── core/ # TypeScript SDK (API layer)
├── extensions/ # JavaScript extensions
│ ├── assistant-extension/
│ ├── conversational-extension/
│ ├── download-extension/
│ └── llamacpp-extension/
├── docs/ # Documentation website
├── website/ # Marketing website
├── autoqa/ # Automated testing
├── scripts/ # Build utilities
├── package.json # Root workspace configuration
├── Makefile # Build automation commands
├── LICENSE # Apache 2.0 license
└── README.md # Project overview
```
## Development Setup
### The Scenic Route (Build from Source)
**Prerequisites:**
- Node.js ≥ 20.0.0
- Yarn ≥ 1.22.0
- Rust (for Tauri)
- Make ≥ 3.81
**Option 1: The Easy Way (Make)**
```bash
git clone https://github.com/janhq/jan
cd jan
make dev
```
## How Can I Contribute?
### Reporting Bugs
- **Ensure the bug was not already reported** by searching on GitHub under [Issues](https://github.com/janhq/jan/issues).
- If you're unable to find an open issue addressing the problem, [open a new one](https://github.com/janhq/jan/issues/new).
- **Ensure the bug was not already reported** by searching on GitHub under [Issues](https://github.com/janhq/jan/issues)
- If you're unable to find an open issue addressing the problem, [open a new one](https://github.com/janhq/jan/issues/new)
- Include your system specs and error logs - it helps a ton
### Suggesting Enhancements
- Open a new issue with a clear title and description.
- Open a new issue with a clear title and description
- Explain why this enhancement would be useful
- Include mockups or examples if you can
### Your First Code Contribution
- Fork the repo.
- Create a new branch (`git checkout -b feature-name`).
- Commit your changes (`git commit -am 'Add some feature'`).
- Push to the branch (`git push origin feature-name`).
- Open a new Pull Request.
**Choose Your Adventure:**
- **Frontend UI and logic**`web-app/`
- **Shared API declarations**`core/`
- **Backend system integration**`src-tauri/`
- **Business logic features**`extensions/`
- **Dedicated backend handler**`src-tauri/plugins/`
## Styleguides
**The Process:**
1. Fork the repo
2. Create a new branch (`git checkout -b feature-name`)
3. Make your changes (and write tests!)
4. Commit your changes (`git commit -am 'Add some feature'`)
5. Push to the branch (`git push origin feature-name`)
6. Open a new Pull Request against `dev` branch
### Git Commit Messages
## Testing
- Use the present tense ("Add feature" not "Added feature").
```bash
yarn test # All tests
cd src-tauri && cargo test # Rust tests
cd autoqa && python main.py # End-to-end tests
```
## Code Standards
### TypeScript/JavaScript
- TypeScript required (we're not animals)
- ESLint + Prettier
- Functional React components
- Proper typing (no `any` - seriously!)
### Rust
- `cargo fmt` + `cargo clippy`
- `Result<T, E>` for error handling
- Document public APIs
## Git Conventions
### Branches
- `main` - stable releases
- `dev` - development (target this for PRs)
- `feature/*` - new features
- `fix/*` - bug fixes
### Commit Messages
- Use the present tense ("Add feature" not "Added feature")
- Be descriptive but concise
- Reference issues when applicable
Examples:
```
feat: add support for Qwen models
fix: resolve memory leak in model loading
docs: update installation instructions
```
## Troubleshooting
If things go sideways:
1. **Check our [troubleshooting docs](https://jan.ai/docs/troubleshooting)**
2. **Clear everything and start fresh:** `make clean` then `make dev`
3. **Copy your error logs and system specs**
4. **Ask for help in our [Discord](https://discord.gg/FTk2MvZwJH)** `#🆘|jan-help` channel
Common issues:
- **Build failures**: Check Node.js and Rust versions
- **Extension not loading**: Verify it's properly registered
- **Model not working**: Check hardware requirements and GPU drivers
## Getting Help
- [Documentation](https://jan.ai/docs) - The manual you should read
- [Discord Community](https://discord.gg/jan) - Where the community lives
- [GitHub Issues](https://github.com/janhq/jan/issues) - Report bugs here
- [GitHub Discussions](https://github.com/janhq/jan/discussions) - Ask questions
## License
Apache 2.0 - Because sharing is caring. See [LICENSE](./LICENSE) for the legal stuff.
## Additional Notes
Thank you for contributing to jan!
We're building something pretty cool here - an AI assistant that respects your privacy and runs entirely on your machine. Every contribution, no matter how small, helps make AI more accessible to everyone.
Thanks for being part of the journey. Let's build the future of local AI together! 🚀

50
Dockerfile Normal file
View File

@ -0,0 +1,50 @@
# Stage 1: Build stage with Node.js and Yarn v4
FROM node:20-alpine AS builder
ARG MENLO_PLATFORM_BASE_URL=https://api-dev.menlo.ai/v1
ENV MENLO_PLATFORM_BASE_URL=$MENLO_PLATFORM_BASE_URL
# Install build dependencies
RUN apk add --no-cache \
make \
g++ \
python3 \
py3-pip \
git
# Enable corepack and install Yarn 4
RUN corepack enable && corepack prepare yarn@4.5.3 --activate
# Verify Yarn version
RUN yarn --version
# Set working directory
WORKDIR /app
# Copy source code
COPY ./extensions-web ./extensions-web
COPY ./web-app ./web-app
COPY ./Makefile ./Makefile
COPY ./.* /
COPY ./package.json ./package.json
COPY ./yarn.lock ./yarn.lock
COPY ./pre-install ./pre-install
COPY ./core ./core
# Build web application
RUN yarn install && yarn build:core && make build-web-app
# Stage 2: Production stage with Nginx
FROM nginx:alpine
# Copy static files from build stage
COPY --from=builder /app/web-app/dist-web /usr/share/nginx/html
# Copy custom nginx config
COPY nginx.conf /etc/nginx/conf.d/default.conf
# Expose port 80
EXPOSE 80
# Start nginx
CMD ["nginx", "-g", "daemon off;"]

667
LICENSE
View File

@ -1,660 +1,19 @@
# GNU AFFERO GENERAL PUBLIC LICENSE
Jan
Version 3, 19 November 2007
Copyright 2025 Menlo Research
Copyright (C) 2007 Free Software Foundation, Inc.
<https://fsf.org/>
This product includes software developed by Menlo Research (https://menlo.ai).
Everyone is permitted to copy and distribute verbatim copies of this
license document, but changing it is not allowed.
Licensed under the Apache License, Version 2.0 (the "License");
You may not use this file except in compliance with the License.
You may obtain a copy of the License at
## Preamble
http://www.apache.org/licenses/LICENSE-2.0
The GNU Affero General Public License is a free, copyleft license for
software and other kinds of works, specifically designed to ensure
cooperation with the community in the case of network server software.
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
The licenses for most software and other practical works are designed
to take away your freedom to share and change the works. By contrast,
our General Public Licenses are intended to guarantee your freedom to
share and change all versions of a program--to make sure it remains
free software for all its users.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
them if you wish), that you receive source code or can get it if you
want it, that you can change the software or use pieces of it in new
free programs, and that you know you can do these things.
Developers that use our General Public Licenses protect your rights
with two steps: (1) assert copyright on the software, and (2) offer
you this License which gives you legal permission to copy, distribute
and/or modify the software.
A secondary benefit of defending all users' freedom is that
improvements made in alternate versions of the program, if they
receive widespread use, become available for other developers to
incorporate. Many developers of free software are heartened and
encouraged by the resulting cooperation. However, in the case of
software used on network servers, this result may fail to come about.
The GNU General Public License permits making a modified version and
letting the public access it on a server without ever releasing its
source code to the public.
The GNU Affero General Public License is designed specifically to
ensure that, in such cases, the modified source code becomes available
to the community. It requires the operator of a network server to
provide the source code of the modified version running there to the
users of that server. Therefore, public use of a modified version, on
a publicly accessible server, gives the public access to the source
code of the modified version.
An older license, called the Affero General Public License and
published by Affero, was designed to accomplish similar goals. This is
a different license, not a version of the Affero GPL, but Affero has
released a new version of the Affero GPL which permits relicensing
under this license.
The precise terms and conditions for copying, distribution and
modification follow.
## TERMS AND CONDITIONS
### 0. Definitions.
"This License" refers to version 3 of the GNU Affero General Public
License.
"Copyright" also means copyright-like laws that apply to other kinds
of works, such as semiconductor masks.
"The Program" refers to any copyrightable work licensed under this
License. Each licensee is addressed as "you". "Licensees" and
"recipients" may be individuals or organizations.
To "modify" a work means to copy from or adapt all or part of the work
in a fashion requiring copyright permission, other than the making of
an exact copy. The resulting work is called a "modified version" of
the earlier work or a work "based on" the earlier work.
A "covered work" means either the unmodified Program or a work based
on the Program.
To "propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy. Propagation includes copying,
distribution (with or without modification), making available to the
public, and in some countries other activities as well.
To "convey" a work means any kind of propagation that enables other
parties to make or receive copies. Mere interaction with a user
through a computer network, with no transfer of a copy, is not
conveying.
An interactive user interface displays "Appropriate Legal Notices" to
the extent that it includes a convenient and prominently visible
feature that (1) displays an appropriate copyright notice, and (2)
tells the user that there is no warranty for the work (except to the
extent that warranties are provided), that licensees may convey the
work under this License, and how to view a copy of this License. If
the interface presents a list of user commands or options, such as a
menu, a prominent item in the list meets this criterion.
### 1. Source Code.
The "source code" for a work means the preferred form of the work for
making modifications to it. "Object code" means any non-source form of
a work.
A "Standard Interface" means an interface that either is an official
standard defined by a recognized standards body, or, in the case of
interfaces specified for a particular programming language, one that
is widely used among developers working in that language.
The "System Libraries" of an executable work include anything, other
than the work as a whole, that (a) is included in the normal form of
packaging a Major Component, but which is not part of that Major
Component, and (b) serves only to enable use of the work with that
Major Component, or to implement a Standard Interface for which an
implementation is available to the public in source code form. A
"Major Component", in this context, means a major essential component
(kernel, window system, and so on) of the specific operating system
(if any) on which the executable work runs, or a compiler used to
produce the work, or an object code interpreter used to run it.
The "Corresponding Source" for a work in object code form means all
the source code needed to generate, install, and (for an executable
work) run the object code and to modify the work, including scripts to
control those activities. However, it does not include the work's
System Libraries, or general-purpose tools or generally available free
programs which are used unmodified in performing those activities but
which are not part of the work. For example, Corresponding Source
includes interface definition files associated with source files for
the work, and the source code for shared libraries and dynamically
linked subprograms that the work is specifically designed to require,
such as by intimate data communication or control flow between those
subprograms and other parts of the work.
The Corresponding Source need not include anything that users can
regenerate automatically from other parts of the Corresponding Source.
The Corresponding Source for a work in source code form is that same
work.
### 2. Basic Permissions.
All rights granted under this License are granted for the term of
copyright on the Program, and are irrevocable provided the stated
conditions are met. This License explicitly affirms your unlimited
permission to run the unmodified Program. The output from running a
covered work is covered by this License only if the output, given its
content, constitutes a covered work. This License acknowledges your
rights of fair use or other equivalent, as provided by copyright law.
You may make, run and propagate covered works that you do not convey,
without conditions so long as your license otherwise remains in force.
You may convey covered works to others for the sole purpose of having
them make modifications exclusively for you, or provide you with
facilities for running those works, provided that you comply with the
terms of this License in conveying all material for which you do not
control copyright. Those thus making or running the covered works for
you must do so exclusively on your behalf, under your direction and
control, on terms that prohibit them from making any copies of your
copyrighted material outside their relationship with you.
Conveying under any other circumstances is permitted solely under the
conditions stated below. Sublicensing is not allowed; section 10 makes
it unnecessary.
### 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
No covered work shall be deemed part of an effective technological
measure under any applicable law fulfilling obligations under article
11 of the WIPO copyright treaty adopted on 20 December 1996, or
similar laws prohibiting or restricting circumvention of such
measures.
When you convey a covered work, you waive any legal power to forbid
circumvention of technological measures to the extent such
circumvention is effected by exercising rights under this License with
respect to the covered work, and you disclaim any intention to limit
operation or modification of the work as a means of enforcing, against
the work's users, your or third parties' legal rights to forbid
circumvention of technological measures.
### 4. Conveying Verbatim Copies.
You may convey verbatim copies of the Program's source code as you
receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice;
keep intact all notices stating that this License and any
non-permissive terms added in accord with section 7 apply to the code;
keep intact all notices of the absence of any warranty; and give all
recipients a copy of this License along with the Program.
You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.
### 5. Conveying Modified Source Versions.
You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
terms of section 4, provided that you also meet all of these
conditions:
- a) The work must carry prominent notices stating that you modified
it, and giving a relevant date.
- b) The work must carry prominent notices stating that it is
released under this License and any conditions added under
section 7. This requirement modifies the requirement in section 4
to "keep intact all notices".
- c) You must license the entire work, as a whole, under this
License to anyone who comes into possession of a copy. This
License will therefore apply, along with any applicable section 7
additional terms, to the whole of the work, and all its parts,
regardless of how they are packaged. This License gives no
permission to license the work in any other way, but it does not
invalidate such permission if you have separately received it.
- d) If the work has interactive user interfaces, each must display
Appropriate Legal Notices; however, if the Program has interactive
interfaces that do not display Appropriate Legal Notices, your
work need not make them do so.
A compilation of a covered work with other separate and independent
works, which are not by their nature extensions of the covered work,
and which are not combined with it such as to form a larger program,
in or on a volume of a storage or distribution medium, is called an
"aggregate" if the compilation and its resulting copyright are not
used to limit the access or legal rights of the compilation's users
beyond what the individual works permit. Inclusion of a covered work
in an aggregate does not cause this License to apply to the other
parts of the aggregate.
### 6. Conveying Non-Source Forms.
You may convey a covered work in object code form under the terms of
sections 4 and 5, provided that you also convey the machine-readable
Corresponding Source under the terms of this License, in one of these
ways:
- a) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by the
Corresponding Source fixed on a durable physical medium
customarily used for software interchange.
- b) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by a
written offer, valid for at least three years and valid for as
long as you offer spare parts or customer support for that product
model, to give anyone who possesses the object code either (1) a
copy of the Corresponding Source for all the software in the
product that is covered by this License, on a durable physical
medium customarily used for software interchange, for a price no
more than your reasonable cost of physically performing this
conveying of source, or (2) access to copy the Corresponding
Source from a network server at no charge.
- c) Convey individual copies of the object code with a copy of the
written offer to provide the Corresponding Source. This
alternative is allowed only occasionally and noncommercially, and
only if you received the object code with such an offer, in accord
with subsection 6b.
- d) Convey the object code by offering access from a designated
place (gratis or for a charge), and offer equivalent access to the
Corresponding Source in the same way through the same place at no
further charge. You need not require recipients to copy the
Corresponding Source along with the object code. If the place to
copy the object code is a network server, the Corresponding Source
may be on a different server (operated by you or a third party)
that supports equivalent copying facilities, provided you maintain
clear directions next to the object code saying where to find the
Corresponding Source. Regardless of what server hosts the
Corresponding Source, you remain obligated to ensure that it is
available for as long as needed to satisfy these requirements.
- e) Convey the object code using peer-to-peer transmission,
provided you inform other peers where the object code and
Corresponding Source of the work are being offered to the general
public at no charge under subsection 6d.
A separable portion of the object code, whose source code is excluded
from the Corresponding Source as a System Library, need not be
included in conveying the object code work.
A "User Product" is either (1) a "consumer product", which means any
tangible personal property which is normally used for personal,
family, or household purposes, or (2) anything designed or sold for
incorporation into a dwelling. In determining whether a product is a
consumer product, doubtful cases shall be resolved in favor of
coverage. For a particular product received by a particular user,
"normally used" refers to a typical or common use of that class of
product, regardless of the status of the particular user or of the way
in which the particular user actually uses, or expects or is expected
to use, the product. A product is a consumer product regardless of
whether the product has substantial commercial, industrial or
non-consumer uses, unless such uses represent the only significant
mode of use of the product.
"Installation Information" for a User Product means any methods,
procedures, authorization keys, or other information required to
install and execute modified versions of a covered work in that User
Product from a modified version of its Corresponding Source. The
information must suffice to ensure that the continued functioning of
the modified object code is in no case prevented or interfered with
solely because modification has been made.
If you convey an object code work under this section in, or with, or
specifically for use in, a User Product, and the conveying occurs as
part of a transaction in which the right of possession and use of the
User Product is transferred to the recipient in perpetuity or for a
fixed term (regardless of how the transaction is characterized), the
Corresponding Source conveyed under this section must be accompanied
by the Installation Information. But this requirement does not apply
if neither you nor any third party retains the ability to install
modified object code on the User Product (for example, the work has
been installed in ROM).
The requirement to provide Installation Information does not include a
requirement to continue to provide support service, warranty, or
updates for a work that has been modified or installed by the
recipient, or for the User Product in which it has been modified or
installed. Access to a network may be denied when the modification
itself materially and adversely affects the operation of the network
or violates the rules and protocols for communication across the
network.
Corresponding Source conveyed, and Installation Information provided,
in accord with this section must be in a format that is publicly
documented (and with an implementation available to the public in
source code form), and must require no special password or key for
unpacking, reading or copying.
### 7. Additional Terms.
"Additional permissions" are terms that supplement the terms of this
License by making exceptions from one or more of its conditions.
Additional permissions that are applicable to the entire Program shall
be treated as though they were included in this License, to the extent
that they are valid under applicable law. If additional permissions
apply only to part of the Program, that part may be used separately
under those permissions, but the entire Program remains governed by
this License without regard to the additional permissions.
When you convey a copy of a covered work, you may at your option
remove any additional permissions from that copy, or from any part of
it. (Additional permissions may be written to require their own
removal in certain cases when you modify the work.) You may place
additional permissions on material, added by you to a covered work,
for which you have or can give appropriate copyright permission.
Notwithstanding any other provision of this License, for material you
add to a covered work, you may (if authorized by the copyright holders
of that material) supplement the terms of this License with terms:
- a) Disclaiming warranty or limiting liability differently from the
terms of sections 15 and 16 of this License; or
- b) Requiring preservation of specified reasonable legal notices or
author attributions in that material or in the Appropriate Legal
Notices displayed by works containing it; or
- c) Prohibiting misrepresentation of the origin of that material,
or requiring that modified versions of such material be marked in
reasonable ways as different from the original version; or
- d) Limiting the use for publicity purposes of names of licensors
or authors of the material; or
- e) Declining to grant rights under trademark law for use of some
trade names, trademarks, or service marks; or
- f) Requiring indemnification of licensors and authors of that
material by anyone who conveys the material (or modified versions
of it) with contractual assumptions of liability to the recipient,
for any liability that these contractual assumptions directly
impose on those licensors and authors.
All other non-permissive additional terms are considered "further
restrictions" within the meaning of section 10. If the Program as you
received it, or any part of it, contains a notice stating that it is
governed by this License along with a term that is a further
restriction, you may remove that term. If a license document contains
a further restriction but permits relicensing or conveying under this
License, you may add to a covered work material governed by the terms
of that license document, provided that the further restriction does
not survive such relicensing or conveying.
If you add terms to a covered work in accord with this section, you
must place, in the relevant source files, a statement of the
additional terms that apply to those files, or a notice indicating
where to find the applicable terms.
Additional terms, permissive or non-permissive, may be stated in the
form of a separately written license, or stated as exceptions; the
above requirements apply either way.
### 8. Termination.
You may not propagate or modify a covered work except as expressly
provided under this License. Any attempt otherwise to propagate or
modify it is void, and will automatically terminate your rights under
this License (including any patent licenses granted under the third
paragraph of section 11).
However, if you cease all violation of this License, then your license
from a particular copyright holder is reinstated (a) provisionally,
unless and until the copyright holder explicitly and finally
terminates your license, and (b) permanently, if the copyright holder
fails to notify you of the violation by some reasonable means prior to
60 days after the cessation.
Moreover, your license from a particular copyright holder is
reinstated permanently if the copyright holder notifies you of the
violation by some reasonable means, this is the first time you have
received notice of violation of this License (for any work) from that
copyright holder, and you cure the violation prior to 30 days after
your receipt of the notice.
Termination of your rights under this section does not terminate the
licenses of parties who have received copies or rights from you under
this License. If your rights have been terminated and not permanently
reinstated, you do not qualify to receive new licenses for the same
material under section 10.
### 9. Acceptance Not Required for Having Copies.
You are not required to accept this License in order to receive or run
a copy of the Program. Ancillary propagation of a covered work
occurring solely as a consequence of using peer-to-peer transmission
to receive a copy likewise does not require acceptance. However,
nothing other than this License grants you permission to propagate or
modify any covered work. These actions infringe copyright if you do
not accept this License. Therefore, by modifying or propagating a
covered work, you indicate your acceptance of this License to do so.
### 10. Automatic Licensing of Downstream Recipients.
Each time you convey a covered work, the recipient automatically
receives a license from the original licensors, to run, modify and
propagate that work, subject to this License. You are not responsible
for enforcing compliance by third parties with this License.
An "entity transaction" is a transaction transferring control of an
organization, or substantially all assets of one, or subdividing an
organization, or merging organizations. If propagation of a covered
work results from an entity transaction, each party to that
transaction who receives a copy of the work also receives whatever
licenses to the work the party's predecessor in interest had or could
give under the previous paragraph, plus a right to possession of the
Corresponding Source of the work from the predecessor in interest, if
the predecessor has it or can get it with reasonable efforts.
You may not impose any further restrictions on the exercise of the
rights granted or affirmed under this License. For example, you may
not impose a license fee, royalty, or other charge for exercise of
rights granted under this License, and you may not initiate litigation
(including a cross-claim or counterclaim in a lawsuit) alleging that
any patent claim is infringed by making, using, selling, offering for
sale, or importing the Program or any portion of it.
### 11. Patents.
A "contributor" is a copyright holder who authorizes use under this
License of the Program or a work on which the Program is based. The
work thus licensed is called the contributor's "contributor version".
A contributor's "essential patent claims" are all patent claims owned
or controlled by the contributor, whether already acquired or
hereafter acquired, that would be infringed by some manner, permitted
by this License, of making, using, or selling its contributor version,
but do not include claims that would be infringed only as a
consequence of further modification of the contributor version. For
purposes of this definition, "control" includes the right to grant
patent sublicenses in a manner consistent with the requirements of
this License.
Each contributor grants you a non-exclusive, worldwide, royalty-free
patent license under the contributor's essential patent claims, to
make, use, sell, offer for sale, import and otherwise run, modify and
propagate the contents of its contributor version.
In the following three paragraphs, a "patent license" is any express
agreement or commitment, however denominated, not to enforce a patent
(such as an express permission to practice a patent or covenant not to
sue for patent infringement). To "grant" such a patent license to a
party means to make such an agreement or commitment not to enforce a
patent against the party.
If you convey a covered work, knowingly relying on a patent license,
and the Corresponding Source of the work is not available for anyone
to copy, free of charge and under the terms of this License, through a
publicly available network server or other readily accessible means,
then you must either (1) cause the Corresponding Source to be so
available, or (2) arrange to deprive yourself of the benefit of the
patent license for this particular work, or (3) arrange, in a manner
consistent with the requirements of this License, to extend the patent
license to downstream recipients. "Knowingly relying" means you have
actual knowledge that, but for the patent license, your conveying the
covered work in a country, or your recipient's use of the covered work
in a country, would infringe one or more identifiable patents in that
country that you have reason to believe are valid.
If, pursuant to or in connection with a single transaction or
arrangement, you convey, or propagate by procuring conveyance of, a
covered work, and grant a patent license to some of the parties
receiving the covered work authorizing them to use, propagate, modify
or convey a specific copy of the covered work, then the patent license
you grant is automatically extended to all recipients of the covered
work and works based on it.
A patent license is "discriminatory" if it does not include within the
scope of its coverage, prohibits the exercise of, or is conditioned on
the non-exercise of one or more of the rights that are specifically
granted under this License. You may not convey a covered work if you
are a party to an arrangement with a third party that is in the
business of distributing software, under which you make payment to the
third party based on the extent of your activity of conveying the
work, and under which the third party grants, to any of the parties
who would receive the covered work from you, a discriminatory patent
license (a) in connection with copies of the covered work conveyed by
you (or copies made from those copies), or (b) primarily for and in
connection with specific products or compilations that contain the
covered work, unless you entered into that arrangement, or that patent
license was granted, prior to 28 March 2007.
Nothing in this License shall be construed as excluding or limiting
any implied license or other defenses to infringement that may
otherwise be available to you under applicable patent law.
### 12. No Surrender of Others' Freedom.
If conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot convey a
covered work so as to satisfy simultaneously your obligations under
this License and any other pertinent obligations, then as a
consequence you may not convey it at all. For example, if you agree to
terms that obligate you to collect a royalty for further conveying
from those to whom you convey the Program, the only way you could
satisfy both those terms and this License would be to refrain entirely
from conveying the Program.
### 13. Remote Network Interaction; Use with the GNU General Public License.
Notwithstanding any other provision of this License, if you modify the
Program, your modified version must prominently offer all users
interacting with it remotely through a computer network (if your
version supports such interaction) an opportunity to receive the
Corresponding Source of your version by providing access to the
Corresponding Source from a network server at no charge, through some
standard or customary means of facilitating copying of software. This
Corresponding Source shall include the Corresponding Source for any
work covered by version 3 of the GNU General Public License that is
incorporated pursuant to the following paragraph.
Notwithstanding any other provision of this License, you have
permission to link or combine any covered work with a work licensed
under version 3 of the GNU General Public License into a single
combined work, and to convey the resulting work. The terms of this
License will continue to apply to the part which is the covered work,
but the work with which it is combined will remain governed by version
3 of the GNU General Public License.
### 14. Revised Versions of this License.
The Free Software Foundation may publish revised and/or new versions
of the GNU Affero General Public License from time to time. Such new
versions will be similar in spirit to the present version, but may
differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the Program
specifies that a certain numbered version of the GNU Affero General
Public License "or any later version" applies to it, you have the
option of following the terms and conditions either of that numbered
version or of any later version published by the Free Software
Foundation. If the Program does not specify a version number of the
GNU Affero General Public License, you may choose any version ever
published by the Free Software Foundation.
If the Program specifies that a proxy can decide which future versions
of the GNU Affero General Public License can be used, that proxy's
public statement of acceptance of a version permanently authorizes you
to choose that version for the Program.
Later license versions may give you additional or different
permissions. However, no additional obligations are imposed on any
author or copyright holder as a result of your choosing to follow a
later version.
### 15. Disclaimer of Warranty.
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT
WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND
PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE
DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR
CORRECTION.
### 16. Limitation of Liability.
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR
CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES
ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT
NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR
LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM
TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER
PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
### 17. Interpretation of Sections 15 and 16.
If the disclaimer of warranty and limitation of liability provided
above cannot be given local legal effect according to their terms,
reviewing courts shall apply local law that most closely approximates
an absolute waiver of all civil liability in connection with the
Program, unless a warranty or assumption of liability accompanies a
copy of the Program in return for a fee.
END OF TERMS AND CONDITIONS
## How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these
terms.
To do so, attach the following notices to the program. It is safest to
attach them to the start of each source file to most effectively state
the exclusion of warranty; and each file should have at least the
"copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>.
Also add information on how to contact you by electronic and paper
mail.
If your software can interact with users remotely through a computer
network, you should also make sure that it provides a way for users to
get its source. For example, if your program is a web application, its
interface could display a "Source" link that leads users to an archive
of the code. There are many ways you could offer source, and different
solutions will be better for different programs; see section 13 for
the specific requirements.
You should also get your employer (if you work as a programmer) or
school, if any, to sign a "copyright disclaimer" for the program, if
necessary. For more information on this, and how to apply and follow
the GNU AGPL, see <https://www.gnu.org/licenses/>.
Attribution is requested in user-facing documentation and materials, where appropriate.

192
Makefile
View File

@ -22,97 +22,112 @@ config-yarn:
install-and-build: config-yarn
ifeq ($(OS),Windows_NT)
echo "skip"
else ifeq ($(shell uname -s),Linux)
chmod +x src-tauri/build-utils/*
endif
yarn install
yarn build:joi
yarn build:tauri:plugin:api
yarn build:core
yarn build:server
yarn build:extensions
yarn build:extensions && yarn build:extensions-web
check-file-counts: install-and-build
ifeq ($(OS),Windows_NT)
powershell -Command "if ((Get-ChildItem -Path pre-install -Filter *.tgz | Measure-Object | Select-Object -ExpandProperty Count) -ne (Get-ChildItem -Path extensions -Directory | Where-Object Name -like *-extension* | Measure-Object | Select-Object -ExpandProperty Count)) { Write-Host 'Number of .tgz files in pre-install does not match the number of subdirectories in extensions with package.json'; exit 1 } else { Write-Host 'Extension build successful' }"
# Install required Rust targets for macOS universal builds
install-rust-targets:
ifeq ($(shell uname -s),Darwin)
@echo "Detected macOS, installing universal build targets..."
rustup target add x86_64-apple-darwin
rustup target add aarch64-apple-darwin
@echo "Rust targets installed successfully!"
else
@tgz_count=$$(find pre-install -type f -name "*.tgz" | wc -l); dir_count=$$(find extensions -mindepth 1 -maxdepth 1 -type d -exec test -e '{}/package.json' \; -print | wc -l); if [ $$tgz_count -ne $$dir_count ]; then echo "Number of .tgz files in pre-install ($$tgz_count) does not match the number of subdirectories in extension ($$dir_count)"; exit 1; else echo "Extension build successful"; fi
@echo "Not macOS; skipping Rust target installation."
endif
dev: check-file-counts
# Install required Rust targets for Android builds
install-android-rust-targets:
@echo "Checking and installing Android Rust targets..."
@rustup target list --installed | grep -q "aarch64-linux-android" || rustup target add aarch64-linux-android
@rustup target list --installed | grep -q "armv7-linux-androideabi" || rustup target add armv7-linux-androideabi
@rustup target list --installed | grep -q "i686-linux-android" || rustup target add i686-linux-android
@rustup target list --installed | grep -q "x86_64-linux-android" || rustup target add x86_64-linux-android
@echo "Android Rust targets ready!"
# Install required Rust targets for iOS builds
install-ios-rust-targets:
@echo "Checking and installing iOS Rust targets..."
@rustup target list --installed | grep -q "aarch64-apple-ios" || rustup target add aarch64-apple-ios
@rustup target list --installed | grep -q "aarch64-apple-ios-sim" || rustup target add aarch64-apple-ios-sim
@rustup target list --installed | grep -q "x86_64-apple-ios" || rustup target add x86_64-apple-ios
@echo "iOS Rust targets ready!"
dev: install-and-build
yarn download:bin
yarn dev
# Linting
lint: check-file-counts
yarn lint
# Web application targets
install-web-app: config-yarn
yarn install
update-playwright-config:
ifeq ($(OS),Windows_NT)
echo -e "const RPconfig = {\n\
apiKey: '$(REPORT_PORTAL_API_KEY)',\n\
endpoint: '$(REPORT_PORTAL_URL)',\n\
project: '$(REPORT_PORTAL_PROJECT_NAME)',\n\
launch: '$(REPORT_PORTAL_LAUNCH_NAME)',\n\
attributes: [\n\
{\n\
key: 'key',\n\
value: 'value',\n\
},\n\
{\n\
value: 'value',\n\
},\n\
],\n\
description: '$(REPORT_PORTAL_DESCRIPTION)',\n\
}\n$$(cat electron/playwright.config.ts)" > electron/playwright.config.ts;
sed -i "s/^ reporter: .*/ reporter: [['@reportportal\/agent-js-playwright', RPconfig]],/" electron/playwright.config.ts
dev-web-app: install-web-app
yarn build:core
yarn dev:web-app
else ifeq ($(shell uname -s),Linux)
echo "const RPconfig = {\n\
apiKey: '$(REPORT_PORTAL_API_KEY)',\n\
endpoint: '$(REPORT_PORTAL_URL)',\n\
project: '$(REPORT_PORTAL_PROJECT_NAME)',\n\
launch: '$(REPORT_PORTAL_LAUNCH_NAME)',\n\
attributes: [\n\
{\n\
key: 'key',\n\
value: 'value',\n\
},\n\
{\n\
value: 'value',\n\
},\n\
],\n\
description: '$(REPORT_PORTAL_DESCRIPTION)',\n\
}\n$$(cat electron/playwright.config.ts)" > electron/playwright.config.ts;
sed -i "s/^ reporter: .*/ reporter: [['@reportportal\/agent-js-playwright', RPconfig]],/" electron/playwright.config.ts
build-web-app: install-web-app
yarn build:core
yarn build:web-app
serve-web-app:
yarn serve:web-app
build-serve-web-app: build-web-app
yarn serve:web-app
# Mobile
dev-android: install-and-build install-android-rust-targets
@echo "Setting up Android development environment..."
@if [ ! -d "src-tauri/gen/android" ]; then \
echo "Android app not initialized. Initializing..."; \
yarn tauri android init; \
fi
@echo "Sourcing Android environment setup..."
@bash autoqa/scripts/setup-android-env.sh echo "Android environment ready"
@echo "Starting Android development server..."
yarn dev:android
dev-ios: install-and-build install-ios-rust-targets
@echo "Setting up iOS development environment..."
ifeq ($(shell uname -s),Darwin)
@if [ ! -d "src-tauri/gen/ios" ]; then \
echo "iOS app not initialized. Initializing..."; \
yarn tauri ios init; \
fi
@echo "Checking iOS development requirements..."
@xcrun --version > /dev/null 2>&1 || (echo "❌ Xcode command line tools not found. Install with: xcode-select --install" && exit 1)
@xcrun simctl list devices available | grep -q "iPhone\|iPad" || (echo "❌ No iOS simulators found. Install simulators through Xcode." && exit 1)
@echo "Starting iOS development server..."
yarn dev:ios
else
echo "const RPconfig = {\n\
apiKey: '$(REPORT_PORTAL_API_KEY)',\n\
endpoint: '$(REPORT_PORTAL_URL)',\n\
project: '$(REPORT_PORTAL_PROJECT_NAME)',\n\
launch: '$(REPORT_PORTAL_LAUNCH_NAME)',\n\
attributes: [\n\
{\n\
key: 'key',\n\
value: 'value',\n\
},\n\
{\n\
value: 'value',\n\
},\n\
],\n\
description: '$(REPORT_PORTAL_DESCRIPTION)',\n\
}\n$$(cat electron/playwright.config.ts)" > electron/playwright.config.ts;
sed -i '' "s|^ reporter: .*| reporter: [['@reportportal\/agent-js-playwright', RPconfig]],|" electron/playwright.config.ts
@echo "❌ iOS development is only supported on macOS"
@exit 1
endif
# Linting
lint: install-and-build
yarn lint
# Testing
test: lint
yarn build:test
yarn test:coverage
yarn download:bin
ifeq ($(OS),Windows_NT)
endif
yarn test
# Builds and publishes the app
build-and-publish: check-file-counts
yarn build:publish
yarn copy:assets:tauri
yarn build:icon
cargo test --manifest-path src-tauri/Cargo.toml --no-default-features --features test-tauri -- --test-threads=1
cargo test --manifest-path src-tauri/plugins/tauri-plugin-hardware/Cargo.toml
cargo test --manifest-path src-tauri/plugins/tauri-plugin-llamacpp/Cargo.toml
cargo test --manifest-path src-tauri/utils/Cargo.toml
# Build
build: check-file-counts
build: install-and-build install-rust-targets
yarn build
clean:
@ -122,6 +137,8 @@ ifeq ($(OS),Windows_NT)
-powershell -Command "Remove-Item -Recurse -Force ./pre-install/*.tgz"
-powershell -Command "Remove-Item -Recurse -Force ./extensions/*/*.tgz"
-powershell -Command "Remove-Item -Recurse -Force ./electron/pre-install/*.tgz"
-powershell -Command "Remove-Item -Recurse -Force ./src-tauri/resources"
-powershell -Command "Remove-Item -Recurse -Force ./src-tauri/target"
-powershell -Command "if (Test-Path \"$($env:USERPROFILE)\jan\extensions\") { Remove-Item -Path \"$($env:USERPROFILE)\jan\extensions\" -Recurse -Force }"
else ifeq ($(shell uname -s),Linux)
find . -name "node_modules" -type d -prune -exec rm -rf '{}' +
@ -136,20 +153,25 @@ else ifeq ($(shell uname -s),Linux)
rm -rf ./pre-install/*.tgz
rm -rf ./extensions/*/*.tgz
rm -rf ./electron/pre-install/*.tgz
rm -rf ./src-tauri/resources
rm -rf ./src-tauri/target
rm -rf "~/jan/extensions"
rm -rf "~/.cache/jan*"
rm -rf "./.cache"
else
find . -name "node_modules" -type d -prune -exec rm -rf '{}' +
find . -name ".next" -type d -exec rm -rf '{}' +
find . -name "dist" -type d -exec rm -rf '{}' +
find . -name "build" -type d -exec rm -rf '{}' +
find . -name "out" -type d -exec rm -rf '{}' +
find . -name ".turbo" -type d -exec rm -rf '{}' +
find . -name ".yarn" -type d -exec rm -rf '{}' +
find . -name "package-lock.json" -type f -exec rm -rf '{}' +
rm -rf ./pre-install/*.tgz
rm -rf ./extensions/*/*.tgz
rm -rf ./electron/pre-install/*.tgz
rm -rf ~/jan/extensions
rm -rf ~/Library/Caches/jan*
find . -name "node_modules" -type d -prune -exec rm -rfv '{}' +
find . -name ".next" -type d -exec rm -rfv '{}' +
find . -name "dist" -type d -exec rm -rfv '{}' +
find . -name "build" -type d -exec rm -rfv '{}' +
find . -name "out" -type d -exec rm -rfv '{}' +
find . -name ".turbo" -type d -exec rm -rfv '{}' +
find . -name ".yarn" -type d -exec rm -rfv '{}' +
find . -name "package-lock.json" -type f -exec rm -rfv '{}' +
rm -rfv ./pre-install/*.tgz
rm -rfv ./extensions/*/*.tgz
rm -rfv ./electron/pre-install/*.tgz
rm -rfv ./src-tauri/resources
rm -rfv ./src-tauri/target
rm -rfv ~/jan/extensions
rm -rfv ~/Library/Caches/jan*
endif

307
README.md
View File

@ -1,6 +1,6 @@
# Jan - Local AI Assistant
# Jan - Open-source ChatGPT replacement
![Jan banner](./JanBanner.png)
<img width="2048" height="280" alt="github jan banner" src="https://github.com/user-attachments/assets/f3f87889-c133-433b-b250-236218150d3f" />
<p align="center">
<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->
@ -12,250 +12,135 @@
</p>
<p align="center">
<a href="https://jan.ai/docs/quickstart">Getting Started</a>
- <a href="https://jan.ai/docs">Docs</a>
- <a href="https://github.com/janhq/jan/releases">Changelog</a>
- <a href="https://github.com/janhq/jan/issues">Bug reports</a>
- <a href="https://discord.gg/AsJ8krTT3N">Discord</a>
<a href="https://www.jan.ai/docs/desktop">Getting Started</a>
- <a href="https://discord.gg/Exe46xPMbK">Community</a>
- <a href="https://jan.ai/changelog">Changelog</a>
- <a href="https://github.com/janhq/jan/issues">Bug reports</a>
</p>
<p align="center">
⚠️ <b> Jan is currently in Development</b>: Expect breaking changes and bugs!
</p>
Jan is bringing the best of open-source AI in an easy-to-use product. Download and run LLMs with **full control** and **privacy**.
## Installation
Jan is a ChatGPT-alternative that runs 100% offline on your device. Our goal is to make it easy for a layperson to download and run LLMs and use AI with **full control** and **privacy**.
Jan is powered by [Cortex](https://github.com/janhq/cortex.cpp), our embeddable local AI engine that runs on any hardware.
From PCs to multi-GPU clusters, Jan & Cortex supports universal architectures:
- [x] NVIDIA GPUs (fast)
- [x] Apple M-series (fast)
- [x] Apple Intel
- [x] Linux Debian
- [x] Windows x64
#### Features:
- [Model Library](https://jan.ai/docs/models/manage-models#add-models) with popular LLMs like Llama, Gemma, Mistral, or Qwen
- Connect to [Remote AI APIs](https://jan.ai/docs/remote-models/openai) like Groq and OpenRouter
- Local API Server with OpenAI-equivalent API
- [Extensions](https://jan.ai/docs/extensions) for customizing Jan
## Download
The easiest way to get started is by downloading one of the following versions for your respective operating system:
<table>
<tr style="text-align:center">
<td style="text-align:center"><b>Version Type</b></td>
<td style="text-align:center"><b>Windows</b></td>
<td style="text-align:center"><b>MacOS Universal</b></td>
<td colspan="2" style="text-align:center"><b>Linux</b></td>
<tr>
<td><b>Platform</b></td>
<td><b>Download</b></td>
</tr>
<tr style="text-align:center">
<td style="text-align:center"><b>Stable (Recommended)</b></td>
<td style="text-align:center">
<a href='https://app.jan.ai/download/latest/win-x64'>
<img src='https://github.com/janhq/jan/blob/dev/docs/static/img/windows.png' style="height:14px; width: 14px" />
<b>jan.exe</b>
</a>
</td>
<td style="text-align:center">
<a href='https://app.jan.ai/download/latest/mac-universal'>
<img src='https://github.com/janhq/jan/blob/dev/docs/static/img/mac.png' style="height:15px; width: 15px" />
<b>jan.dmg</b>
</a>
</td>
<td style="text-align:center">
<a href='https://app.jan.ai/download/latest/linux-amd64-deb'>
<img src='https://github.com/janhq/jan/blob/dev/docs/static/img/linux.png' style="height:14px; width: 14px" />
<b>jan.deb</b>
</a>
</td>
<td style="text-align:center">
<a href='https://app.jan.ai/download/latest/linux-amd64-appimage'>
<img src='https://github.com/janhq/jan/blob/dev/docs/static/img/linux.png' style="height:14px; width: 14px" />
<b>jan.AppImage</b>
</a>
</td>
<tr>
<td><b>Windows</b></td>
<td><a href='https://app.jan.ai/download/latest/win-x64'>jan.exe</a></td>
</tr>
<tr style="text-align:center">
<td style="text-align:center"><b>Beta (Preview)</b></td>
<td style="text-align:center">
<a href='https://app.jan.ai/download/beta/win-x64'>
<img src='https://github.com/janhq/jan/blob/dev/docs/static/img/windows.png' style="height:14px; width: 14px" />
<b>jan.exe</b>
</a>
</td>
<td style="text-align:center">
<a href='https://app.jan.ai/download/beta/mac-universal'>
<img src='https://github.com/janhq/jan/blob/dev/docs/static/img/mac.png' style="height:15px; width: 15px" />
<b>jan.dmg</b>
</a>
</td>
<td style="text-align:center">
<a href='https://app.jan.ai/download/beta/linux-amd64-deb'>
<img src='https://github.com/janhq/jan/blob/dev/docs/static/img/linux.png' style="height:14px; width: 14px" />
<b>jan.deb</b>
</a>
</td>
<td style="text-align:center">
<a href='https://app.jan.ai/download/beta/linux-amd64-appimage'>
<img src='https://github.com/janhq/jan/blob/dev/docs/static/img/linux.png' style="height:14px; width: 14px" />
<b>jan.AppImage</b>
</a>
</td>
<tr>
<td><b>macOS</b></td>
<td><a href='https://app.jan.ai/download/latest/mac-universal'>jan.dmg</a></td>
</tr>
<tr style="text-align:center">
<td style="text-align:center"><b>Nightly Build (Experimental)</b></td>
<td style="text-align:center">
<a href='https://app.jan.ai/download/nightly/win-x64'>
<img src='https://github.com/janhq/jan/blob/dev/docs/static/img/windows.png' style="height:14px; width: 14px" />
<b>jan.exe</b>
</a>
</td>
<td style="text-align:center">
<a href='https://app.jan.ai/download/nightly/mac-universal'>
<img src='https://github.com/janhq/jan/blob/dev/docs/static/img/mac.png' style="height:15px; width: 15px" />
<b>jan.dmg</b>
</a>
</td>
<td style="text-align:center">
<a href='https://app.jan.ai/download/nightly/linux-amd64-deb'>
<img src='https://github.com/janhq/jan/blob/dev/docs/static/img/linux.png' style="height:14px; width: 14px" />
<b>jan.deb</b>
</a>
</td>
<td style="text-align:center">
<a href='https://app.jan.ai/download/nightly/linux-amd64-appimage'>
<img src='https://github.com/janhq/jan/blob/dev/docs/static/img/linux.png' style="height:14px; width: 14px" />
<b>jan.AppImage</b>
</a>
</td>
<tr>
<td><b>Linux (deb)</b></td>
<td><a href='https://app.jan.ai/download/latest/linux-amd64-deb'>jan.deb</a></td>
</tr>
<tr>
<td><b>Linux (AppImage)</b></td>
<td><a href='https://app.jan.ai/download/latest/linux-amd64-appimage'>jan.AppImage</a></td>
</tr>
</table>
Download the latest version of Jan at https://jan.ai/ or visit the [GitHub Releases](https://github.com/janhq/jan/releases) to download any previous release.
## Demo
Download from [jan.ai](https://jan.ai/) or [GitHub Releases](https://github.com/janhq/jan/releases).
https://github.com/user-attachments/assets/c3592fa2-c504-4d9d-a885-7e00122a50f3
## Features
*Real-time Video: Jan v0.5.7 on a Mac M2, 16GB Sonoma 14.2*
- **Local AI Models**: Download and run LLMs (Llama, Gemma, Qwen, GPT-oss etc.) from HuggingFace
- **Cloud Integration**: Connect to GPT models via OpenAI, Claude models via Anthropic, Mistral, Groq, and others
- **Custom Assistants**: Create specialized AI assistants for your tasks
- **OpenAI-Compatible API**: Local server at `localhost:1337` for other applications
- **Model Context Protocol**: MCP integration for agentic capabilities
- **Privacy First**: Everything runs locally when you want it to
## Quicklinks
## Build from Source
### Jan
For those who enjoy the scenic route:
- [Jan Website](https://jan.ai/)
- [Jan GitHub](https://github.com/janhq/jan)
- [Documentation](https://jan.ai/docs)
- [Jan Changelog](https://jan.ai/changelog)
- [Jan Blog](https://jan.ai/blog)
### Prerequisites
### Cortex.cpp
Jan is powered by **Cortex.cpp**. It is a C++ command-line interface (CLI) designed as an alternative to [Ollama](https://ollama.com/). By default, it runs on the llama.cpp engine but also supports other engines, including ONNX and TensorRT-LLM, making it a multi-engine platform.
- Node.js ≥ 20.0.0
- Yarn ≥ 1.22.0
- Make ≥ 3.81
- Rust (for Tauri)
### Run with Make
- [Cortex Website](https://cortex.so/)
- [Cortex GitHub](https://github.com/janhq/cortex.cpp)
- [Documentation](https://cortex.so/docs/)
- [Models Library](https://cortex.so/models)
- API Reference: *Under development*
## Requirements for running Jan
```bash
git clone https://github.com/janhq/jan
cd jan
make dev
```
- **MacOS**: 13 or higher
- **Windows**:
- Windows 10 or higher
- To enable GPU support:
- Nvidia GPU with CUDA Toolkit 11.7 or higher
- Nvidia driver 470.63.01 or higher
- **Linux**:
- glibc 2.27 or higher (check with `ldd --version`)
- gcc 11, g++ 11, cpp 11 or higher, refer to this [link](https://jan.ai/guides/troubleshooting/gpu-not-used/#specific-requirements-for-linux) for more information
- To enable GPU support:
- Nvidia GPU with CUDA Toolkit 11.7 or higher
- Nvidia driver 470.63.01 or higher
This handles everything: installs dependencies, builds core components, and launches the app.
**Available make targets:**
- `make dev` - Full development setup and launch
- `make build` - Production build
- `make test` - Run tests and linting
- `make clean` - Delete everything and start fresh
### Manual Commands
```bash
yarn install
yarn build:tauri:plugin:api
yarn build:core
yarn build:extensions
yarn dev
```
## System Requirements
**Minimum specs for a decent experience:**
- **macOS**: 13.6+ (8GB RAM for 3B models, 16GB for 7B, 32GB for 13B)
- **Windows**: 10+ with GPU support for NVIDIA/AMD/Intel Arc
- **Linux**: Most distributions work, GPU acceleration available
For detailed compatibility, check our [installation guides](https://jan.ai/docs/desktop/mac).
## Troubleshooting
As Jan is in development mode, you might get stuck on a some common issues:
- [Troubleshooting a broken build](https://jan.ai/docs/troubleshooting#broken-build)
- [Troubleshooting NVIDIA GPU](https://jan.ai/docs/troubleshooting#troubleshooting-nvidia-gpu)
- [Troubleshooting Something's Amiss](https://jan.ai/docs/troubleshooting#somethings-amiss)
If things go sideways:
1. Check our [troubleshooting docs](https://jan.ai/docs/troubleshooting)
2. Copy your error logs and system specs
3. Ask for help in our [Discord](https://discord.gg/FTk2MvZwJH) `#🆘|jan-help` channel
If you can't find what you need in our troubleshooting guide, feel free reach out to us for extra help:
1. Copy your [error logs & device specifications](https://jan.ai/docs/troubleshooting#how-to-get-error-logs).
2. Go to our [Discord](https://discord.com/invite/FTk2MvZwJH) & send it to **#🆘|get-help** channel for further support.
*Check the logs to ensure the information is what you intend to send. Note that we retain your logs for only 24 hours, so report any issues promptly.*
## Contributing
Contributions are welcome! Please read the [CONTRIBUTING.md](CONTRIBUTING.md) file
Contributions welcome. See [CONTRIBUTING.md](CONTRIBUTING.md) for the full spiel.
### Pre-requisites
## Links
- node >= 20.0.0
- yarn >= 1.22.0
- make >= 3.81
### Instructions
1. **Clone the repository and prepare:**
```bash
git clone https://github.com/janhq/jan
cd jan
git checkout -b DESIRED_BRANCH
```
2. **Run development and use Jan Desktop**
```bash
make dev
```
This will start the development server and open the desktop app.
### For production build
```bash
# Do steps 1 and 2 in the previous section
# Build the app
make build
```
This will build the app MacOS m1/m2 for production (with code signing already done) and put the result in `dist` folder.
## Acknowledgements
Jan builds on top of other open-source projects:
- [llama.cpp](https://github.com/ggerganov/llama.cpp)
- [LangChain](https://github.com/langchain-ai)
- [TensorRT](https://github.com/NVIDIA/TensorRT)
- [TensorRT-LLM](https://github.com/NVIDIA/TensorRT-LLM)
- [Documentation](https://jan.ai/docs) - The manual you should read
- [API Reference](https://jan.ai/api-reference) - For the technically inclined
- [Changelog](https://jan.ai/changelog) - What we broke and fixed
- [Discord](https://discord.gg/FTk2MvZwJH) - Where the community lives
## Contact
- Bugs & requests: file a GitHub ticket
- For discussion: join our Discord [here](https://discord.gg/FTk2MvZwJH)
- For business inquiries: email hello@jan.ai
- For jobs: please email hr@jan.ai
## Trust & Safety
Beware of scams!
- We will never request your personal information.
- Our product is completely free; no paid version exists.
- We do not have a token or ICO.
- We are a [bootstrapped company](https://en.wikipedia.org/wiki/Bootstrapping), and don't have any external investors (*yet*). We're open to exploring opportunities with strategic partners want to tackle [our mission](https://jan.ai/about#mission) together.
- **Bugs**: [GitHub Issues](https://github.com/janhq/jan/issues)
- **Business**: hello@jan.ai
- **Jobs**: hr@jan.ai
- **General Discussion**: [Discord](https://discord.gg/FTk2MvZwJH)
## License
Jan is free and open source, under the **AGPLv3** license.
Apache 2.0 - Because sharing is caring.
## Acknowledgements
Built on the shoulders of giants:
- [Llama.cpp](https://github.com/ggerganov/llama.cpp)
- [Tauri](https://tauri.app/)
- [Scalar](https://github.com/scalar/scalar)

View File

@ -1,9 +0,0 @@
[Desktop Entry]
Name=Jan
Comment=Local AI Assistant that runs 100% offline
Exec=run.sh
Icon=ai.menlo.jan
Type=Application
Categories=Development;
Keywords=AI;Assistant;LLM;ChatGPT;Local;Offline;
StartupNotify=true

View File

@ -1,42 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<component type="desktop-application">
<id>ai.menlo.jan</id>
<metadata_license>FSFAP</metadata_license>
<project_license>AGPL-3.0-only</project_license>
<name>Jan</name>
<summary>Local AI Assistant that runs 100% offline on your device</summary>
<description>
<p>
Jan is a ChatGPT-alternative that runs 100% offline on your device. Our goal is to make it easy for anyone to download and run LLMs and use AI with full control and privacy.
</p>
<p>Features:</p>
<ul>
<li>Model Library with popular LLMs like Llama, Gemma, Mistral, or Qwen</li>
<li>Connect to Remote AI APIs like Groq and OpenRouter</li>
<li>Local API Server with OpenAI-equivalent API</li>
<li>Extensions for customizing Jan</li>
</ul>
</description>
<launchable type="desktop-id">ai.menlo.jan.desktop</launchable>
<screenshots>
<screenshot type="default">
<image>https://catalog.jan.ai/flatpak/demo.gif</image>
</screenshot>
</screenshots>
<url type="homepage">https://jan.ai/</url>
<url type="bugtracker">https://github.com/janhq/jan/issues</url>
<content_rating type="oars-1.1" />
<releases>
<release version="0.5.12" date="2024-01-02">
<description>
<p>Latest stable release of Jan AI</p>
</description>
</release>
</releases>
</component>

319
autoqa/README.md Normal file
View File

@ -0,0 +1,319 @@
# E2E Test Runner with ReportPortal Integration
🚀 An automated end-to-end test runner for Jan application with ReportPortal integration, screen recording, and comprehensive test monitoring.
## Features
- ✅ **Automated Jan App Testing**: Automatically starts/stops Jan application
- 🖥️ **Auto Computer Server**: Automatically starts computer server in background
- 📹 **Screen Recording**: Records test execution for debugging
- 📊 **ReportPortal Integration**: Optional test results upload to ReportPortal
- 🔄 **Turn Monitoring**: Prevents infinite loops with configurable turn limits
- 🎯 **Flexible Configuration**: Command-line arguments and environment variables
- 🌐 **Cross-platform**: Windows, macOS, and Linux support
- 📁 **Test Discovery**: Automatically scans test files from directory
## Prerequisites
- Python 3.8+
- Jan application installed
- Windows Sandbox (for computer provider)
- Computer server package installed
- Required Python packages (see requirements.txt)
## Installation
1. Clone the repository:
```bash
git clone <repository-url>
cd autoqa
```
2. Install dependencies:
```bash
## For Windows and Linux
pip install -r requirements.txt
```
3. Ensure Jan application is installed in one of the default locations:
- Windows: `%LOCALAPPDATA%\Programs\jan\Jan.exe`
- macOS: `~/Applications/Jan.app/Contents/MacOS/Jan`
- Linux: `jan` (in PATH)
## Quick Start
### Local Development (No ReportPortal)
```bash
# Run all tests in ./tests directory (auto-starts computer server)
python main.py
# Run with custom test directory
python main.py --tests-dir "my_tests"
# Run with custom Jan app path
python main.py --jan-app-path "C:/Custom/Path/Jan.exe"
# Skip auto computer server start (if already running)
python main.py --skip-server-start
```
### With ReportPortal Integration
```bash
# Enable ReportPortal with token
python main.py --enable-reportportal --rp-token "YOUR_API_TOKEN"
# Full ReportPortal configuration
python main.py \
--enable-reportportal \
--rp-endpoint "https://reportportal.example.com" \
--rp-project "my_project" \
--rp-token "YOUR_API_TOKEN"
```
## Configuration
### Command Line Arguments
| Argument | Environment Variable | Default | Description |
| ----------------------- | --------------------- | ------------------------------- | ------------------------------------------------- |
| **Computer Server** |
| `--skip-server-start` | `SKIP_SERVER_START` | `false` | Skip automatic computer server startup |
| **ReportPortal** |
| `--enable-reportportal` | `ENABLE_REPORTPORTAL` | `false` | Enable ReportPortal integration |
| `--rp-endpoint` | `RP_ENDPOINT` | `https://reportportal.menlo.ai` | ReportPortal endpoint URL |
| `--rp-project` | `RP_PROJECT` | `default_personal` | ReportPortal project name |
| `--rp-token` | `RP_TOKEN` | - | ReportPortal API token (required when RP enabled) |
| **Jan Application** |
| `--jan-app-path` | `JAN_APP_PATH` | _auto-detected_ | Path to Jan application executable |
| `--jan-process-name` | `JAN_PROCESS_NAME` | `Jan.exe` | Jan process name for monitoring |
| **Model Configuration** |
| `--model-name` | `MODEL_NAME` | `ByteDance-Seed/UI-TARS-1.5-7B` | AI model name |
| `--model-base-url` | `MODEL_BASE_URL` | `http://10.200.108.58:1234/v1` | Model API endpoint |
| `--model-provider` | `MODEL_PROVIDER` | `oaicompat` | Model provider type |
| `--model-loop` | `MODEL_LOOP` | `uitars` | Agent loop type |
| **Test Execution** |
| `--max-turns` | `MAX_TURNS` | `30` | Maximum turns per test |
| `--tests-dir` | `TESTS_DIR` | `tests` | Directory containing test files |
| `--delay-between-tests` | `DELAY_BETWEEN_TESTS` | `3` | Delay between tests (seconds) |
### Environment Variables
Create a `.env` file or set environment variables:
```bash
# Computer Server
SKIP_SERVER_START=false
# ReportPortal Configuration
ENABLE_REPORTPORTAL=true
RP_ENDPOINT=https://reportportal.example.com
RP_PROJECT=my_project
RP_TOKEN=your_secret_token
# Jan Application
JAN_APP_PATH=C:\Custom\Path\Jan.exe
JAN_PROCESS_NAME=Jan.exe
# Model Configuration
MODEL_NAME=gpt-4
MODEL_BASE_URL=https://api.openai.com/v1
MODEL_PROVIDER=openai
MODEL_LOOP=uitars
# Test Settings
MAX_TURNS=50
TESTS_DIR=e2e_tests
DELAY_BETWEEN_TESTS=5
```
## Test Structure
### Test Files
- Test files should be `.txt` files containing test prompts
- Place test files in the `tests/` directory (or custom directory)
- Support nested directories for organization
Example test file (`tests/basic/login_test.txt`):
```
Test the login functionality of Jan application.
Navigate to login screen, enter valid credentials, and verify successful login.
```
### Directory Structure
```
autoqa/
├── main.py # Main test runner
├── utils.py # Jan app utilities
├── test_runner.py # Test execution logic
├── screen_recorder.py # Screen recording functionality
├── reportportal_handler.py # ReportPortal integration
├── tests/ # Test files directory
│ ├── basic/
│ │ ├── login_test.txt
│ │ └── navigation_test.txt
│ └── advanced/
│ └── complex_workflow.txt
├── recordings/ # Screen recordings (auto-created)
├── trajectories/ # Agent trajectories (auto-created)
└── README.md
```
## Usage Examples
### Basic Usage
```bash
# Run all tests locally (auto-starts computer server)
python main.py
# Get help
python main.py --help
# Run without auto-starting computer server
python main.py --skip-server-start
```
### Advanced Usage
```bash
# Custom configuration
python main.py \
--tests-dir "integration_tests" \
--max-turns 40 \
--delay-between-tests 10 \
--model-name "gpt-4"
# Environment + Arguments
ENABLE_REPORTPORTAL=true RP_TOKEN=secret python main.py --max-turns 50
# Different model provider
python main.py \
--model-provider "openai" \
--model-name "gpt-4" \
--model-base-url "https://api.openai.com/v1"
# External computer server (skip auto-start)
SKIP_SERVER_START=true python main.py
```
### CI/CD Usage
```bash
# GitHub Actions / CI environment
ENABLE_REPORTPORTAL=true \
RP_TOKEN=${{ secrets.RP_TOKEN }} \
MODEL_NAME=production-model \
MAX_TURNS=40 \
SKIP_SERVER_START=false \
python main.py
```
## Computer Server Management
The test runner automatically manages the computer server:
### Automatic Server Management (Default)
- **Auto-start**: Computer server starts automatically in background thread
- **Auto-cleanup**: Server stops when main program exits (daemon thread)
- **Error handling**: Graceful fallback if server fails to start
### Manual Server Management
```bash
# If you prefer to manage computer server manually:
python -m computer_server # In separate terminal
# Then run tests without auto-start:
python main.py --skip-server-start
```
### Server Logs
```
2025-07-15 15:30:45 - INFO - Starting computer server in background...
2025-07-15 15:30:45 - INFO - Calling computer_server.run_cli()...
2025-07-15 15:30:45 - INFO - Computer server thread started
2025-07-15 15:30:50 - INFO - Computer server is running successfully
```
## Output
### Local Development
- **Console logs**: Detailed execution information
- **Screen recordings**: Saved to `recordings/` directory as MP4 files
- **Trajectories**: Agent interaction data in `trajectories/` directory
- **Local results**: Test results logged to console
### ReportPortal Integration
When enabled, results are uploaded to ReportPortal including:
- Test execution status (PASSED/FAILED)
- Screen recordings as attachments
- Detailed turn-by-turn interaction logs
- Error messages and debugging information
## Troubleshooting
### Common Issues
1. **Computer server startup failed**:
```bash
# Install required dependencies
pip install computer_server
# Check if computer_server is available
python -c "import computer_server; print('OK')"
# Use manual server if auto-start fails
python main.py --skip-server-start
```
2. **Jan app not found**:
```bash
# Specify custom path
python main.py --jan-app-path "D:/Apps/Jan/Jan.exe"
```
3. **Windows dependencies missing**:
```bash
# Install Windows-specific packages
pip install pywin32 psutil
```
4. **ReportPortal connection failed**:
- Verify endpoint URL and token
- Check network connectivity
- Ensure project exists
5. **Screen recording issues**:
- Check disk space in `recordings/` directory
- Verify screen recording permissions
6. **Test timeouts**:
```bash
# Increase turn limit
python main.py --max-turns 50
```
### Debug Mode
Enable detailed logging by modifying the logging level in `main.py`:
```python
logging.basicConfig(level=logging.DEBUG)
```

264
autoqa/checklist.md Normal file
View File

@ -0,0 +1,264 @@
# I. Before release
## A. Initial update / migration Data check
Before testing, set-up the following in the old version to make sure that we can see the data is properly migrated:
- [ ] Changing appearance / theme to something that is obviously different from default set-up
- [ ] Ensure there are a few chat threads
- [ ] Ensure there are a few favourites / star threads
- [ ] Ensure there are 2 model downloaded
- [ ] Ensure there are 2 import on local provider (llama.cpp)
- [ ] Modify MCP servers list and add some ENV value to MCP servers
- [ ] Modify Local API Server
- [ ] HTTPS proxy config value
- [ ] Add 2 custom assistants to Jan
- [ ] Create a new chat with the custom assistant
- [ ] Change the `App Data` to some other folder
- [ ] Create a Custom Provider
- [ ] Disabled some model providers
- [NEW] Change llama.cpp setting of 2 models
#### Validate that the update does not corrupt existing user data or settings (before and after update show the same information):
- [ ] Threads
- [ ] Previously used model and assistants is shown correctly
- [ ] Can resume chat in threads with the previous context
- [ ] Assistants
- Settings:
- [ ] Appearance
- [ ] MCP Servers
- [ ] Local API Server
- [ ] HTTPS Proxy
- [ ] Custom Provider Set-up
#### In `Hub`:
- [ ] Can see model from HF listed properly
- [ ] Downloaded model will show `Use` instead of `Download`
- [ ] Toggling on `Downloaded` on the right corner show the correct list of downloaded models
#### In `Settings -> General`:
- [ ] Ensure the `App Data` path is the same
- [ ] Click Open Logs, App Log will show
#### In `Settings -> Model Providers`:
- [ ] Llama.cpp still listed downloaded models and user can chat with the models
- [ ] Llama.cpp still listed imported models and user can chat with the models
- [ ] Remote model still retain previously set up API keys and user can chat with model from the provider without having to re-enter API keys
- [ ] Enabled and Disabled Model Providers stay the same as before update
#### In `Settings -> Extensions`, check that following exists:
- [ ] Conversational
- [ ] Jan Assistant
- [ ] Download Manager
- [ ] llama.cpp Inference Engine
## B. `Settings`
#### In `General`:
- [ ] Ensure `Community` links work and point to the correct website
- [ ] Ensure the `Check for Updates` function detect the correct latest version
- [ ] [ENG] Create a folder with un-standard character as title (e.g. Chinese character) => change the `App data` location to that folder => test that model is still able to load and run properly.
#### In `Appearance`:
- [ ] Toggle between different `Theme` options to check that they change accordingly and that all elements of the UI are legible with the right contrast:
- [ ] Light
- [ ] Dark
- [ ] System (should follow your OS system settings)
- [ ] Change the following values => close the application => re-open the application => ensure that the change is persisted across session:
- [ ] Theme
- [ ] Font Size
- [ ] Window Background
- [ ] App Main View
- [ ] Primary
- [ ] Accent
- [ ] Destructive
- [ ] Chat Width
- [ ] Ensure that when this value is changed, there is no broken UI caused by it
- [ ] Code Block
- [ ] Show Line Numbers
- [ENG] Ensure that when click on `Reset` in the `Appearance` section, it reset back to the default values
- [ENG] Ensure that when click on `Reset` in the `Code Block` section, it reset back to the default values
#### In `Model Providers`:
In `Llama.cpp`:
- [ ] After downloading a model from hub, the model is listed with the correct name under `Models`
- [ ] Can import `gguf` model with no error
- [ ] Imported model will be listed with correct name under the `Models`
- [ ] Check that when click `delete` the model will be removed from the list
- [ ] Deleted model doesn't appear in the selectable models section in chat input (even in old threads that use the model previously)
- [ ] Ensure that user can re-import deleted imported models
- [ ] Enable `Auto-Unload Old Models`, and ensure that only one model can run / start at a time. If there are two model running at the time of enable, both of them will be stopped.
- [ ] Disable `Auto-Unload Old Models`, and ensure that multiple models can run at the same time.
- [ ] Enable `Context Shift` and ensure that context can run for long without encountering memory error. Use the `banana test` by turn on fetch MCP => ask local model to fetch and summarize the history of banana (banana has a very long history on wiki it turns out). It should run out of context memory sufficiently fast if `Context Shift` is not enabled.
- [ ] Ensure that user can change the Jinja chat template of individual model and it doesn't affect the template of other model
- [ ] Ensure that there is a recommended `llama.cpp` for each system and that it works out of the box for users.
- [ ] [0.6.9] Take a `gguf` file and delete the `.gguf` extensions from the file name, import it into Jan and verify that it works.
In Remote Model Providers:
- [ ] Check that the following providers are presence:
- [ ] OpenAI
- [ ] Anthropic
- [ ] Cohere
- [ ] OpenRouter
- [ ] Mistral
- [ ] Groq
- [ ] Gemini
- [ ] Hugging Face
- [ ] Models should appear as available on the selectable dropdown in chat input once some value is input in the API key field. (it could be the wrong API key)
- [ ] Once a valid API key is used, user can select a model from that provider and chat without any error.
- [ ] Delete a model and ensure that it doesn't show up in the `Modesl` list view or in the selectable dropdown in chat input.
- [ ] Ensure that a deleted model also not selectable or appear in old threads that used it.
- [ ] Adding of new model manually works and user can chat with the newly added model without error (you can add back the model you just delete for testing)
- [ ] [0.6.9] Make sure that Ollama set-up as a custom provider work with Jan
In Custom Providers:
- [ ] Ensure that user can create a new custom providers with the right baseURL and API key.
- [ ] Click `Refresh` should retrieve a list of available models from the Custom Providers.
- [ ] User can chat with the custom providers
- [ ] Ensure that Custom Providers can be deleted and won't reappear in a new session
In general:
- [ ] Disabled Model Provider should not show up as selectable in chat input of new thread and old thread alike (old threads' chat input should show `Select Model` instead of disabled model)
#### In `Shortcuts`:
Make sure the following shortcut key combo is visible and works:
- [ ] New chat
- [ ] Toggle Sidebar
- [ ] Zoom In
- [ ] Zoom Out
- [ ] Send Message
- [ ] New Line
- [ ] Navigation
#### In `Hardware`:
Ensure that the following section information show up for hardware
- [ ] Operating System
- [ ] CPU
- [ ] Memory
- [ ] GPU (If the machine has one)
- [ ] Enabling and Disabling GPUs and ensure that model still run correctly in both mode
- [ ] Enabling or Disabling GPU should not affect the UI of the application
#### In `MCP Servers`:
- [ ] Ensure that an user can create a MCP server successfully when enter in the correct information
- [ ] Ensure that `Env` value is masked by `*` in the quick view.
- [ ] If an `Env` value is missing, there should be a error pop up.
- [ ] Ensure that deleted MCP server disappear from the `MCP Server` list without any error
- [ ] Ensure that before a MCP is deleted, it will be disable itself first and won't appear on the tool list after deleted.
- [ ] Ensure that when the content of a MCP server is edited, it will be updated and reflected accordingly in the UI and when running it.
- [ ] Toggling enable and disabled of a MCP server work properly
- [ ] A disabled MCP should not appear in the available tool list in chat input
- [ ] An disabled MCP should not be callable even when forced prompt by the model (ensure there is no ghost MCP server)
- [ ] Ensure that enabled MCP server start automatically upon starting of the application
- [ ] An enabled MCP should show functions in the available tool list
- [ ] User can use a model and call different tool from multiple enabled MCP servers in the same thread
- [ ] If `Allow All MCP Tool Permissions` is disabled, in every new thread, before a tool is called, there should be a confirmation dialog pop up to confirm the action.
- [ ] When the user click `Deny`, the tool call will not be executed and return a message indicate so in the tool call result.
- [ ] When the user click `Allow Once` on the pop up, a confirmation dialog will appear again when the tool is called next time.
- [ ] When the user click `Always Allow` on the pop up, the tool will retain permission and won't ask for confirmation again. (this applied at an individual tool level, not at the MCP server level)
- [ ] If `Allow All MCP Tool Permissions` is enabled, in every new thread, there should not be any confirmation dialog pop up when a tool is called.
- [ ] When the pop-up appear, make sure that the `Tool Parameters` is also shown with detail in the pop-up.a
- [ ] [0.6.9] Go to Enter JSON configuration when created a new MCp => paste the JSON config inside => click `Save` => server works
- [ ] [0.6.9] If individual JSON config format is failed, the MCP server should not be activated
- [ ] [0.6.9] Make sure that MCP server can be used with streamable-http transport => connect to Smithery and test MCP server
#### In `Local API Server`:
- [ ] User can `Start Server` and chat with the default endpoint
- [ ] User should see the correct model name at `v1/models`
- [ ] User should be able to chat with it at `v1/chat/completions`
- [ ] `Open Logs` show the correct query log send to the server and return from the server
- [ ] Make sure that changing all the parameter in `Server Configuration` is reflected when `Start Server`
- [ ] [0.6.9] When the startup configuration, the last used model is also automatically start (users does not have to manually start a model before starting the server)
- [ ] [0.6.9] Make sure that you can send an image to a Local API Server and it also works (can set up Local API Server as a Custom Provider in Jan to test)
#### In `HTTPS Proxy`:
- [ ] Model download request goes through proxy endpoint
## C. Hub
- [ ] User can click `Download` to download a model
- [ ] User can cancel a model in the middle of downloading
- [ ] User can add a Hugging Face model detail to the list by pasting a model name / model url into the search bar and press enter
- [ ] Clicking on a listing will open up the model card information within Jan and render the HTML properly
- [ ] Clicking download work on the `Show variants` section
- [ ] Clicking download work inside the Model card HTML
- [ ] [0.6.9] Check that the model recommendation base on user hardware work as expected in the Model Hub
## D. Threads
#### In the left bar:
- [ ] User can delete an old thread, and it won't reappear even when app restart
- [ ] Change the title of the thread should update its last modification date and re-organise its position in the correct chronological order on the left bar.
- [ ] The title of a new thread is the first message from the user.
- [ ] Users can starred / un-starred threads accordingly
- [ ] Starred threads should move to `Favourite` section and other threads should stay in `Recent`
- [ ] Ensure that the search thread feature return accurate result based on thread titles and contents (including from both `Favourite` and `Recent`)
- [ ] `Delete All` should delete only threads in the `Recents` section
- [ ] `Unstar All` should un-star all of the `Favourites` threads and return them to `Recent`
#### In a thread:
- [ ] When `New Chat` is clicked, the assistant is set as the last selected assistant, the model selected is set as the last used model, and the user can immediately chat with the model.
- [ ] User can conduct multi-turn conversation in a single thread without lost of data (given that `Context Shift` is not enabled)
- [ ] User can change to a different model in the middle of a conversation in a thread and the model work.
- [ ] User can click on `Regenerate` button on a returned message from the model to get a new response base on the previous context.
- [ ] User can change `Assistant` in the middle of a conversation in a thread and the new assistant setting will be applied instead.
- [ ] The chat windows can render and show all the content of a selected threads (including scroll up and down on long threads)
- [ ] Old thread retained their setting as of the last update / usage
- [ ] Assistant option
- [ ] Model option (except if the model / model provider has been deleted or disabled)
- [ ] User can send message with different type of text content (e.g text, emoji, ...)
- [ ] When request model to generate a markdown table, the table is correctly formatted as returned from the model.
- [ ] When model generate code, ensure that the code snippets is properly formatted according to the `Appearance -> Code Block` setting.
- [ ] Users can edit their old message and and user can regenerate the answer based on the new message
- [ ] User can click `Copy` to copy the model response
- [ ] User can click `Delete` to delete either the user message or the model response.
- [ ] The token speed appear when a response from model is being generated and the final value is show under the response.
- [ ] Make sure that user when using IME keyboard to type Chinese and Japanese character and they press `Enter`, the `Send` button doesn't trigger automatically after each words.
- [ ] [0.6.9] Attach an image to the chat input and see if you can chat with it using a remote model
- [ ] [0.6.9] Attach an image to the chat input and see if you can chat with it using a local model
- [ ] [0.6.9] Check that you can paste an image to text box from your system clipboard (Copy - Paste)
- [ ] [0.6.9] Make sure that user can favourite a model in the model selection in chat input
## E. Assistants
- [ ] There is always at least one default Assistant which is Jan
- [ ] The default Jan assistant has `stream = True` by default
- [ ] User can create / edit a new assistant with different parameters and instructions choice.
- [ ] When user delete the default Assistant, the next Assistant in line will be come the default Assistant and apply their setting to new chat accordingly.
- [ ] User can create / edit assistant from within a Chat windows (on the top left)
## F. After checking everything else
In `Settings -> General`:
- [ ] Change the location of the `App Data` to some other path that is not the default path
- [ ] Click on `Reset` button in `Other` to factory reset the app:
- [ ] All threads deleted
- [ ] All Assistant deleted except for default Jan Assistant
- [ ] `App Data` location is reset back to default path
- [ ] Appearance reset
- [ ] Model Providers information all reset
- [ ] Llama.cpp setting reset
- [ ] API keys cleared
- [ ] All Custom Providers deleted
- [ ] MCP Servers reset
- [ ] Local API Server reset
- [ ] HTTPS Proxy reset
- [ ] After closing the app, all models are unloaded properly
- [ ] Locate to the data folder using the `App Data` path information => delete the folder => reopen the app to check that all the folder is re-created with all the necessary data.
- [ ] Ensure that the uninstallation process removes the app successfully from the system.
## G. New App Installation
- [ ] Clean up by deleting all the left over folder created by Jan
- [ ] On MacOS
- [ ] `~/Library/Application Support/Jan`
- [ ] `~/Library/Caches/jan.ai.app`
- [ ] On Windows
- [ ] `C:\Users<Username>\AppData\Roaming\Jan\`
- [ ] `C:\Users<Username>\AppData\Local\jan.ai.app`
- [ ] On Linux
- [ ] `~/.cache/Jan`
- [ ] `~/.cache/jan.ai.app`
- [ ] `~/.local/share/Jan`
- [ ] `~/.local/share/jan.ai.app`
- [ ] Ensure that the fresh install of Jan launch
- [ ] Do some basic check to see that all function still behaved as expected. To be extra careful, you can go through the whole list again. However, it is more advisable to just check to make sure that all the core functionality like `Thread` and `Model Providers` work as intended.
# II. After release
- [ ] Check that the App Updater works and user can update to the latest release without any problem
- [ ] App restarts after the user finished an update
- [ ] Repeat section `A. Initial update / migration Data check` above to verify that update is done correctly on live version

514
autoqa/main.py Normal file
View File

@ -0,0 +1,514 @@
import asyncio
import logging
import os
import argparse
import threading
import time
import platform
from datetime import datetime
from computer import Computer
from reportportal_client import RPClient
from reportportal_client.helpers import timestamp
from utils import scan_test_files
from test_runner import run_single_test_with_timeout
# Configure logging
logging.basicConfig(
level=logging.INFO,
format='%(asctime)s - %(levelname)s - %(message)s',
handlers=[
logging.StreamHandler()
]
)
logger = logging.getLogger(__name__)
# Platform detection
IS_WINDOWS = platform.system() == "Windows"
IS_LINUX = platform.system() == "Linux"
IS_MACOS = platform.system() == "Darwin"
def get_computer_config():
"""Get computer configuration based on platform"""
if IS_WINDOWS:
return {
"os_type": "windows"
}
elif IS_LINUX:
return {
"os_type": "linux"
}
elif IS_MACOS:
return {
"os_type": "macos"
}
else:
# Default fallback
logger.warning(f"Unknown platform {platform.system()}, using Linux config as fallback")
return {
"os_type": "linux"
}
def get_default_jan_path():
"""Get default Jan app path based on OS"""
if IS_WINDOWS:
# Try multiple common locations on Windows
possible_paths = [
os.path.expanduser(r"~\AppData\Local\Programs\jan\Jan.exe"),
os.path.join(os.environ.get('LOCALAPPDATA', ''), 'Programs', 'jan', 'Jan.exe'),
os.path.join(os.environ.get('APPDATA', ''), 'jan', 'Jan.exe'),
r"C:\Program Files\jan\Jan.exe",
r"C:\Program Files (x86)\jan\Jan.exe"
]
# Return first existing path, or first option as default
for path in possible_paths:
if os.path.exists(path):
return path
# If none exist, return the most likely default
return possible_paths[0]
elif IS_LINUX:
# Linux possible locations
possible_paths = [
"/usr/bin/Jan",
"/usr/local/bin/Jan",
os.path.expanduser("~/Applications/Jan/Jan"),
"/opt/Jan/Jan"
]
# Return first existing path, or first option as default
for path in possible_paths:
if os.path.exists(path):
return path
# Default to nightly build path
return "/usr/bin/Jan"
elif IS_MACOS:
# macOS defaults
possible_paths = [
"/Applications/Jan.app/Contents/MacOS/Jan",
os.path.expanduser("~/Applications/Jan.app/Contents/MacOS/Jan")
]
for path in possible_paths:
if os.path.exists(path):
return path
return possible_paths[0]
else:
# Unknown platform
return "jan"
def start_computer_server():
"""Start computer server in background thread"""
try:
logger.info("Starting computer server in background...")
# Import computer_server module
import computer_server
import sys
# Start server in a separate thread
def run_server():
try:
# Save original sys.argv to avoid argument conflicts
original_argv = sys.argv.copy()
# Override sys.argv for computer_server to use default args
sys.argv = ['computer_server'] # Reset to minimal args
# Use the proper entry point
logger.info("Calling computer_server.run_cli()...")
computer_server.run_cli()
logger.info("Computer server.run_cli() completed")
except KeyboardInterrupt:
logger.info("Computer server interrupted")
except Exception as e:
logger.error(f"Computer server error: {e}")
import traceback
logger.error(f"Traceback: {traceback.format_exc()}")
finally:
# Restore original sys.argv
try:
sys.argv = original_argv
except:
pass
server_thread = threading.Thread(target=run_server, daemon=True)
server_thread.start()
logger.info("Computer server thread started")
# Give server more time to start up
time.sleep(5)
# Check if thread is still alive (server is running)
if server_thread.is_alive():
logger.info("Computer server is running successfully")
return server_thread
else:
logger.error("Computer server thread died unexpectedly")
return None
except ImportError as e:
logger.error(f"Cannot import computer_server module: {e}")
logger.error("Please install computer_server package")
return None
except Exception as e:
logger.error(f"Error starting computer server: {e}")
import traceback
logger.error(f"Traceback: {traceback.format_exc()}")
return None
def parse_arguments():
"""Parse command line arguments"""
parser = argparse.ArgumentParser(
description="E2E Test Runner with ReportPortal integration",
formatter_class=argparse.RawDescriptionHelpFormatter,
epilog="""
Examples:
# Run locally without ReportPortal
python main.py
# Run with ReportPortal integration
python main.py --enable-reportportal --rp-token YOUR_TOKEN
# Run with custom Jan app path
python main.py --jan-app-path "C:/Custom/Path/Jan.exe"
# Run with different model
python main.py --model-name "gpt-4" --model-base-url "https://api.openai.com/v1"
# Using environment variables
ENABLE_REPORTPORTAL=true RP_TOKEN=xxx MODEL_NAME=gpt-4 python main.py
"""
)
# Get default Jan path
default_jan_path = get_default_jan_path()
# Computer server arguments
server_group = parser.add_argument_group('Computer Server Configuration')
server_group.add_argument(
'--skip-server-start',
action='store_true',
default=os.getenv('SKIP_SERVER_START', 'false').lower() == 'true',
help='Skip automatic computer server startup (env: SKIP_SERVER_START, default: false)'
)
# ReportPortal arguments
rp_group = parser.add_argument_group('ReportPortal Configuration')
rp_group.add_argument(
'--enable-reportportal',
action='store_true',
default=os.getenv('ENABLE_REPORTPORTAL', 'false').lower() == 'true',
help='Enable ReportPortal integration (env: ENABLE_REPORTPORTAL, default: false)'
)
rp_group.add_argument(
'--rp-endpoint',
default=os.getenv('RP_ENDPOINT', 'https://reportportal.menlo.ai'),
help='ReportPortal endpoint URL (env: RP_ENDPOINT, default: %(default)s)'
)
rp_group.add_argument(
'--rp-project',
default=os.getenv('RP_PROJECT', 'default_personal'),
help='ReportPortal project name (env: RP_PROJECT, default: %(default)s)'
)
rp_group.add_argument(
'--rp-token',
default=os.getenv('RP_TOKEN'),
help='ReportPortal API token (env: RP_TOKEN, required when --enable-reportportal is used)'
)
rp_group.add_argument(
'--launch-name',
default=os.getenv('LAUNCH_NAME'),
help='Custom launch name for ReportPortal (env: LAUNCH_NAME, default: auto-generated with timestamp)'
)
# Jan app arguments
jan_group = parser.add_argument_group('Jan Application Configuration')
jan_group.add_argument(
'--jan-app-path',
default=os.getenv('JAN_APP_PATH', default_jan_path),
help=f'Path to Jan application executable (env: JAN_APP_PATH, default: auto-detected or {default_jan_path})'
)
jan_group.add_argument(
'--jan-process-name',
default=os.getenv('JAN_PROCESS_NAME', 'Jan.exe' if IS_WINDOWS else ('Jan' if IS_MACOS else 'Jan-nightly')),
help='Jan process name for monitoring (env: JAN_PROCESS_NAME, default: platform-specific)'
)
# Model/Agent arguments
model_group = parser.add_argument_group('Model Configuration')
model_group.add_argument(
'--model-loop',
default=os.getenv('MODEL_LOOP', 'uitars'),
help='Agent loop type (env: MODEL_LOOP, default: %(default)s)'
)
model_group.add_argument(
'--model-provider',
default=os.getenv('MODEL_PROVIDER', 'oaicompat'),
help='Model provider (env: MODEL_PROVIDER, default: %(default)s)'
)
model_group.add_argument(
'--model-name',
default=os.getenv('MODEL_NAME', 'ByteDance-Seed/UI-TARS-1.5-7B'),
help='Model name (env: MODEL_NAME, default: %(default)s)'
)
model_group.add_argument(
'--model-base-url',
default=os.getenv('MODEL_BASE_URL', 'http://10.200.108.58:1234/v1'),
help='Model base URL (env: MODEL_BASE_URL, default: %(default)s)'
)
# Test execution arguments
test_group = parser.add_argument_group('Test Execution Configuration')
test_group.add_argument(
'--max-turns',
type=int,
default=int(os.getenv('MAX_TURNS', '30')),
help='Maximum number of turns per test (env: MAX_TURNS, default: %(default)s)'
)
test_group.add_argument(
'--tests-dir',
default=os.getenv('TESTS_DIR', 'tests'),
help='Directory containing test files (env: TESTS_DIR, default: %(default)s)'
)
test_group.add_argument(
'--delay-between-tests',
type=int,
default=int(os.getenv('DELAY_BETWEEN_TESTS', '3')),
help='Delay in seconds between tests (env: DELAY_BETWEEN_TESTS, default: %(default)s)'
)
args = parser.parse_args()
# Validate ReportPortal token if ReportPortal is enabled
if args.enable_reportportal and not args.rp_token:
parser.error("--rp-token (or RP_TOKEN env var) is required when --enable-reportportal is used")
return args
async def main():
"""
Main function to scan and run all test files with optional ReportPortal integration
"""
# Parse command line arguments
args = parse_arguments()
# Initialize final exit code
final_exit_code = 0
# Start computer server if not skipped
server_thread = None
if not args.skip_server_start:
server_thread = start_computer_server()
if server_thread is None:
logger.error("Failed to start computer server. Exiting...")
return
else:
logger.info("Skipping computer server startup (assuming it's already running)")
try:
# Build agent config from arguments
agent_config = {
"loop": args.model_loop,
"model_provider": args.model_provider,
"model_name": args.model_name,
"model_base_url": args.model_base_url
}
# Log configuration
logger.info("=== Configuration ===")
logger.info(f"Computer server: {'STARTED' if server_thread else 'EXTERNAL'}")
logger.info(f"Tests directory: {args.tests_dir}")
logger.info(f"Max turns per test: {args.max_turns}")
logger.info(f"Delay between tests: {args.delay_between_tests}s")
logger.info(f"Jan app path: {args.jan_app_path}")
logger.info(f"Jan app exists: {os.path.exists(args.jan_app_path)}")
logger.info(f"Jan process name: {args.jan_process_name}")
logger.info(f"Model: {args.model_name}")
logger.info(f"Model URL: {args.model_base_url}")
logger.info(f"Model provider: {args.model_provider}")
logger.info(f"ReportPortal integration: {'ENABLED' if args.enable_reportportal else 'DISABLED'}")
if args.enable_reportportal:
logger.info(f"ReportPortal endpoint: {args.rp_endpoint}")
logger.info(f"ReportPortal project: {args.rp_project}")
logger.info(f"ReportPortal token: {'SET' if args.rp_token else 'NOT SET'}")
logger.info(f"Launch name: {args.launch_name if args.launch_name else 'AUTO-GENERATED'}")
logger.info("======================")
# Scan all test files
test_files = scan_test_files(args.tests_dir)
if not test_files:
logger.warning(f"No test files found in directory: {args.tests_dir}")
return
logger.info(f"Found {len(test_files)} test files")
# Track test results for final exit code
test_results = {"passed": 0, "failed": 0, "total": len(test_files)}
# Initialize ReportPortal client only if enabled
rp_client = None
launch_id = None
if args.enable_reportportal:
try:
rp_client = RPClient(
endpoint=args.rp_endpoint,
project=args.rp_project,
api_key=args.rp_token
)
# Start ReportPortal launch
current_time = datetime.now().strftime("%Y%m%d_%H%M%S")
# Use custom launch name if provided, otherwise generate default
if args.launch_name:
launch_name = args.launch_name
logger.info(f"Using custom launch name: {launch_name}")
else:
launch_name = f"E2E Test Run - {current_time}"
logger.info(f"Using auto-generated launch name: {launch_name}")
launch_id = rp_client.start_launch(
name=launch_name,
start_time=timestamp(),
description=f"Automated E2E test run with {len(test_files)} test cases\n"
f"Model: {args.model_name}\n"
f"Max turns: {args.max_turns}"
)
logger.info(f"Started ReportPortal launch: {launch_name}")
except Exception as e:
logger.error(f"Failed to initialize ReportPortal: {e}")
logger.warning("Continuing without ReportPortal integration...")
rp_client = None
launch_id = None
else:
logger.info("Running in local development mode - results will not be uploaded to ReportPortal")
# Start computer environment
logger.info("Initializing computer environment...")
# Get platform-specific computer configuration
computer_config = get_computer_config()
logger.info(f"Using computer config: {computer_config}")
computer = Computer(
os_type=computer_config["os_type"],
use_host_computer_server=True
)
await computer.run()
logger.info("Computer environment ready")
# Run each test sequentially with turn monitoring
for i, test_data in enumerate(test_files, 1):
logger.info(f"Running test {i}/{len(test_files)}: {test_data['path']}")
try:
# Pass all configs to test runner
test_result = await run_single_test_with_timeout(
computer=computer,
test_data=test_data,
rp_client=rp_client, # Can be None
launch_id=launch_id, # Can be None
max_turns=args.max_turns,
jan_app_path=args.jan_app_path,
jan_process_name=args.jan_process_name,
agent_config=agent_config,
enable_reportportal=args.enable_reportportal
)
# Track test result - properly handle different return formats
test_passed = False
if test_result:
# Check different possible return formats
if isinstance(test_result, dict):
# Dictionary format: check 'success' key
test_passed = test_result.get('success', False)
elif isinstance(test_result, bool):
# Boolean format: direct boolean value
test_passed = test_result
elif hasattr(test_result, 'success'):
# Object format: check success attribute
test_passed = getattr(test_result, 'success', False)
else:
# Any truthy value is considered success
test_passed = bool(test_result)
else:
test_passed = False
# Update counters and log result
if test_passed:
test_results["passed"] += 1
logger.info(f"[SUCCESS] Test {i} PASSED: {test_data['path']}")
else:
test_results["failed"] += 1
logger.error(f"[FAILED] Test {i} FAILED: {test_data['path']}")
# Debug log for troubleshooting
logger.info(f"[INFO] Debug - Test result: type={type(test_result)}, value={test_result}, success_field={test_result.get('success', 'N/A') if isinstance(test_result, dict) else 'N/A'}, final_passed={test_passed}")
except Exception as e:
test_results["failed"] += 1
logger.error(f"[FAILED] Test {i} FAILED with exception: {test_data['path']} - {e}")
# Add delay between tests
if i < len(test_files):
logger.info(f"Waiting {args.delay_between_tests} seconds before next test...")
await asyncio.sleep(args.delay_between_tests)
# Log final test results summary
logger.info("=" * 50)
logger.info("TEST EXECUTION SUMMARY")
logger.info("=" * 50)
logger.info(f"Total tests: {test_results['total']}")
logger.info(f"Passed: {test_results['passed']}")
logger.info(f"Failed: {test_results['failed']}")
logger.info(f"Success rate: {(test_results['passed']/test_results['total']*100):.1f}%")
logger.info("=" * 50)
if test_results["failed"] > 0:
logger.error(f"[FAILED] Test execution completed with {test_results['failed']} failures!")
final_exit_code = 1
else:
logger.info("[SUCCESS] All tests completed successfully!")
final_exit_code = 0
except KeyboardInterrupt:
logger.info("Test execution interrupted by user")
final_exit_code = 1
except Exception as e:
logger.error(f"Error in main execution: {e}")
final_exit_code = 1
finally:
# Finish ReportPortal launch only if it was started
if args.enable_reportportal and rp_client and launch_id:
try:
rp_client.finish_launch(
launch_id=launch_id,
end_time=timestamp()
)
rp_client.session.close()
logger.info("ReportPortal launch finished and session closed")
except Exception as e:
logger.error(f"Error finishing ReportPortal launch: {e}")
# Note: daemon thread will automatically terminate when main program ends
if server_thread:
logger.info("Computer server will stop when main program exits (daemon thread)")
# Exit with appropriate code based on test results
logger.info(f"Exiting with code: {final_exit_code}")
exit(final_exit_code)
if __name__ == "__main__":
asyncio.run(main())

View File

@ -0,0 +1,439 @@
import os
import json
import mimetypes
import re
import logging
import glob
import platform
from reportportal_client.helpers import timestamp
logger = logging.getLogger(__name__)
def upload_turn_folder(client, test_item_id, turn_path, turn_name, force_fail=False):
"""
Upload turn folder content to ReportPortal
"""
step_item_id = client.start_test_item(
parent_item_id=test_item_id,
name=turn_name,
start_time=timestamp(),
item_type="STEP"
)
uploaded = False
step_has_errors = False # Track if this step has any errors
for fname in sorted(os.listdir(turn_path)):
fpath = os.path.join(turn_path, fname)
if fname.endswith(".json"):
try:
with open(fpath, "r", encoding="utf-8") as f:
data = json.load(f)
client.log(
time=timestamp(),
level="INFO",
message=f"[{fname}]\n{json.dumps(data, indent=2)}",
item_id=step_item_id
)
uploaded = True
except Exception as e:
client.log(
time=timestamp(),
level="ERROR",
message=f"[ERROR parsing {fname}] {str(e)}",
item_id=step_item_id
)
step_has_errors = True
elif fname.endswith(".png"):
try:
with open(fpath, "rb") as img_file:
client.log(
time=timestamp(),
level="INFO",
message=f"Screenshot: {fname}",
item_id=step_item_id,
attachment={
"name": fname,
"data": img_file.read(),
"mime": mimetypes.guess_type(fname)[0] or "image/png"
}
)
uploaded = True
except Exception as e:
client.log(
time=timestamp(),
level="ERROR",
message=f"[ERROR attaching {fname}] {str(e)}",
item_id=step_item_id
)
step_has_errors = True
if not uploaded:
client.log(
time=timestamp(),
level="WARNING",
message="No data found in this turn.",
item_id=step_item_id
)
# Determine step status based on test case result
if force_fail:
step_status = "FAILED"
else:
step_status = "FAILED" if step_has_errors else "PASSED"
client.finish_test_item(
item_id=step_item_id,
end_time=timestamp(),
status=step_status
)
def extract_test_result_from_trajectory(trajectory_dir):
"""
Extract test result from the last turn's API response
Returns True only if found {"result": True}, False for all other cases including {"result": False}
"""
if not trajectory_dir or not os.path.exists(trajectory_dir):
logger.warning(f"Trajectory directory not found: {trajectory_dir}")
return False
try:
# Get all turn folders and find the last one
turn_folders = [f for f in os.listdir(trajectory_dir)
if os.path.isdir(os.path.join(trajectory_dir, f)) and f.startswith("turn_")]
if not turn_folders:
logger.warning("No turn folders found")
return False
# Sort to get the last turn
last_turn = sorted(turn_folders)[-1]
last_turn_path = os.path.join(trajectory_dir, last_turn)
logger.info(f"Checking result in last turn: {last_turn}")
# Look for API call response files
response_files = [f for f in os.listdir(last_turn_path)
if f.startswith("api_call_") and f.endswith("_response.json")]
if not response_files:
logger.warning("No API response files found in last turn")
return False
# Check the last response file
last_response_file = sorted(response_files)[-1]
response_file_path = os.path.join(last_turn_path, last_response_file)
logger.info(f"Checking response file: {last_response_file}")
with open(response_file_path, 'r', encoding='utf-8') as f:
data = json.load(f)
# Extract content from response
if 'response' in data and 'choices' in data['response'] and data['response']['choices']:
last_choice = data['response']['choices'][-1]
if 'message' in last_choice and 'content' in last_choice['message']:
content = last_choice['message']['content']
logger.info(f"Last response content: {content}")
# Look for result patterns - need to check both True and False
true_pattern = r'\{\s*"result"\s*:\s*True\s*\}'
false_pattern = r'\{\s*"result"\s*:\s*False\s*\}'
true_match = re.search(true_pattern, content)
false_match = re.search(false_pattern, content)
if true_match:
logger.info(f"Found test result: True - PASSED")
return True
elif false_match:
logger.info(f"Found test result: False - FAILED")
return False
else:
logger.warning("No valid result pattern found in response content - marking as FAILED")
return False
logger.warning("Could not extract content from response structure")
return False
except Exception as e:
logger.error(f"Error extracting test result: {e}")
return False
def get_jan_log_paths(is_nightly=False):
"""
Get Jan application log file paths based on OS and version (nightly vs regular)
Returns list of glob patterns for log files
"""
system = platform.system().lower()
app_name = "Jan-nightly" if is_nightly else "Jan"
if system == "windows":
# Windows: %APPDATA%\Jan(-nightly)\data\logs\*.log
appdata = os.path.expandvars("%APPDATA%")
return [f"{appdata}\\{app_name}\\data\\logs\\*.log"]
elif system == "darwin": # macOS
# macOS: ~/Library/Application Support/Jan(-nightly)/data/logs/*.log
home_dir = os.path.expanduser("~")
return [f"{home_dir}/Library/Application Support/{app_name}/data/logs/*.log"]
elif system == "linux":
# Linux: ~/.local/share/Jan(-nightly)/data/logs/*.log
home_dir = os.path.expanduser("~")
return [f"{home_dir}/.local/share/{app_name}/data/logs/*.log"]
else:
logger.warning(f"Unsupported OS: {system}")
return []
def upload_jan_logs(client, test_item_id, is_nightly=False, max_log_files=5):
"""
Upload Jan application log files to ReportPortal
"""
log_patterns = get_jan_log_paths(is_nightly)
app_type = "nightly" if is_nightly else "regular"
logger.info(f"Looking for Jan {app_type} logs...")
all_log_files = []
for pattern in log_patterns:
try:
log_files = glob.glob(pattern)
all_log_files.extend(log_files)
logger.info(f"Found {len(log_files)} log files matching pattern: {pattern}")
except Exception as e:
logger.error(f"Error searching for logs with pattern {pattern}: {e}")
if not all_log_files:
logger.warning(f"No Jan {app_type} log files found")
client.log(
time=timestamp(),
level="WARNING",
message=f"[INFO] No Jan {app_type} application logs found",
item_id=test_item_id
)
return
# Sort by modification time (newest first) and limit to max_log_files
try:
all_log_files.sort(key=lambda x: os.path.getmtime(x), reverse=True)
log_files_to_upload = all_log_files[:max_log_files]
logger.info(f"Uploading {len(log_files_to_upload)} most recent Jan {app_type} log files")
for i, log_file in enumerate(log_files_to_upload, 1):
try:
file_size = os.path.getsize(log_file)
file_name = os.path.basename(log_file)
# Check file size limit (50MB = 50 * 1024 * 1024 bytes)
max_file_size = 50 * 1024 * 1024 # 50MB
if file_size > max_file_size:
logger.warning(f"Log file {file_name} is too large ({file_size} bytes > {max_file_size} bytes), skipping upload")
client.log(
time=timestamp(),
level="WARNING",
message=f"[INFO] Log file {file_name} skipped (size: {file_size} bytes > 50MB limit)",
item_id=test_item_id
)
continue
logger.info(f"Uploading log file {i}/{len(log_files_to_upload)}: {file_name} ({file_size} bytes)")
# Read log file content (safe to read since we checked size)
with open(log_file, 'r', encoding='utf-8', errors='ignore') as f:
log_content = f.read()
# Upload as text attachment
client.log(
time=timestamp(),
level="INFO",
message=f"[INFO] Jan {app_type} application log: {file_name}",
item_id=test_item_id,
attachment={
"name": f"jan_{app_type}_log_{i}_{file_name}",
"data": log_content.encode('utf-8'),
"mime": "text/plain"
}
)
logger.info(f"Successfully uploaded log: {file_name}")
except Exception as e:
logger.error(f"Error uploading log file {log_file}: {e}")
client.log(
time=timestamp(),
level="ERROR",
message=f"Failed to upload log file {os.path.basename(log_file)}: {str(e)}",
item_id=test_item_id
)
# Add summary log
client.log(
time=timestamp(),
level="INFO",
message=f"[INFO] Uploaded {len(log_files_to_upload)} Jan {app_type} log files (total available: {len(all_log_files)})",
item_id=test_item_id
)
except Exception as e:
logger.error(f"Error processing Jan logs: {e}")
client.log(
time=timestamp(),
level="ERROR",
message=f"Error processing Jan {app_type} logs: {str(e)}",
item_id=test_item_id
)
def upload_test_results_to_rp(client, launch_id, test_path, trajectory_dir, force_stopped=False, video_path=None, is_nightly=False):
"""
Upload test results to ReportPortal with proper status based on test result
"""
if not trajectory_dir or not os.path.exists(trajectory_dir):
logger.warning(f"Trajectory directory not found: {trajectory_dir}")
formatted_test_path = test_path.replace('\\', '/').replace('.txt', '').replace('/', '__')
test_item_id = client.start_test_item(
launch_id=launch_id,
name=formatted_test_path,
start_time=timestamp(),
item_type="TEST",
description=f"Test case from: {test_path}"
)
client.log(
time=timestamp(),
level="ERROR",
message="[FAILED] TEST FAILED [FAILED]\nNo trajectory directory found",
item_id=test_item_id
)
# Upload video if available
if video_path and os.path.exists(video_path):
try:
with open(video_path, "rb") as video_file:
client.log(
time=timestamp(),
level="INFO",
message="Screen recording of test execution",
item_id=test_item_id,
attachment={
"name": f"test_recording_{formatted_test_path}.mp4",
"data": video_file.read(),
"mime": "video/x-msvideo"
}
)
logger.info(f"Uploaded video for failed test: {video_path}")
except Exception as e:
logger.error(f"Error uploading video: {e}")
client.finish_test_item(
item_id=test_item_id,
end_time=timestamp(),
status="FAILED"
)
return
formatted_test_path = test_path.replace('\\', '/').replace('.txt', '').replace('/', '__')
# Determine final status
if force_stopped:
final_status = "FAILED"
status_message = "exceeded maximum turn limit (30 turns)"
else:
test_result = extract_test_result_from_trajectory(trajectory_dir)
if test_result is True:
final_status = "PASSED"
status_message = "completed successfully with positive result"
else:
final_status = "FAILED"
status_message = "no valid success result found"
# Create test item
test_item_id = client.start_test_item(
launch_id=launch_id,
name=formatted_test_path,
start_time=timestamp(),
item_type="TEST",
description=f"Test case from: {test_path}"
)
try:
turn_folders = [f for f in os.listdir(trajectory_dir)
if os.path.isdir(os.path.join(trajectory_dir, f)) and f.startswith("turn_")]
# Add clear status log
status_emoji = "[SUCCESS]" if final_status == "PASSED" else "[FAILED]"
client.log(
time=timestamp(),
level="INFO" if final_status == "PASSED" else "ERROR",
message=f"{status_emoji} TEST {final_status} {status_emoji}\nReason: {status_message}\nTotal turns: {len(turn_folders)}",
item_id=test_item_id
)
# Upload screen recording video first
if video_path and os.path.exists(video_path):
logger.info(f"Attempting to upload video: {video_path}")
logger.info(f"Video file size: {os.path.getsize(video_path)} bytes")
try:
with open(video_path, "rb") as video_file:
video_data = video_file.read()
logger.info(f"Read video data: {len(video_data)} bytes")
client.log(
time=timestamp(),
level="INFO",
message="[INFO] Screen recording of test execution",
item_id=test_item_id,
attachment={
"name": f"test_recording_{formatted_test_path}.mp4",
"data": video_data,
"mime": "video/x-msvideo"
}
)
logger.info(f"Successfully uploaded screen recording: {video_path}")
except Exception as e:
logger.error(f"Error uploading screen recording: {e}")
client.log(
time=timestamp(),
level="WARNING",
message=f"Failed to upload screen recording: {str(e)}",
item_id=test_item_id
)
else:
logger.warning(f"Video upload skipped - video_path: {video_path}, exists: {os.path.exists(video_path) if video_path else 'N/A'}")
client.log(
time=timestamp(),
level="WARNING",
message="No screen recording available for this test",
item_id=test_item_id
)
# Upload Jan application logs
logger.info("Uploading Jan application logs...")
upload_jan_logs(client, test_item_id, is_nightly=is_nightly, max_log_files=5)
# Upload all turn data with appropriate status
# If test failed, mark all turns as failed
force_fail_turns = (final_status == "FAILED")
for turn_folder in sorted(turn_folders):
turn_path = os.path.join(trajectory_dir, turn_folder)
upload_turn_folder(client, test_item_id, turn_path, turn_folder, force_fail=force_fail_turns)
# Finish with correct status
client.finish_test_item(
item_id=test_item_id,
end_time=timestamp(),
status=final_status
)
logger.info(f"Uploaded test results for {formatted_test_path}: {final_status}")
except Exception as e:
logger.error(f"Error uploading test results: {e}")
client.finish_test_item(
item_id=test_item_id,
end_time=timestamp(),
status="FAILED"
)

18
autoqa/requirements.txt Normal file
View File

@ -0,0 +1,18 @@
# Core dependencies
cua-computer[all]~=0.3.5
cua-agent[all]~=0.3.0
cua-agent @ git+https://github.com/janhq/cua.git@compute-agent-0.3.0-patch#subdirectory=libs/python/agent
# ReportPortal integration
reportportal-client~=5.6.5
# Screen recording and automation
opencv-python~=4.10.0
numpy~=2.2.6
PyAutoGUI~=0.9.54
# System utilities
psutil~=7.0.0
# Server component
cua-computer-server~=0.1.19

84
autoqa/screen_recorder.py Normal file
View File

@ -0,0 +1,84 @@
import cv2
import numpy as np
import pyautogui
import threading
import time
import logging
logger = logging.getLogger(__name__)
class ScreenRecorder:
def __init__(self, output_path, fps=10):
self.output_path = output_path
self.fps = fps
self.recording = False
self.writer = None
self.thread = None
def start_recording(self):
"""Start screen recording"""
if self.recording:
logger.warning("Recording already in progress")
return
self.recording = True
self.thread = threading.Thread(target=self._record_screen, daemon=True)
self.thread.start()
logger.info(f"Started screen recording: {self.output_path}")
def stop_recording(self):
"""Stop screen recording"""
if not self.recording:
logger.warning("No recording in progress")
return
self.recording = False
if self.thread:
self.thread.join(timeout=5)
if self.writer:
self.writer.release()
logger.info(f"Stopped screen recording: {self.output_path}")
def _record_screen(self):
"""Internal method to record screen"""
try:
# Get screen dimensions
screen_size = pyautogui.size()
# Try MP4 with H264 codec for better compatibility
fourcc = cv2.VideoWriter_fourcc(*'mp4v') # or 'H264'
output_path_mp4 = self.output_path
self.writer = cv2.VideoWriter(
output_path_mp4,
fourcc,
self.fps,
screen_size
)
while self.recording:
try:
# Capture screen
screenshot = pyautogui.screenshot()
# Convert PIL image to numpy array
frame = np.array(screenshot)
# Convert RGB to BGR (OpenCV uses BGR)
frame = cv2.cvtColor(frame, cv2.COLOR_RGB2BGR)
# Write frame
self.writer.write(frame)
# Control FPS
time.sleep(1.0 / self.fps)
except Exception as e:
logger.error(f"Error capturing frame: {e}")
break
except Exception as e:
logger.error(f"Error in screen recording: {e}")
finally:
if self.writer:
self.writer.release()

116
autoqa/scripts/README.md Normal file
View File

@ -0,0 +1,116 @@
# AutoQA Scripts
This directory contains platform-specific scripts used by the AutoQA GitHub Actions workflow. These scripts help maintain a cleaner and more maintainable workflow file by extracting complex inline scripts into separate files.
## Directory Structure
```text
autoqa/scripts/
├── setup_permissions.sh # Setup executable permissions for all scripts
├── windows_cleanup.ps1 # Windows: Clean existing Jan installations
├── windows_download.ps1 # Windows: Download Jan app installer
├── windows_install.ps1 # Windows: Install Jan app
├── windows_post_cleanup.ps1 # Windows: Post-test cleanup
├── run_tests.ps1 # Windows: Run AutoQA tests
├── ubuntu_cleanup.sh # Ubuntu: Clean existing Jan installations
├── ubuntu_download.sh # Ubuntu: Download Jan app (.deb)
├── ubuntu_install.sh # Ubuntu: Install Jan app
├── ubuntu_post_cleanup.sh # Ubuntu: Post-test cleanup
├── macos_cleanup.sh # macOS: Clean existing Jan installations
├── macos_download.sh # macOS: Download Jan app (.dmg)
├── macos_install.sh # macOS: Install Jan app
├── macos_post_cleanup.sh # macOS: Post-test cleanup
├── run_tests.sh # Unix: Run AutoQA tests (Ubuntu/macOS)
├── README.md # This file
└── PERMISSIONS.md # Permission setup documentation
```
## Script Functions
### Windows Scripts (.ps1)
- **windows_cleanup.ps1**: Removes existing Jan installations and kills running processes
- **windows_download.ps1**: Downloads Jan installer with priority-based URL selection
- **windows_install.ps1**: Installs Jan app and sets environment variables
- **windows_post_cleanup.ps1**: Comprehensive cleanup after tests including uninstallation
- **run_tests.ps1**: Runs the AutoQA Python tests with proper arguments
### Ubuntu Scripts (.sh)
- **ubuntu_cleanup.sh**: Removes existing Jan installations and kills running processes
- **ubuntu_download.sh**: Downloads Jan .deb package with priority-based URL selection
- **ubuntu_install.sh**: Installs Jan .deb package and sets environment variables
- **ubuntu_post_cleanup.sh**: Comprehensive cleanup after tests including package removal
### macOS Scripts (.sh)
- **macos_cleanup.sh**: Removes existing Jan installations and kills running processes
- **macos_download.sh**: Downloads Jan .dmg package with priority-based URL selection
- **macos_install.sh**: Mounts DMG, extracts .app, and installs to Applications
- **macos_post_cleanup.sh**: Comprehensive cleanup after tests
### Common Scripts
- **setup_permissions.sh**: Automatically sets executable permissions for all shell scripts
- **run_tests.sh**: Platform-agnostic test runner for Unix-based systems (Ubuntu/macOS)
## Usage in GitHub Actions
These scripts are called from the `.github/workflows/autoqa.yml` workflow file:
```yaml
# Setup permissions first (Ubuntu/macOS)
- name: Setup script permissions
run: |
chmod +x autoqa/scripts/setup_permissions.sh
./autoqa/scripts/setup_permissions.sh
# Then use scripts without chmod
- name: Clean existing Jan installations
run: |
./autoqa/scripts/ubuntu_cleanup.sh
# Windows example (no chmod needed)
- name: Clean existing Jan installations
shell: powershell
run: |
.\autoqa\scripts\windows_cleanup.ps1
```
## Benefits
1. **Maintainability**: Complex scripts are in separate files, easier to read and modify
2. **Reusability**: Scripts can be reused across different workflows or locally
3. **Testing**: Scripts can be tested independently
4. **Version Control**: Better diff tracking for script changes
5. **Platform Consistency**: Similar functionality across platforms in separate files
## Development
When modifying these scripts:
1. Test them locally on the respective platforms
2. Ensure proper error handling and exit codes
3. Follow platform-specific best practices
4. Update this README if new scripts are added
## Script Parameters
### Windows Scripts
- Most scripts accept `-IsNightly` parameter to handle nightly vs stable builds
- Download script accepts multiple URL sources with priority ordering
### Unix Scripts
- Most scripts accept positional parameters for nightly flag and URLs
- Scripts use `$1`, `$2`, etc. for parameter access
## Environment Variables
Scripts set these environment variables for subsequent workflow steps:
- `JAN_APP_URL`: The selected Jan app download URL
- `IS_NIGHTLY`: Boolean flag indicating if it's a nightly build
- `JAN_APP_PATH`: Path to the installed Jan executable
- `JAN_PROCESS_NAME`: Name of the Jan process for monitoring

View File

@ -0,0 +1,34 @@
#!/bin/bash
# macOS cleanup script for Jan app
echo "Cleaning existing Jan installations..."
# Kill any running Jan processes (both regular and nightly)
pkill -f "Jan" || true
pkill -f "jan" || true
pkill -f "Jan-nightly" || true
pkill -f "jan-nightly" || true
# Remove Jan app directories
rm -rf /Applications/Jan.app
rm -rf /Applications/Jan-nightly.app
rm -rf ~/Applications/Jan.app
rm -rf ~/Applications/Jan-nightly.app
# Remove Jan data folders (both regular and nightly)
rm -rf ~/Library/Application\ Support/Jan
rm -rf ~/Library/Application\ Support/Jan-nightly
rm -rf ~/Library/Application\ Support/jan.ai.app
rm -rf ~/Library/Application\ Support/jan-nightly.ai.app
rm -rf ~/Library/Preferences/jan.*
rm -rf ~/Library/Preferences/jan-nightly.*
rm -rf ~/Library/Caches/jan.*
rm -rf ~/Library/Caches/jan-nightly.*
rm -rf ~/Library/Caches/jan.ai.app
rm -rf ~/Library/Caches/jan-nightly.ai.app
rm -rf ~/Library/WebKit/jan.ai.app
rm -rf ~/Library/WebKit/jan-nightly.ai.app
rm -rf ~/Library/Saved\ Application\ State/jan.ai.app
rm -rf ~/Library/Saved\ Application\ State/jan-nightly.ai.app
echo "Jan cleanup completed"

View File

@ -0,0 +1,49 @@
#!/bin/bash
# macOS download script for Jan app
WORKFLOW_INPUT_URL="$1"
WORKFLOW_INPUT_IS_NIGHTLY="$2"
REPO_VARIABLE_URL="$3"
REPO_VARIABLE_IS_NIGHTLY="$4"
DEFAULT_URL="$5"
DEFAULT_IS_NIGHTLY="$6"
# Determine Jan app URL and nightly flag from multiple sources (priority order):
# 1. Workflow dispatch input (manual trigger)
# 2. Repository variable JAN_APP_URL
# 3. Default URL from env
JAN_APP_URL=""
IS_NIGHTLY="false"
if [ -n "$WORKFLOW_INPUT_URL" ]; then
JAN_APP_URL="$WORKFLOW_INPUT_URL"
IS_NIGHTLY="$WORKFLOW_INPUT_IS_NIGHTLY"
echo "Using Jan app URL from workflow input: $JAN_APP_URL"
echo "Is nightly build: $IS_NIGHTLY"
elif [ -n "$REPO_VARIABLE_URL" ]; then
JAN_APP_URL="$REPO_VARIABLE_URL"
IS_NIGHTLY="$REPO_VARIABLE_IS_NIGHTLY"
echo "Using Jan app URL from repository variable: $JAN_APP_URL"
echo "Is nightly build: $IS_NIGHTLY"
else
JAN_APP_URL="$DEFAULT_URL"
IS_NIGHTLY="$DEFAULT_IS_NIGHTLY"
echo "Using default Jan app URL: $JAN_APP_URL"
echo "Is nightly build: $IS_NIGHTLY"
fi
# Export for later steps
echo "JAN_APP_URL=$JAN_APP_URL" >> $GITHUB_ENV
echo "IS_NIGHTLY=$IS_NIGHTLY" >> $GITHUB_ENV
echo "Downloading Jan app from: $JAN_APP_URL"
curl -L -o "/tmp/jan-installer.dmg" "$JAN_APP_URL"
if [ ! -f "/tmp/jan-installer.dmg" ]; then
echo "[FAILED] Failed to download Jan app"
exit 1
fi
echo "[SUCCESS] Successfully downloaded Jan app"
ls -la "/tmp/jan-installer.dmg"

View File

@ -0,0 +1,91 @@
#!/bin/bash
# macOS install script for Jan app
echo "Installing Jan app from DMG..."
# Mount the DMG
hdiutil attach "/tmp/jan-installer.dmg" -mountpoint "/tmp/jan-mount"
# Find the .app file in the mounted DMG
APP_FILE=$(find "/tmp/jan-mount" -name "*.app" -type d | head -1)
if [ -z "$APP_FILE" ]; then
echo "[Failed] No .app file found in DMG"
hdiutil detach "/tmp/jan-mount" || true
exit 1
fi
echo "Found app file: $APP_FILE"
# Copy to Applications directory
cp -R "$APP_FILE" /Applications/
# Unmount the DMG
hdiutil detach "/tmp/jan-mount"
# Determine app name and executable path
APP_NAME=$(basename "$APP_FILE")
echo "App name: $APP_NAME"
# First, check what's actually in the MacOS folder
echo "Contents of MacOS folder:"
ls -la "/Applications/$APP_NAME/Contents/MacOS/"
# Find all executable files in MacOS folder
echo "Looking for executable files..."
find "/Applications/$APP_NAME/Contents/MacOS/" -type f -perm +111 -ls
# Try to find the main executable - it's usually the one with the same name as the app (without .app)
APP_BASE_NAME=$(basename "$APP_NAME" .app)
POTENTIAL_EXECUTABLES=(
"/Applications/$APP_NAME/Contents/MacOS/$APP_BASE_NAME"
"/Applications/$APP_NAME/Contents/MacOS/Jan"
"/Applications/$APP_NAME/Contents/MacOS/Jan-nightly"
)
APP_PATH=""
for potential_exec in "${POTENTIAL_EXECUTABLES[@]}"; do
echo "Checking: $potential_exec"
if [ -f "$potential_exec" ] && [ -x "$potential_exec" ]; then
APP_PATH="$potential_exec"
echo "Found executable: $APP_PATH"
break
fi
done
# If still not found, get any executable file
if [ -z "$APP_PATH" ]; then
echo "No predefined executable found, searching for any executable..."
APP_PATH=$(find "/Applications/$APP_NAME/Contents/MacOS/" -type f -perm +111 | head -1)
fi
if [ -z "$APP_PATH" ]; then
echo "[FAILED] No executable found in MacOS folder"
ls -la "/Applications/$APP_NAME/Contents/MacOS/"
exit 1
fi
PROCESS_NAME=$(basename "$APP_PATH")
echo "App installed at: /Applications/$APP_NAME"
echo "Executable path: $APP_PATH"
echo "Process name: $PROCESS_NAME"
# Export for test step
echo "JAN_APP_PATH=$APP_PATH" >> $GITHUB_ENV
echo "PROCESS_NAME=$PROCESS_NAME" >> $GITHUB_ENV
echo "[INFO] Waiting for Jan app first initialization (120 seconds)..."
echo "This allows Jan to complete its initial setup and configuration"
sleep 120
echo "[SUCCESS] Initialization wait completed"
# Verify installation
if [ -f "$APP_PATH" ]; then
echo "[SUCCESS] Jan app installed successfully"
ls -la "/Applications/$APP_NAME"
else
echo "[FAILED] Jan app installation failed - executable not found"
exit 1
fi

View File

@ -0,0 +1,38 @@
#!/bin/bash
# macOS post-test cleanup script
echo "Cleaning up after tests..."
# Kill any running Jan processes (both regular and nightly)
pkill -f "Jan" || true
pkill -f "jan" || true
pkill -f "Jan-nightly" || true
pkill -f "jan-nightly" || true
# Remove Jan app directories
rm -rf /Applications/Jan.app
rm -rf /Applications/Jan-nightly.app
rm -rf ~/Applications/Jan.app
rm -rf ~/Applications/Jan-nightly.app
# Remove Jan data folders (both regular and nightly)
rm -rf ~/Library/Application\ Support/Jan
rm -rf ~/Library/Application\ Support/Jan-nightly
rm -rf ~/Library/Application\ Support/jan.ai.app
rm -rf ~/Library/Application\ Support/jan-nightly.ai.app
rm -rf ~/Library/Preferences/jan.*
rm -rf ~/Library/Preferences/jan-nightly.*
rm -rf ~/Library/Caches/jan.*
rm -rf ~/Library/Caches/jan-nightly.*
rm -rf ~/Library/Caches/jan.ai.app
rm -rf ~/Library/Caches/jan-nightly.ai.app
rm -rf ~/Library/WebKit/jan.ai.app
rm -rf ~/Library/WebKit/jan-nightly.ai.app
rm -rf ~/Library/Saved\ Application\ State/jan.ai.app
rm -rf ~/Library/Saved\ Application\ State/jan-nightly.ai.app
# Clean up downloaded installer
rm -f "/tmp/jan-installer.dmg"
rm -rf "/tmp/jan-mount"
echo "Cleanup completed"

View File

@ -0,0 +1,31 @@
#!/usr/bin/env pwsh
# Windows test runner script
param(
[string]$JanAppPath,
[string]$ProcessName,
[string]$RpToken
)
Write-Host "Starting Auto QA Tests..."
Write-Host "Jan app path: $JanAppPath"
Write-Host "Process name: $ProcessName"
Write-Host "Current working directory: $(Get-Location)"
Write-Host "Contents of current directory:"
Get-ChildItem
Write-Host "Contents of trajectories directory (if exists):"
if (Test-Path "trajectories") {
Get-ChildItem "trajectories"
} else {
Write-Host "trajectories directory not found"
}
# Run the main test with proper arguments
if ($JanAppPath -and $ProcessName) {
python main.py --enable-reportportal --rp-token "$RpToken" --jan-app-path "$JanAppPath" --jan-process-name "$ProcessName"
} elseif ($JanAppPath) {
python main.py --enable-reportportal --rp-token "$RpToken" --jan-app-path "$JanAppPath"
} else {
python main.py --enable-reportportal --rp-token "$RpToken"
}

View File

@ -0,0 +1,69 @@
#!/bin/bash
# Common test runner script
JAN_APP_PATH="$1"
PROCESS_NAME="$2"
RP_TOKEN="$3"
PLATFORM="$4"
echo "Starting Auto QA Tests..."
echo "Platform: $PLATFORM"
echo "Jan app path: $JAN_APP_PATH"
echo "Process name: $PROCESS_NAME"
# Platform-specific setup
if [ "$PLATFORM" = "ubuntu" ]; then
# Get the current display session
export DISPLAY=$(w -h | awk 'NR==1 {print $2}')
echo "Display ID: $DISPLAY"
# Verify display is working
if [ -z "$DISPLAY" ]; then
echo "No display session found, falling back to :0"
export DISPLAY=:0
fi
echo "Using display: $DISPLAY"
# Test display connection
xdpyinfo -display $DISPLAY >/dev/null 2>&1 || {
echo "Display $DISPLAY is not available"
exit 1
}
# Make Jan executable if needed
if [ -f "/usr/bin/Jan-nightly" ]; then
sudo chmod +x /usr/bin/Jan-nightly
fi
if [ -f "/usr/bin/Jan" ]; then
sudo chmod +x /usr/bin/Jan
fi
fi
# macOS specific setup
if [ "$PLATFORM" = "macos" ]; then
# Verify Jan app path
if [ ! -f "$JAN_APP_PATH" ]; then
echo "❌ Jan app not found at: $JAN_APP_PATH"
echo "Available files in /Applications:"
ls -la /Applications/ | grep -i jan || echo "No Jan apps found"
exit 1
fi
fi
# Change to autoqa directory to ensure correct working directory
cd "$(dirname "$0")/.."
echo "Current working directory: $(pwd)"
echo "Contents of current directory:"
ls -la
echo "Contents of trajectories directory (if exists):"
ls -la trajectories/ 2>/dev/null || echo "trajectories directory not found"
# Run the main test with proper arguments
if [ -n "$JAN_APP_PATH" ] && [ -n "$PROCESS_NAME" ]; then
python main.py --enable-reportportal --rp-token "$RP_TOKEN" --jan-app-path "$JAN_APP_PATH" --jan-process-name "$PROCESS_NAME"
elif [ -n "$JAN_APP_PATH" ]; then
python main.py --enable-reportportal --rp-token "$RP_TOKEN" --jan-app-path "$JAN_APP_PATH"
else
python main.py --enable-reportportal --rp-token "$RP_TOKEN"
fi

View File

@ -0,0 +1,80 @@
#!/bin/bash
# Android Development Environment Setup for Jan
# Ensure rustup's Rust toolchain is used instead of Homebrew's
export PATH="$HOME/.cargo/bin:$PATH"
# Set JAVA_HOME for Android builds
export JAVA_HOME=/opt/homebrew/opt/openjdk@17/libexec/openjdk.jdk/Contents/Home
export PATH="/opt/homebrew/opt/openjdk@17/bin:$PATH"
export ANDROID_HOME="$HOME/Library/Android/sdk"
export ANDROID_NDK_ROOT="$HOME/Library/Android/sdk/ndk/29.0.14033849"
export NDK_HOME="$HOME/Library/Android/sdk/ndk/29.0.14033849"
# Add Android tools to PATH
export PATH=$PATH:$ANDROID_HOME/platform-tools:$ANDROID_HOME/tools:$ANDROID_HOME/cmdline-tools/latest/bin:$ANDROID_HOME/emulator:$NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin
# Set up CC and CXX for Android compilation
export CC_aarch64_linux_android="$NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/aarch64-linux-android21-clang"
export CXX_aarch64_linux_android="$NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/aarch64-linux-android21-clang++"
export AR_aarch64_linux_android="$NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/llvm-ar"
export RANLIB_aarch64_linux_android="$NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/llvm-ranlib"
# Additional environment variables for Rust cross-compilation
export CARGO_TARGET_AARCH64_LINUX_ANDROID_LINKER="$NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/aarch64-linux-android21-clang"
# Only set global CC and AR for Android builds (when IS_ANDROID is set)
if [ "$IS_ANDROID" = "true" ]; then
export CC="$NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/aarch64-linux-android21-clang"
export AR="$NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/llvm-ar"
echo "Global CC and AR set for Android build"
fi
# Create symlinks for Android tools if they don't exist
mkdir -p ~/.local/bin
if [ ! -f ~/.local/bin/aarch64-linux-android-ranlib ]; then
ln -sf $NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/llvm-ranlib ~/.local/bin/aarch64-linux-android-ranlib
fi
if [ ! -f ~/.local/bin/aarch64-linux-android-clang ]; then
ln -sf $NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/aarch64-linux-android21-clang ~/.local/bin/aarch64-linux-android-clang
fi
if [ ! -f ~/.local/bin/aarch64-linux-android-clang++ ]; then
ln -sf $NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/aarch64-linux-android21-clang++ ~/.local/bin/aarch64-linux-android-clang++
fi
# Fix the broken clang symlinks by ensuring base clang is available
if [ ! -f ~/.local/bin/clang ]; then
ln -sf $NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/clang ~/.local/bin/clang
fi
if [ ! -f ~/.local/bin/clang++ ]; then
ln -sf $NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/clang++ ~/.local/bin/clang++
fi
# Create symlinks for target-specific ar tools
if [ ! -f ~/.local/bin/aarch64-linux-android-ar ]; then
ln -sf $NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64/bin/llvm-ar ~/.local/bin/aarch64-linux-android-ar
fi
export PATH="$HOME/.local/bin:$PATH"
echo "Android environment configured:"
echo "ANDROID_HOME: $ANDROID_HOME"
echo "ANDROID_NDK_ROOT: $ANDROID_NDK_ROOT"
echo "PATH includes NDK toolchain: $(echo $PATH | grep -o "ndk.*bin" || echo "NOT FOUND")"
# Verify required tools
echo -e "\nChecking required tools:"
which adb && echo "✅ adb found" || echo "❌ adb not found"
which emulator && echo "✅ emulator found" || echo "❌ emulator not found"
which $CC_aarch64_linux_android && echo "✅ Android clang found" || echo "❌ Android clang not found"
# Show available AVDs
echo -e "\nAvailable Android Virtual Devices:"
emulator -list-avds 2>/dev/null || echo "No AVDs found"
# Execute the provided command
if [ "$1" ]; then
echo -e "\nExecuting: $@"
exec "$@"
fi

View File

@ -0,0 +1,15 @@
#!/bin/bash
# Setup script permissions for AutoQA scripts
echo "Setting up permissions for AutoQA scripts..."
# Get the directory where this script is located
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
# Make all shell scripts executable
chmod +x "$SCRIPT_DIR"/*.sh
echo "[SUCCESS] All shell scripts are now executable:"
ls -la "$SCRIPT_DIR"/*.sh
echo "[SUCCESS] Permission setup completed"

View File

@ -0,0 +1,22 @@
#!/bin/bash
# Ubuntu cleanup script for Jan app
echo "Cleaning existing Jan installations..."
# Remove Jan data folders (both regular and nightly)
rm -rf ~/.config/Jan
rm -rf ~/.config/Jan-nightly
rm -rf ~/.local/share/Jan
rm -rf ~/.local/share/Jan-nightly
rm -rf ~/.cache/jan
rm -rf ~/.cache/jan-nightly
rm -rf ~/.local/share/jan-nightly.ai.app
rm -rf ~/.local/share/jan.ai.app
# Kill any running Jan processes (both regular and nightly)
pkill -f "Jan" || true
pkill -f "jan" || true
pkill -f "Jan-nightly" || true
pkill -f "jan-nightly" || true
echo "Jan cleanup completed"

View File

@ -0,0 +1,57 @@
#!/bin/bash
# Ubuntu download script for Jan app
WORKFLOW_INPUT_URL="$1"
WORKFLOW_INPUT_IS_NIGHTLY="$2"
REPO_VARIABLE_URL="$3"
REPO_VARIABLE_IS_NIGHTLY="$4"
DEFAULT_URL="$5"
DEFAULT_IS_NIGHTLY="$6"
# Determine Jan app URL and nightly flag from multiple sources (priority order):
# 1. Workflow dispatch input (manual trigger)
# 2. Repository variable JAN_APP_URL_LINUX
# 3. Default URL from env
JAN_APP_URL=""
IS_NIGHTLY=false
if [ -n "$WORKFLOW_INPUT_URL" ]; then
JAN_APP_URL="$WORKFLOW_INPUT_URL"
IS_NIGHTLY="$WORKFLOW_INPUT_IS_NIGHTLY"
echo "Using Jan app URL from workflow input: $JAN_APP_URL"
echo "Is nightly build: $IS_NIGHTLY"
elif [ -n "$REPO_VARIABLE_URL" ]; then
JAN_APP_URL="$REPO_VARIABLE_URL"
IS_NIGHTLY="$REPO_VARIABLE_IS_NIGHTLY"
echo "Using Jan app URL from repository variable: $JAN_APP_URL"
echo "Is nightly build: $IS_NIGHTLY"
else
JAN_APP_URL="$DEFAULT_URL"
IS_NIGHTLY="$DEFAULT_IS_NIGHTLY"
echo "Using default Jan app URL: $JAN_APP_URL"
echo "Is nightly build: $IS_NIGHTLY"
fi
# Set environment variables for later steps
echo "JAN_APP_URL=$JAN_APP_URL" >> $GITHUB_ENV
echo "IS_NIGHTLY=$IS_NIGHTLY" >> $GITHUB_ENV
echo "Downloading Jan app from: $JAN_APP_URL"
DOWNLOAD_PATH="/tmp/jan-installer.deb"
# Download the package
if ! wget "$JAN_APP_URL" -O "$DOWNLOAD_PATH"; then
echo "Failed to download Jan app"
exit 1
fi
if [ -f "$DOWNLOAD_PATH" ]; then
FILE_SIZE=$(stat -c%s "$DOWNLOAD_PATH")
echo "Downloaded Jan app successfully. Size: $FILE_SIZE bytes"
echo "File saved to: $DOWNLOAD_PATH"
else
echo "Downloaded file not found"
exit 1
fi

View File

@ -0,0 +1,39 @@
#!/bin/bash
# Ubuntu install script for Jan app
IS_NIGHTLY="$1"
INSTALLER_PATH="/tmp/jan-installer.deb"
echo "Installing Jan app..."
echo "Is nightly build: $IS_NIGHTLY"
# Install the .deb package
sudo apt install "$INSTALLER_PATH" -y
sudo apt-get install -f -y
# Wait for installation to complete
sleep 10
echo "[INFO] Waiting for Jan app first initialization (120 seconds)..."
echo "This allows Jan to complete its initial setup and configuration"
sleep 120
echo "[SUCCESS] Initialization wait completed"
# Verify installation based on nightly flag
if [ "$IS_NIGHTLY" = "true" ]; then
DEFAULT_JAN_PATH="/usr/bin/Jan-nightly"
PROCESS_NAME="Jan-nightly"
else
DEFAULT_JAN_PATH="/usr/bin/Jan"
PROCESS_NAME="Jan"
fi
if [ -f "$DEFAULT_JAN_PATH" ]; then
echo "Jan app installed successfully at: $DEFAULT_JAN_PATH"
echo "JAN_APP_PATH=$DEFAULT_JAN_PATH" >> $GITHUB_ENV
echo "JAN_PROCESS_NAME=$PROCESS_NAME" >> $GITHUB_ENV
else
echo "Jan app not found at expected location: $DEFAULT_JAN_PATH"
echo "Will auto-detect during test run"
fi

View File

@ -0,0 +1,44 @@
#!/bin/bash
# Ubuntu post-test cleanup script
IS_NIGHTLY="$1"
echo "Cleaning up after tests..."
# Kill any running Jan processes (both regular and nightly)
pkill -f "Jan" || true
pkill -f "jan" || true
pkill -f "Jan-nightly" || true
pkill -f "jan-nightly" || true
# Remove Jan data folders (both regular and nightly)
rm -rf ~/.config/Jan
rm -rf ~/.config/Jan-nightly
rm -rf ~/.local/share/Jan
rm -rf ~/.local/share/Jan-nightly
rm -rf ~/.cache/jan
rm -rf ~/.cache/jan-nightly
rm -rf ~/.local/share/jan-nightly.ai.app
rm -rf ~/.local/share/jan.ai.app
# Try to uninstall Jan app
if [ "$IS_NIGHTLY" = "true" ]; then
PACKAGE_NAME="jan-nightly"
else
PACKAGE_NAME="jan"
fi
echo "Attempting to uninstall package: $PACKAGE_NAME"
if dpkg -l | grep -q "$PACKAGE_NAME"; then
echo "Found package $PACKAGE_NAME, uninstalling..."
sudo dpkg -r "$PACKAGE_NAME" || true
sudo apt-get autoremove -y || true
else
echo "Package $PACKAGE_NAME not found in dpkg list"
fi
# Clean up downloaded installer
rm -f "/tmp/jan-installer.deb"
echo "Cleanup completed"

View File

@ -0,0 +1,50 @@
#!/usr/bin/env pwsh
# Windows cleanup script for Jan app
param(
[string]$IsNightly = "false"
)
Write-Host "Cleaning existing Jan installations..."
# Remove Jan data folders (both regular and nightly)
$janAppData = "$env:APPDATA\Jan"
$janNightlyAppData = "$env:APPDATA\Jan-nightly"
$janLocalAppData = "$env:LOCALAPPDATA\jan.ai.app"
$janNightlyLocalAppData = "$env:LOCALAPPDATA\jan-nightly.ai.app"
if (Test-Path $janAppData) {
Write-Host "Removing $janAppData"
Remove-Item -Path $janAppData -Recurse -Force -ErrorAction SilentlyContinue
}
if (Test-Path $janNightlyAppData) {
Write-Host "Removing $janNightlyAppData"
Remove-Item -Path $janNightlyAppData -Recurse -Force -ErrorAction SilentlyContinue
}
if (Test-Path $janLocalAppData) {
Write-Host "Removing $janLocalAppData"
Remove-Item -Path $janLocalAppData -Recurse -Force -ErrorAction SilentlyContinue
}
if (Test-Path $janNightlyLocalAppData) {
Write-Host "Removing $janNightlyLocalAppData"
Remove-Item -Path $janNightlyLocalAppData -Recurse -Force -ErrorAction SilentlyContinue
}
# Kill any running Jan processes (both regular and nightly)
Get-Process -Name "Jan" -ErrorAction SilentlyContinue | Stop-Process -Force -ErrorAction SilentlyContinue
Get-Process -Name "jan" -ErrorAction SilentlyContinue | Stop-Process -Force -ErrorAction SilentlyContinue
Get-Process -Name "Jan-nightly" -ErrorAction SilentlyContinue | Stop-Process -Force -ErrorAction SilentlyContinue
Get-Process -Name "jan-nightly" -ErrorAction SilentlyContinue | Stop-Process -Force -ErrorAction SilentlyContinue
# Remove Jan extensions folder
$janExtensionsPath = "$env:USERPROFILE\jan\extensions"
if (Test-Path $janExtensionsPath) {
Write-Host "Removing $janExtensionsPath"
Remove-Item -Path $janExtensionsPath -Recurse -Force -ErrorAction SilentlyContinue
}
Write-Host "Jan cleanup completed"

View File

@ -0,0 +1,63 @@
#!/usr/bin/env pwsh
# Windows download script for Jan app
param(
[string]$WorkflowInputUrl = "",
[string]$WorkflowInputIsNightly = "",
[string]$RepoVariableUrl = "",
[string]$RepoVariableIsNightly = "",
[string]$DefaultUrl = "",
[string]$DefaultIsNightly = ""
)
# Determine Jan app URL and nightly flag from multiple sources (priority order):
# 1. Workflow dispatch input (manual trigger)
# 2. Repository variable JAN_APP_URL
# 3. Default URL from env
$janAppUrl = ""
$isNightly = $false
if ($WorkflowInputUrl -ne "") {
$janAppUrl = $WorkflowInputUrl
$isNightly = [System.Convert]::ToBoolean($WorkflowInputIsNightly)
Write-Host "Using Jan app URL from workflow input: $janAppUrl"
Write-Host "Is nightly build: $isNightly"
}
elseif ($RepoVariableUrl -ne "") {
$janAppUrl = $RepoVariableUrl
$isNightly = [System.Convert]::ToBoolean($RepoVariableIsNightly)
Write-Host "Using Jan app URL from repository variable: $janAppUrl"
Write-Host "Is nightly build: $isNightly"
}
else {
$janAppUrl = $DefaultUrl
$isNightly = [System.Convert]::ToBoolean($DefaultIsNightly)
Write-Host "Using default Jan app URL: $janAppUrl"
Write-Host "Is nightly build: $isNightly"
}
# Set environment variables for later steps
Write-Output "JAN_APP_URL=$janAppUrl" >> $env:GITHUB_ENV
Write-Output "IS_NIGHTLY=$isNightly" >> $env:GITHUB_ENV
Write-Host "Downloading Jan app from: $janAppUrl"
$downloadPath = "$env:TEMP\jan-installer.exe"
try {
# Use wget for better performance
wget.exe "$janAppUrl" -O "$downloadPath"
if (Test-Path $downloadPath) {
$fileSize = (Get-Item $downloadPath).Length
Write-Host "Downloaded Jan app successfully. Size: $fileSize bytes"
Write-Host "File saved to: $downloadPath"
} else {
throw "Downloaded file not found"
}
}
catch {
Write-Error "Failed to download Jan app: $_"
exit 1
}

View File

@ -0,0 +1,48 @@
#!/usr/bin/env pwsh
# Windows install script for Jan app
param(
[string]$IsNightly = "false"
)
$installerPath = "$env:TEMP\jan-installer.exe"
$isNightly = [System.Convert]::ToBoolean($IsNightly)
Write-Host "Installing Jan app..."
Write-Host "Is nightly build: $isNightly"
# Try silent installation first
try {
Start-Process -FilePath $installerPath -ArgumentList "/S" -Wait -NoNewWindow
Write-Host "Jan app installed silently"
}
catch {
Write-Host "Silent installation failed, trying normal installation..."
Start-Process -FilePath $installerPath -Wait -NoNewWindow
}
# Wait a bit for installation to complete
Start-Sleep -Seconds 10
Write-Host "[INFO] Waiting for Jan app first initialization (120 seconds)..."
Write-Host "This allows Jan to complete its initial setup and configuration"
Start-Sleep -Seconds 120
Write-Host "[SUCCESS] Initialization wait completed"
# Verify installation based on nightly flag
if ($isNightly) {
$defaultJanPath = "$env:LOCALAPPDATA\Programs\jan-nightly\Jan-nightly.exe"
$processName = "Jan-nightly.exe"
} else {
$defaultJanPath = "$env:LOCALAPPDATA\Programs\jan\Jan.exe"
$processName = "Jan.exe"
}
if (Test-Path $defaultJanPath) {
Write-Host "Jan app installed successfully at: $defaultJanPath"
Write-Output "JAN_APP_PATH=$defaultJanPath" >> $env:GITHUB_ENV
Write-Output "JAN_PROCESS_NAME=$processName" >> $env:GITHUB_ENV
} else {
Write-Warning "Jan app not found at expected location: $defaultJanPath"
Write-Host "Will auto-detect during test run"
}

View File

@ -0,0 +1,102 @@
#!/usr/bin/env pwsh
# Windows post-test cleanup script
param(
[string]$IsNightly = "false"
)
Write-Host "Cleaning up after tests..."
# Kill any running Jan processes (both regular and nightly)
Get-Process -Name "Jan" -ErrorAction SilentlyContinue | Stop-Process -Force -ErrorAction SilentlyContinue
Get-Process -Name "jan" -ErrorAction SilentlyContinue | Stop-Process -Force -ErrorAction SilentlyContinue
Get-Process -Name "Jan-nightly" -ErrorAction SilentlyContinue | Stop-Process -Force -ErrorAction SilentlyContinue
Get-Process -Name "jan-nightly" -ErrorAction SilentlyContinue | Stop-Process -Force -ErrorAction SilentlyContinue
# Remove Jan data folders (both regular and nightly)
$janAppData = "$env:APPDATA\Jan"
$janNightlyAppData = "$env:APPDATA\Jan-nightly"
$janLocalAppData = "$env:LOCALAPPDATA\jan.ai.app"
$janNightlyLocalAppData = "$env:LOCALAPPDATA\jan-nightly.ai.app"
$janProgramsPath = "$env:LOCALAPPDATA\Programs\Jan"
$janNightlyProgramsPath = "$env:LOCALAPPDATA\Programs\Jan-nightly"
if (Test-Path $janAppData) {
Write-Host "Removing $janAppData"
Remove-Item -Path $janAppData -Recurse -Force -ErrorAction SilentlyContinue
}
if (Test-Path $janNightlyAppData) {
Write-Host "Removing $janNightlyAppData"
Remove-Item -Path $janNightlyAppData -Recurse -Force -ErrorAction SilentlyContinue
}
if (Test-Path $janLocalAppData) {
Write-Host "Removing $janLocalAppData"
Remove-Item -Path $janLocalAppData -Recurse -Force -ErrorAction SilentlyContinue
}
if (Test-Path $janNightlyLocalAppData) {
Write-Host "Removing $janNightlyLocalAppData"
Remove-Item -Path $janNightlyLocalAppData -Recurse -Force -ErrorAction SilentlyContinue
}
if (Test-Path $janProgramsPath) {
Write-Host "Removing $janProgramsPath"
Remove-Item -Path $janProgramsPath -Recurse -Force -ErrorAction SilentlyContinue
}
if (Test-Path $janNightlyProgramsPath) {
Write-Host "Removing $janNightlyProgramsPath"
Remove-Item -Path $janNightlyProgramsPath -Recurse -Force -ErrorAction SilentlyContinue
}
# Remove Jan extensions folder
$janExtensionsPath = "$env:USERPROFILE\jan\extensions"
if (Test-Path $janExtensionsPath) {
Write-Host "Removing $janExtensionsPath"
Remove-Item -Path $janExtensionsPath -Recurse -Force -ErrorAction SilentlyContinue
}
# Try to uninstall Jan app silently
try {
$isNightly = [System.Convert]::ToBoolean($IsNightly)
# Determine uninstaller path based on nightly flag
if ($isNightly) {
$uninstallerPath = "$env:LOCALAPPDATA\Programs\jan-nightly\uninstall.exe"
$installPath = "$env:LOCALAPPDATA\Programs\jan-nightly"
} else {
$uninstallerPath = "$env:LOCALAPPDATA\Programs\jan\uninstall.exe"
$installPath = "$env:LOCALAPPDATA\Programs\jan"
}
Write-Host "Looking for uninstaller at: $uninstallerPath"
if (Test-Path $uninstallerPath) {
Write-Host "Found uninstaller, attempting silent uninstall..."
Start-Process -FilePath $uninstallerPath -ArgumentList "/S" -Wait -NoNewWindow -ErrorAction SilentlyContinue
Write-Host "Uninstall completed"
} else {
Write-Host "No uninstaller found, attempting manual cleanup..."
if (Test-Path $installPath) {
Write-Host "Removing installation directory: $installPath"
Remove-Item -Path $installPath -Recurse -Force -ErrorAction SilentlyContinue
}
}
Write-Host "Jan app cleanup completed"
}
catch {
Write-Warning "Failed to uninstall Jan app cleanly: $_"
Write-Host "Manual cleanup may be required"
}
# Clean up downloaded installer
$installerPath = "$env:TEMP\jan-installer.exe"
if (Test-Path $installerPath) {
Remove-Item -Path $installerPath -Force -ErrorAction SilentlyContinue
}
Write-Host "Cleanup completed"

322
autoqa/test_runner.py Normal file
View File

@ -0,0 +1,322 @@
import os
import asyncio
import threading
import time
import logging
from datetime import datetime
from pathlib import Path
# from computer import Computer
from agent import ComputerAgent, LLM
from utils import is_jan_running, force_close_jan, start_jan_app, get_latest_trajectory_folder
from screen_recorder import ScreenRecorder
from reportportal_handler import upload_test_results_to_rp
from reportportal_client.helpers import timestamp
logger = logging.getLogger(__name__)
async def run_single_test_with_timeout(computer, test_data, rp_client, launch_id, max_turns=30,
jan_app_path=None, jan_process_name="Jan.exe", agent_config=None,
enable_reportportal=False):
"""
Run a single test case with turn count monitoring, forced stop, and screen recording
Returns dict with test result: {"success": bool, "status": str, "message": str}
"""
path = test_data['path']
prompt = test_data['prompt']
# Detect if using nightly version based on process name
is_nightly = "nightly" in jan_process_name.lower() if jan_process_name else False
# Default agent config if not provided
if agent_config is None:
agent_config = {
"loop": "uitars",
"model_provider": "oaicompat",
"model_name": "ByteDance-Seed/UI-TARS-1.5-7B",
"model_base_url": "http://10.200.108.58:1234/v1"
}
# Create trajectory_dir from path (remove .txt extension)
trajectory_name = str(Path(path).with_suffix(''))
trajectory_base_dir = os.path.abspath(f"trajectories/{trajectory_name.replace(os.sep, '/')}")
# Ensure trajectories directory exists
os.makedirs(os.path.dirname(trajectory_base_dir), exist_ok=True)
# Create recordings directory
recordings_dir = "recordings"
os.makedirs(recordings_dir, exist_ok=True)
# Create video filename
current_time = datetime.now().strftime("%Y%m%d_%H%M%S")
safe_test_name = trajectory_name.replace('/', '_').replace('\\', '_')
video_filename = f"{safe_test_name}_{current_time}.mp4"
video_path = os.path.abspath(os.path.join(recordings_dir, video_filename))
# Initialize result tracking
test_result_data = {
"success": False,
"status": "UNKNOWN",
"message": "Test execution incomplete",
"trajectory_dir": None,
"video_path": video_path
}
logger.info(f"Starting test: {path}")
logger.info(f"Current working directory: {os.getcwd()}")
logger.info(f"Trajectory base directory: {trajectory_base_dir}")
logger.info(f"Screen recording will be saved to: {video_path}")
logger.info(f"Using model: {agent_config['model_name']} from {agent_config['model_base_url']}")
logger.info(f"ReportPortal upload: {'ENABLED' if enable_reportportal else 'DISABLED'}")
trajectory_dir = None
agent_task = None
monitor_stop_event = threading.Event()
force_stopped_due_to_turns = False # Track if test was force stopped
# Initialize screen recorder
recorder = ScreenRecorder(video_path, fps=10)
try:
# Step 1: Check and force close Jan app if running
if is_jan_running(jan_process_name):
logger.info("Jan application is running, force closing...")
force_close_jan(jan_process_name)
# Step 2: Start Jan app in maximized mode
if jan_app_path:
start_jan_app(jan_app_path)
else:
start_jan_app() # Use default path
# Step 3: Start screen recording
recorder.start_recording()
# Step 4: Create agent for this test using config
agent = ComputerAgent(
computer=computer,
loop=agent_config["loop"],
model=LLM(
provider=agent_config["model_provider"],
name=agent_config["model_name"],
provider_base_url=agent_config["model_base_url"]
),
trajectory_dir=trajectory_base_dir
)
# Step 5: Start monitoring thread
def monitor_thread():
nonlocal force_stopped_due_to_turns
while not monitor_stop_event.is_set():
try:
if os.path.exists(trajectory_base_dir):
folders = [f for f in os.listdir(trajectory_base_dir)
if os.path.isdir(os.path.join(trajectory_base_dir, f))]
if folders:
latest_folder = sorted(folders)[-1]
latest_folder_path = os.path.join(trajectory_base_dir, latest_folder)
if os.path.exists(latest_folder_path):
turn_folders = [f for f in os.listdir(latest_folder_path)
if os.path.isdir(os.path.join(latest_folder_path, f)) and f.startswith("turn_")]
turn_count = len(turn_folders)
logger.info(f"Current turn count: {turn_count}")
if turn_count >= max_turns:
logger.warning(f"Turn count exceeded {max_turns} for test {path}, forcing stop")
force_stopped_due_to_turns = True # Mark as force stopped
# Cancel the agent task
if agent_task and not agent_task.done():
agent_task.cancel()
monitor_stop_event.set()
return
# Check every 5 seconds
if not monitor_stop_event.wait(5):
continue
else:
break
except Exception as e:
logger.error(f"Error in monitor thread: {e}")
time.sleep(5)
# Start monitoring in background thread
monitor_thread_obj = threading.Thread(target=monitor_thread, daemon=True)
monitor_thread_obj.start()
# Step 6: Run the test with prompt
logger.info(f"Running test case: {path}")
try:
# Create the agent task
async def run_agent():
async for result in agent.run(prompt):
if monitor_stop_event.is_set():
logger.warning(f"Test {path} stopped due to turn limit")
break
logger.info(f"Test result for {path}: {result}")
print(result)
agent_task = asyncio.create_task(run_agent())
# Wait for agent task to complete or timeout
try:
await asyncio.wait_for(agent_task, timeout=600) # 10 minute timeout as backup
if not monitor_stop_event.is_set():
logger.info(f"Successfully completed test execution: {path}")
else:
logger.warning(f"Test {path} was stopped due to turn limit")
except asyncio.TimeoutError:
logger.warning(f"Test {path} timed out after 10 minutes")
agent_task.cancel()
except asyncio.CancelledError:
logger.warning(f"Test {path} was cancelled due to turn limit")
finally:
# Stop monitoring
monitor_stop_event.set()
except Exception as e:
logger.error(f"Error running test {path}: {e}")
monitor_stop_event.set()
# Update result data for exception case
test_result_data.update({
"success": False,
"status": "ERROR",
"message": f"Test execution failed with exception: {str(e)}",
"trajectory_dir": None
})
finally:
# Step 7: Stop screen recording
try:
recorder.stop_recording()
logger.info(f"Screen recording saved to: {video_path}")
except Exception as e:
logger.error(f"Error stopping screen recording: {e}")
# Step 8: Upload results to ReportPortal only if enabled
if enable_reportportal and rp_client and launch_id:
# Get trajectory folder first
trajectory_dir = get_latest_trajectory_folder(trajectory_base_dir)
try:
if trajectory_dir:
logger.info(f"Uploading results to ReportPortal for: {path}")
logger.info(f"Video path for upload: {video_path}")
logger.info(f"Video exists: {os.path.exists(video_path)}")
if os.path.exists(video_path):
logger.info(f"Video file size: {os.path.getsize(video_path)} bytes")
upload_test_results_to_rp(rp_client, launch_id, path, trajectory_dir, force_stopped_due_to_turns, video_path, is_nightly)
else:
logger.warning(f"Test completed but no trajectory found for: {path}")
# Handle case where test completed but no trajectory found
formatted_test_path = path.replace('\\', '/').replace('.txt', '').replace('/', '__')
test_item_id = rp_client.start_test_item(
launch_id=launch_id,
name=formatted_test_path,
start_time=timestamp(),
item_type="TEST"
)
rp_client.log(
time=timestamp(),
level="ERROR",
message="Test execution completed but no trajectory data found",
item_id=test_item_id
)
# Still upload video for failed test
if video_path and os.path.exists(video_path):
try:
with open(video_path, "rb") as video_file:
rp_client.log(
time=timestamp(),
level="INFO",
message="[INFO] Screen recording of failed test",
item_id=test_item_id,
attachment={
"name": f"failed_test_recording_{formatted_test_path}.mp4",
"data": video_file.read(),
"mime": "video/x-msvideo"
}
)
except Exception as e:
logger.error(f"Error uploading video for failed test: {e}")
rp_client.finish_test_item(
item_id=test_item_id,
end_time=timestamp(),
status="FAILED"
)
except Exception as upload_error:
logger.error(f"Error uploading results for {path}: {upload_error}")
else:
# For non-ReportPortal mode, still get trajectory for final results
trajectory_dir = get_latest_trajectory_folder(trajectory_base_dir)
# Always process results for consistency (both RP and local mode)
# trajectory_dir is already set above, no need to call get_latest_trajectory_folder again
if trajectory_dir:
# Extract test result for processing
from reportportal_handler import extract_test_result_from_trajectory
if force_stopped_due_to_turns:
final_status = "FAILED"
status_message = "exceeded maximum turn limit ({} turns)".format(max_turns)
test_result_data.update({
"success": False,
"status": final_status,
"message": status_message,
"trajectory_dir": trajectory_dir
})
else:
test_result = extract_test_result_from_trajectory(trajectory_dir)
if test_result is True:
final_status = "PASSED"
status_message = "completed successfully with positive result"
test_result_data.update({
"success": True,
"status": final_status,
"message": status_message,
"trajectory_dir": trajectory_dir
})
else:
final_status = "FAILED"
status_message = "no valid success result found"
test_result_data.update({
"success": False,
"status": final_status,
"message": status_message,
"trajectory_dir": trajectory_dir
})
if not enable_reportportal:
# Local development mode - log results
logger.info(f"[INFO] LOCAL RESULT: {path} - {final_status} ({status_message})")
logger.info(f"[INFO] Video saved: {video_path}")
logger.info(f"[INFO] Trajectory: {trajectory_dir}")
else:
final_status = "FAILED"
status_message = "no trajectory found"
test_result_data.update({
"success": False,
"status": final_status,
"message": status_message,
"trajectory_dir": None
})
if not enable_reportportal:
logger.warning(f"[INFO] LOCAL RESULT: {path} - {final_status} ({status_message})")
# Step 9: Always force close Jan app after test completion
logger.info(f"Cleaning up after test: {path}")
force_close_jan(jan_process_name)
# Return test result
return test_result_data

View File

@ -0,0 +1,17 @@
prompt = """
You are going to test the Jan application by downloading and chatting with a model (bitcpm4).
Step-by-step instructions:
1. Given the Jan application is already opened.
2. In the **bottom-left corner**, click the **Hub** menu item.
3. Scroll through the model list or use the search bar to find **qwen3-0.6B**.
4. Click **Use** on the qwen3-0.6B model.
5. Wait for the model to finish downloading and become ready.
6. Once redirected to the chat screen, type any message into the input box (e.g. `Hello World`).
7. Press **Enter** to send the message.
8. Wait for the models response.
If the model responds correctly, return: {"result": True}, otherwise return: {"result": False}.
In all your responses, use only plain ASCII characters. Do NOT use Unicode symbols
"""

343
autoqa/utils.py Normal file
View File

@ -0,0 +1,343 @@
import os
import logging
import subprocess
import psutil
import time
import pyautogui
import platform
from pathlib import Path
logger = logging.getLogger(__name__)
# Cross-platform window management
IS_LINUX = platform.system() == "Linux"
IS_WINDOWS = platform.system() == "Windows"
IS_MACOS = platform.system() == "Darwin"
if IS_WINDOWS:
try:
import pygetwindow as gw
except ImportError:
gw = None
logger.warning("pygetwindow not available on this system")
def is_jan_running(jan_process_name="Jan.exe"):
"""
Check if Jan application is currently running
"""
for proc in psutil.process_iter(['pid', 'name']):
try:
if proc.info['name'] and jan_process_name.lower() in proc.info['name'].lower():
return True
except (psutil.NoSuchProcess, psutil.AccessDenied, psutil.ZombieProcess):
pass
return False
def force_close_jan(jan_process_name="Jan.exe"):
"""
Force close Jan application if it's running
"""
logger.info("Checking for running Jan processes...")
closed_any = False
for proc in psutil.process_iter(['pid', 'name']):
try:
if proc.info['name'] and jan_process_name.lower() in proc.info['name'].lower():
logger.info(f"Force closing Jan process (PID: {proc.info['pid']})")
proc.kill()
closed_any = True
except (psutil.NoSuchProcess, psutil.AccessDenied, psutil.ZombieProcess):
pass
if closed_any:
logger.info("Waiting for Jan processes to terminate...")
time.sleep(3) # Wait for processes to fully terminate
else:
logger.info("No Jan processes found running")
def find_jan_window_linux():
"""
Find Jan window on Linux using wmctrl
"""
try:
result = subprocess.run(['wmctrl', '-l'], capture_output=True, text=True, timeout=10)
if result.returncode == 0:
for line in result.stdout.split('\n'):
if 'jan' in line.lower() or 'Jan' in line:
# Extract window ID (first column)
window_id = line.split()[0]
logger.info(f"Found Jan window with ID: {window_id}")
return window_id
except (subprocess.TimeoutExpired, FileNotFoundError, subprocess.SubprocessError) as e:
logger.warning(f"wmctrl command failed: {e}")
return None
def maximize_jan_window_linux():
"""
Maximize Jan window on Linux using wmctrl
"""
window_id = find_jan_window_linux()
if window_id:
try:
# Maximize window using wmctrl
subprocess.run(['wmctrl', '-i', '-r', window_id, '-b', 'add,maximized_vert,maximized_horz'],
timeout=5)
logger.info("Jan window maximized using wmctrl")
return True
except (subprocess.TimeoutExpired, subprocess.SubprocessError) as e:
logger.warning(f"Failed to maximize with wmctrl: {e}")
# Fallback: Try xdotool
try:
result = subprocess.run(['xdotool', 'search', '--name', 'Jan'],
capture_output=True, text=True, timeout=5)
if result.returncode == 0 and result.stdout.strip():
window_id = result.stdout.strip().split('\n')[0]
subprocess.run(['xdotool', 'windowactivate', window_id], timeout=5)
subprocess.run(['xdotool', 'key', 'alt+F10'], timeout=5) # Maximize shortcut
logger.info("Jan window maximized using xdotool")
return True
except (subprocess.TimeoutExpired, FileNotFoundError, subprocess.SubprocessError) as e:
logger.warning(f"xdotool command failed: {e}")
return False
def find_jan_window_macos():
"""
Find Jan window on macOS using AppleScript
"""
try:
# AppleScript to find Jan window
script = '''
tell application "System Events"
set janApps to (every process whose name contains "Jan")
if length of janApps > 0 then
return name of first item of janApps
else
return ""
end if
end tell
'''
result = subprocess.run(['osascript', '-e', script],
capture_output=True, text=True, timeout=10)
if result.returncode == 0 and result.stdout.strip():
app_name = result.stdout.strip()
logger.info(f"Found Jan app: {app_name}")
return app_name
except (subprocess.TimeoutExpired, FileNotFoundError, subprocess.SubprocessError) as e:
logger.warning(f"AppleScript command failed: {e}")
return None
def maximize_jan_window_macos():
"""
Maximize Jan window on macOS using AppleScript
"""
app_name = find_jan_window_macos()
if app_name:
try:
# AppleScript to maximize window
script = f'''
tell application "System Events"
tell process "{app_name}"
set frontmost to true
tell window 1
set value of attribute "AXFullScreen" to true
end tell
end tell
end tell
'''
result = subprocess.run(['osascript', '-e', script], timeout=10)
if result.returncode == 0:
logger.info("Jan window maximized using AppleScript")
return True
except (subprocess.TimeoutExpired, subprocess.SubprocessError) as e:
logger.warning(f"Failed to maximize with AppleScript: {e}")
# Fallback: Try Command+M (fullscreen hotkey on macOS)
try:
logger.info("Trying Cmd+Ctrl+F hotkey to maximize")
pyautogui.hotkey('cmd', 'ctrl', 'f')
time.sleep(1)
logger.info("Attempted to maximize using Cmd+Ctrl+F")
return True
except Exception as e:
logger.warning(f"Hotkey maximize failed: {e}")
return False
def maximize_jan_window():
"""
Find and maximize Jan window (cross-platform)
"""
try:
# Wait a bit for window to appear
time.sleep(2)
if IS_LINUX:
return maximize_jan_window_linux()
elif IS_MACOS:
return maximize_jan_window_macos()
elif IS_WINDOWS and gw:
# Method 1: Try to find window by title containing "Jan"
windows = gw.getWindowsWithTitle("Jan")
if windows:
jan_window = windows[0]
logger.info(f"Found Jan window: {jan_window.title}")
jan_window.maximize()
logger.info("Jan window maximized using pygetwindow")
return True
# Fallback methods for both platforms
# Method 2: Try Alt+Space then X (maximize hotkey) - works on both platforms
logger.info("Trying Alt+Space+X hotkey to maximize")
pyautogui.hotkey('alt', 'space')
time.sleep(0.5)
pyautogui.press('x')
logger.info("Attempted to maximize using Alt+Space+X")
return True
except Exception as e:
logger.warning(f"Could not maximize Jan window: {e}")
# Method 3: Platform-specific fallback
try:
if IS_WINDOWS:
logger.info("Trying Windows+Up arrow to maximize")
pyautogui.hotkey('win', 'up')
elif IS_LINUX:
logger.info("Trying Alt+F10 to maximize")
pyautogui.hotkey('alt', 'F10')
elif IS_MACOS:
logger.info("Trying macOS specific maximize")
pyautogui.hotkey('cmd', 'tab') # Switch to Jan if it's running
time.sleep(0.5)
return True
except Exception as e2:
logger.warning(f"All maximize methods failed: {e2}")
return False
def start_jan_app(jan_app_path=None):
"""
Start Jan application in maximized window (cross-platform)
"""
# Set default path based on platform
if jan_app_path is None:
if IS_WINDOWS:
jan_app_path = os.path.expanduser(r"~\AppData\Local\Programs\jan\Jan.exe")
elif IS_LINUX:
jan_app_path = "/usr/bin/Jan" # or "/usr/bin/Jan" for regular
elif IS_MACOS:
jan_app_path = "/Applications/Jan.app/Contents/MacOS/Jan" # Default macOS path
else:
raise NotImplementedError(f"Platform {platform.system()} not supported")
logger.info(f"Starting Jan application from: {jan_app_path}")
if not os.path.exists(jan_app_path):
logger.error(f"Jan executable not found at: {jan_app_path}")
raise FileNotFoundError(f"Jan app not found at {jan_app_path}")
try:
# Start the Jan application
if IS_WINDOWS:
subprocess.Popen([jan_app_path], shell=True)
elif IS_LINUX:
# On Linux, start with DISPLAY environment variable
env = os.environ.copy()
subprocess.Popen([jan_app_path], env=env)
elif IS_MACOS:
# On macOS, use 'open' command to launch .app bundle properly
if jan_app_path.endswith('.app/Contents/MacOS/Jan'):
# Use the .app bundle path instead
app_bundle = jan_app_path.replace('/Contents/MacOS/Jan', '')
subprocess.Popen(['open', app_bundle])
elif jan_app_path.endswith('.app'):
# Direct .app bundle
subprocess.Popen(['open', jan_app_path])
elif '/Contents/MacOS/' in jan_app_path:
# Extract app bundle from full executable path
app_bundle = jan_app_path.split('/Contents/MacOS/')[0]
subprocess.Popen(['open', app_bundle])
else:
# Fallback: try to execute directly
subprocess.Popen([jan_app_path])
else:
raise NotImplementedError(f"Platform {platform.system()} not supported")
logger.info("Jan application started")
# Wait for app to fully load
logger.info("Waiting for Jan application to initialize...")
time.sleep(5)
# Try to maximize the window
if maximize_jan_window():
logger.info("Jan application maximized successfully")
else:
logger.warning("Could not maximize Jan application window")
# Wait a bit more after maximizing
time.sleep(10)
logger.info("Jan application should be ready, waiting for additional setup...")
time.sleep(10) # Additional wait to ensure everything is ready
except Exception as e:
logger.error(f"Error starting Jan application: {e}")
raise
def scan_test_files(tests_dir="tests"):
"""
Scan tests folder and find all .txt files
Returns list with format [{'path': 'relative_path', 'prompt': 'file_content'}]
"""
test_files = []
tests_path = Path(tests_dir)
if not tests_path.exists():
logger.error(f"Tests directory {tests_dir} does not exist!")
return test_files
# Scan all .txt files in folder and subfolders
for txt_file in tests_path.rglob("*.txt"):
try:
# Read file content
with open(txt_file, 'r', encoding='utf-8') as f:
content = f.read().strip()
# Get relative path
relative_path = txt_file.relative_to(tests_path)
test_files.append({
'path': str(relative_path),
'prompt': content
})
logger.info(f"Found test file: {relative_path}")
except Exception as e:
logger.error(f"Error reading file {txt_file}: {e}")
return test_files
def get_latest_trajectory_folder(trajectory_base_path):
"""
Get the latest created folder in trajectory base path
"""
if not os.path.exists(trajectory_base_path):
logger.warning(f"Trajectory base path not found: {trajectory_base_path}")
return None
# Get all folders and sort by creation time (latest first)
folders = [f for f in os.listdir(trajectory_base_path)
if os.path.isdir(os.path.join(trajectory_base_path, f))]
if not folders:
logger.warning(f"No trajectory folders found in: {trajectory_base_path}")
return None
# Sort by folder name (assuming timestamp format like 20250715_100443)
folders.sort(reverse=True)
latest_folder = folders[0]
full_path = os.path.join(trajectory_base_path, latest_folder)
logger.info(f"Found latest trajectory folder: {full_path}")
return full_path

71
core/CONTRIBUTING.md Normal file
View File

@ -0,0 +1,71 @@
# Contributing to Jan Core
[← Back to Main Contributing Guide](../CONTRIBUTING.md)
TypeScript SDK providing extension system, APIs, and type definitions for all Jan components.
## Key Directories
- **`/src/browser`** - Core APIs (events, extensions, file system)
- **`/src/browser/extensions`** - Built-in extensions (assistant, inference, conversational)
- **`/src/types`** - TypeScript type definitions
- **`/src/test`** - Testing utilities
## Development
### Key Principles
1. **Platform Agnostic** - Works everywhere (browser, Node.js)
2. **Extension-Based** - New features = new extensions
3. **Type Everything** - TypeScript required
4. **Event-Driven** - Components communicate via events
### Building & Testing
```bash
# Build the SDK
yarn build
# Run tests
yarn test
# Watch mode
yarn test:watch
```
### Event System
```typescript
// Emit events
events.emit('model:loaded', { modelId: 'llama-3' })
// Listen for events
events.on('model:loaded', (data) => {
console.log('Model loaded:', data.modelId)
})
```
## Testing
```typescript
describe('MyFeature', () => {
it('should do something', () => {
const result = doSomething()
expect(result).toBe('expected')
})
})
```
## Best Practices
- Keep it simple
- Use TypeScript fully (no `any`)
- Write tests for critical features
- Follow existing patterns
- Export new modules in index files
## Dependencies
- **TypeScript** - Type safety
- **Rolldown** - Bundling
- **Vitest** - Testing

View File

@ -8,10 +8,7 @@
```js
// Web / extension runtime
import * as core from "@janhq/core";
// Node runtime
import * as node from "@janhq/core/node";
import * as core from '@janhq/core'
```
## Build an Extension
@ -19,26 +16,27 @@ import * as node from "@janhq/core/node";
1. Download an extension template, for example, [https://github.com/janhq/extension-template](https://github.com/janhq/extension-template).
2. Update the source code:
1. Open `index.ts` in your code editor.
2. Rename the extension class from `SampleExtension` to your preferred extension name.
3. Import modules from the core package.
```ts
import * as core from "@janhq/core";
import * as core from '@janhq/core'
```
4. In the `onLoad()` method, add your code:
```ts
// Example of listening to app events and providing customized inference logic:
import * as core from "@janhq/core";
import * as core from '@janhq/core'
export default class MyExtension extends BaseExtension {
// On extension load
onLoad() {
core.events.on(MessageEvent.OnMessageSent, (data) => MyExtension.inference(data, this));
core.events.on(MessageEvent.OnMessageSent, (data) => MyExtension.inference(data, this))
}
// Customized inference logic
private static inference(incomingMessage: MessageRequestData) {
// Prepare customized message content
const content: ThreadContent = {
type: ContentType.Text,
@ -46,16 +44,17 @@ import * as node from "@janhq/core/node";
value: "I'm Jan Assistant!",
annotations: [],
},
};
}
// Modify message and send out
const outGoingMessage: ThreadMessage = {
...incomingMessage,
content
};
content,
}
}
}
```
3. Build the extension:
1. Navigate to the extension directory.
2. Install dependencies.
@ -66,4 +65,4 @@ import * as node from "@janhq/core/node";
```bash
yarn build
```
4. Select the generated .tgz from Jan > Settings > Extension > Manual Installation.
4. Select the generated .tgz from Jan > Settings > Extension > Manual Installation.

View File

@ -1,17 +0,0 @@
module.exports = {
preset: 'ts-jest',
testEnvironment: 'node',
collectCoverageFrom: ['src/**/*.{ts,tsx}'],
moduleNameMapper: {
'@/(.*)': '<rootDir>/src/$1',
},
runner: './testRunner.js',
transform: {
"^.+\\.tsx?$": [
"ts-jest",
{
diagnostics: false,
},
],
},
}

View File

@ -8,61 +8,46 @@
],
"homepage": "https://jan.ai",
"license": "AGPL-3.0",
"browser": "dist/index.js",
"main": "dist/index.js",
"module": "dist/node/index.cjs.js",
"typings": "dist/types/index.d.ts",
"files": [
"dist",
"types"
],
"author": "Jan <service@jan.ai>",
"exports": {
".": "./dist/index.js",
"./node": "./dist/node/index.cjs.js"
},
"typesVersions": {
"*": {
".": [
"./dist/index.js.map",
"./dist/types/index.d.ts"
],
"node": [
"./dist/node/index.cjs.js.map",
"./dist/types/node/index.d.ts"
]
}
},
"scripts": {
"lint": "tslint --project tsconfig.json -t codeFrame 'src/**/*.ts' 'test/**/*.ts'",
"test": "jest",
"test": "vitest run",
"test:watch": "vitest",
"test:ui": "vitest --ui",
"test:coverage": "vitest run --coverage",
"prebuild": "rimraf dist",
"build": "tsc -p . && rolldown -c rolldown.config.mjs"
},
"devDependencies": {
"@npmcli/arborist": "^7.1.0",
"@types/jest": "^29.5.14",
"@types/node": "^22.10.0",
"@types/pacote": "^11.1.7",
"@types/request": "^2.48.12",
"electron": "33.2.1",
"@types/react": "19.1.2",
"@vitest/coverage-v8": "^2.1.8",
"@vitest/ui": "^2.1.8",
"eslint": "8.57.0",
"eslint-plugin-jest": "^27.9.0",
"jest": "^29.7.0",
"jest-junit": "^16.0.0",
"jest-runner": "^29.7.0",
"happy-dom": "^20.0.0",
"pacote": "^21.0.0",
"react": "19.0.0",
"request": "^2.88.2",
"request-progress": "^3.0.0",
"rimraf": "^3.0.2",
"rimraf": "^6.0.1",
"rolldown": "1.0.0-beta.1",
"ts-jest": "^29.2.5",
"tslib": "^2.6.2",
"typescript": "^5.3.3"
"typescript": "^5.8.3",
"vitest": "^2.1.8"
},
"dependencies": {
"rxjs": "^7.8.1",
"ulidx": "^2.3.0"
},
"peerDependencies": {
"react": "19.0.0"
},
"packageManager": "yarn@4.5.3"
}

View File

@ -10,42 +10,10 @@ export default defineConfig([
sourcemap: true,
},
platform: 'browser',
external: ['path'],
external: ['path', 'react', 'react-dom', 'react/jsx-runtime'],
define: {
NODE: JSON.stringify(`${pkgJson.name}/${pkgJson.node}`),
VERSION: JSON.stringify(pkgJson.version),
},
},
{
input: 'src/node/index.ts',
external: [
'fs/promises',
'path',
'pacote',
'@types/pacote',
'@npmcli/arborist',
'ulidx',
'node-fetch',
'fs',
'request',
'crypto',
'url',
'http',
'os',
'util',
'child_process',
'electron',
'request-progress',
],
output: {
format: 'cjs',
file: 'dist/node/index.cjs.js',
sourcemap: true,
inlineDynamicImports: true,
},
resolve: {
extensions: ['.js', '.ts'],
},
platform: 'node',
},
}
])

View File

@ -1,8 +1,8 @@
import { describe, it, expect, vi } from 'vitest'
import { openExternalUrl } from './core'
import { joinPath } from './core'
import { openFileExplorer } from './core'
import { getJanDataFolderPath } from './core'
import { abortDownload } from './core'
import { executeOnMain } from './core'
describe('test core apis', () => {
@ -10,7 +10,7 @@ describe('test core apis', () => {
const url = 'http://example.com'
globalThis.core = {
api: {
openExternalUrl: jest.fn().mockResolvedValue('opened'),
openExternalUrl: vi.fn().mockResolvedValue('opened'),
},
}
const result = await openExternalUrl(url)
@ -22,11 +22,11 @@ describe('test core apis', () => {
const paths = ['/path/one', '/path/two']
globalThis.core = {
api: {
joinPath: jest.fn().mockResolvedValue('/path/one/path/two'),
joinPath: vi.fn().mockResolvedValue('/path/one/path/two'),
},
}
const result = await joinPath(paths)
expect(globalThis.core.api.joinPath).toHaveBeenCalledWith(paths)
expect(globalThis.core.api.joinPath).toHaveBeenCalledWith({ args: paths })
expect(result).toBe('/path/one/path/two')
})
@ -34,55 +34,29 @@ describe('test core apis', () => {
const path = '/path/to/open'
globalThis.core = {
api: {
openFileExplorer: jest.fn().mockResolvedValue('opened'),
openFileExplorer: vi.fn().mockResolvedValue('opened'),
},
}
const result = await openFileExplorer(path)
expect(globalThis.core.api.openFileExplorer).toHaveBeenCalledWith(path)
expect(globalThis.core.api.openFileExplorer).toHaveBeenCalledWith({ path })
expect(result).toBe('opened')
})
it('should get jan data folder path', async () => {
globalThis.core = {
api: {
getJanDataFolderPath: jest.fn().mockResolvedValue('/path/to/jan/data'),
getJanDataFolderPath: vi.fn().mockResolvedValue('/path/to/jan/data'),
},
}
const result = await getJanDataFolderPath()
expect(globalThis.core.api.getJanDataFolderPath).toHaveBeenCalled()
expect(result).toBe('/path/to/jan/data')
})
it('should abort download', async () => {
const fileName = 'testFile'
globalThis.core = {
api: {
abortDownload: jest.fn().mockResolvedValue('aborted'),
},
}
const result = await abortDownload(fileName)
expect(globalThis.core.api.abortDownload).toHaveBeenCalledWith(fileName)
expect(result).toBe('aborted')
})
it('should execute function on main process', async () => {
const extension = 'testExtension'
const method = 'testMethod'
const args = ['arg1', 'arg2']
globalThis.core = {
api: {
invokeExtensionFunc: jest.fn().mockResolvedValue('result'),
},
}
const result = await executeOnMain(extension, method, ...args)
expect(globalThis.core.api.invokeExtensionFunc).toHaveBeenCalledWith(extension, method, ...args)
expect(result).toBe('result')
})
})
describe('dirName - just a pass thru api', () => {
it('should retrieve the directory name from a file path', async () => {
const mockDirName = jest.fn()
const mockDirName = vi.fn()
globalThis.core = {
api: {
dirName: mockDirName.mockResolvedValue('/path/to'),

View File

@ -1,55 +1,11 @@
import {
DownloadRequest,
FileStat,
NetworkConfig,
SystemInformation,
} from '../types'
/**
* Execute a extension module function in main process
*
* @param extension extension name to import
* @param method function name to execute
* @param args arguments to pass to the function
* @returns Promise<any>
*
*/
const executeOnMain: (
extension: string,
method: string,
...args: any[]
) => Promise<any> = (extension, method, ...args) =>
globalThis.core?.api?.invokeExtensionFunc(extension, method, ...args)
/**
* Downloads a file from a URL and saves it to the local file system.
*
* @param {DownloadRequest} downloadRequest - The request to download the file.
* @param {NetworkConfig} network - Optional object to specify proxy/whether to ignore SSL certificates.
*
* @returns {Promise<any>} A promise that resolves when the file is downloaded.
*/
const downloadFile: (
downloadRequest: DownloadRequest,
network?: NetworkConfig
) => Promise<any> = (downloadRequest, network) =>
globalThis.core?.api?.downloadFile(downloadRequest, network)
/**
* Aborts the download of a specific file.
* @param {string} fileName - The name of the file whose download is to be aborted.
* @returns {Promise<any>} A promise that resolves when the download has been aborted.
*/
const abortDownload: (fileName: string) => Promise<any> = (fileName) =>
globalThis.core.api?.abortDownload(fileName)
import { SystemInformation } from '../types'
/**
* Gets Jan's data folder path.
*
* @returns {Promise<string>} A Promise that resolves with Jan's data folder path.
*/
const getJanDataFolderPath = (): Promise<string> =>
globalThis.core.api?.getJanDataFolderPath()
const getJanDataFolderPath = (): Promise<string> => globalThis.core.api?.getJanDataFolderPath()
/**
* Opens the file explorer at a specific path.
@ -57,31 +13,29 @@ const getJanDataFolderPath = (): Promise<string> =>
* @returns {Promise<any>} A promise that resolves when the file explorer is opened.
*/
const openFileExplorer: (path: string) => Promise<any> = (path) =>
globalThis.core.api?.openFileExplorer(path)
globalThis.core.api?.openFileExplorer({ path })
/**
* Joins multiple paths together.
* @param paths - The paths to join.
* @returns {Promise<string>} A promise that resolves with the joined path.
*/
const joinPath: (paths: string[]) => Promise<string> = (paths) =>
globalThis.core.api?.joinPath(paths)
const joinPath: (args: string[]) => Promise<string> = (args) =>
globalThis.core.api?.joinPath({ args })
/**
* Get dirname of a file path.
* @param path - The file path to retrieve dirname.
* @returns {Promise<string>} A promise that resolves the dirname.
*/
const dirName: (path: string) => Promise<string> = (path) =>
globalThis.core.api?.dirName(path)
const dirName: (path: string) => Promise<string> = (path) => globalThis.core.api?.dirName(path)
/**
* Retrieve the basename from an url.
* @param path - The path to retrieve.
* @returns {Promise<string>} A promise that resolves with the basename.
*/
const baseName: (paths: string) => Promise<string> = (path) =>
globalThis.core.api?.baseName(path)
const baseName: (paths: string) => Promise<string> = (path) => globalThis.core.api?.baseName(path)
/**
* Opens an external URL in the default web browser.
@ -97,15 +51,13 @@ const openExternalUrl: (url: string) => Promise<any> = (url) =>
*
* @returns {Promise<string>} - A promise that resolves with the resource path.
*/
const getResourcePath: () => Promise<string> = () =>
globalThis.core.api?.getResourcePath()
const getResourcePath: () => Promise<string> = () => globalThis.core.api?.getResourcePath()
/**
* Gets the user's home path.
* @returns return user's home path
*/
const getUserHomePath = (): Promise<string> =>
globalThis.core.api?.getUserHomePath()
const getUserHomePath = (): Promise<string> => globalThis.core.api?.getUserHomePath()
/**
* Log to file from browser processes.
@ -123,17 +75,8 @@ const log: (message: string, fileName?: string) => void = (message, fileName) =>
*
* @returns {Promise<boolean>} - A promise that resolves with a boolean indicating whether the path is a subdirectory.
*/
const isSubdirectory: (from: string, to: string) => Promise<boolean> = (
from: string,
to: string
) => globalThis.core.api?.isSubdirectory(from, to)
/**
* Get system information
* @returns {Promise<any>} - A promise that resolves with the system information.
*/
const systemInformation: () => Promise<SystemInformation> = () =>
globalThis.core.api?.systemInformation()
const isSubdirectory: (from: string, to: string) => Promise<boolean> = (from: string, to: string) =>
globalThis.core.api?.isSubdirectory(from, to)
/**
* Show toast message from browser processes.
@ -158,9 +101,6 @@ export type RegisterExtensionPoint = (
* Functions exports
*/
export {
executeOnMain,
downloadFile,
abortDownload,
getJanDataFolderPath,
openFileExplorer,
getResourcePath,
@ -170,7 +110,6 @@ export {
log,
isSubdirectory,
getUserHomePath,
systemInformation,
showToast,
dirName,
}

View File

@ -1,11 +1,11 @@
import { it, expect, vi } from 'vitest'
import { events } from './events';
import { jest } from '@jest/globals';
it('should emit an event', () => {
const mockObject = { key: 'value' };
globalThis.core = {
events: {
emit: jest.fn()
emit: vi.fn()
}
};
events.emit('testEvent', mockObject);
@ -14,10 +14,10 @@ it('should emit an event', () => {
it('should remove an observer for an event', () => {
const mockHandler = jest.fn();
const mockHandler = vi.fn();
globalThis.core = {
events: {
off: jest.fn()
off: vi.fn()
}
};
events.off('testEvent', mockHandler);
@ -26,10 +26,10 @@ it('should remove an observer for an event', () => {
it('should add an observer for an event', () => {
const mockHandler = jest.fn();
const mockHandler = vi.fn();
globalThis.core = {
events: {
on: jest.fn()
on: vi.fn()
}
};
events.on('testEvent', mockHandler);

Some files were not shown because too many files have changed in this diff Show More