You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jul 4, 2025. It is now read-only.
> ⚠️ **Cortex is currently in Development**: Expect breaking changes and bugs!
9
+
10
+
## About
11
+
Cortex is an openAI-compatible local AI server that developers can use to build LLM apps. It is packaged with a Docker-inspired command-line interface and a Typescript client library. It can be used as a standalone server, or imported as a library.
12
+
13
+
Cortex currently supports two inference engines:
14
+
15
+
- Llama.cpp
16
+
- TensorRT-LLM
17
+
18
+
> Read more about Cortex at https://jan.ai/cortex
19
+
20
+
### Repo Structure
21
+
```
22
+
# Entity Definitions
23
+
domain/ # This is the core directory where the domains are defined.
24
+
abstracts/ # Abstract base classes for common attributes and methods.
25
+
models/ # Domain interface definitions, e.g. model, assistant.
@@ -10,10 +76,9 @@ Before installation, ensure that you have installed the following:
10
76
-**NPM**: Needed to manage packages.
11
77
-**CPU Instruction Sets**: Available for download from the [Cortex GitHub Releases](https://github.com/janhq/cortex/releases) page.
12
78
13
-
<aside>
14
-
💡 The **CPU instruction sets** are not required for the initial installation of Cortex. This dependency will be automatically installed during the Cortex initialization if they are not already on your system.
15
79
16
-
</aside>
80
+
>💡 The **CPU instruction sets** are not required for the initial installation of Cortex. This dependency will be automatically installed during the Cortex initialization if they are not already on your system.
81
+
17
82
18
83
### **Hardware**
19
84
@@ -35,88 +100,34 @@ Ensure that your system meets the following requirements to run Cortex:
35
100
36
101
-**Disk**: At least 10GB for app and model download.
37
102
38
-
## Cortex Installation
39
-
40
-
To install Cortex, follow the steps below:
41
-
42
-
### Step 1: Install Cortex
43
-
44
-
Run the following command to install Cortex globally on your machine:
45
-
46
-
```bash
47
-
# Install using NPM globally
103
+
## Quickstart
104
+
1. Install the NPM package:
105
+
```bash
48
106
npm i -g @janhq/cortex
49
107
```
50
108
51
-
### Step 2: Verify the Installation
52
-
53
-
After installation, you can verify that Cortex is installed correctly by getting help information.
54
-
55
-
```bash
56
-
# Get the help information
57
-
cortex -h
58
-
```
59
-
60
-
### Step 3: Initialize Cortex
61
-
62
-
Once verified, you need to initialize the Cortex engine.
63
-
64
-
1. Initialize the Cortex engine:
65
-
66
-
```
109
+
2. Initialize a compatible engine:
110
+
```bash
67
111
cortex init
68
112
```
69
113
70
-
1. Select between `CPU` and `GPU` modes.
71
-
72
-
```bash
73
-
? Select run mode (Use arrow keys)
74
-
> CPU
75
-
GPU
76
-
```
77
-
78
-
2. Select between GPU types.
79
-
80
-
```bash
81
-
? Select GPU types (Use arrow keys)
82
-
> Nvidia
83
-
Others (Vulkan)
84
-
```
85
-
86
-
3. Select CPU instructions (will be deprecated soon).
1. Cortex will download the required CPU instruction sets if you choose `CPU` mode. If you choose `GPU` mode, Cortex will download the necessary dependencies to use your GPU.
0 commit comments