Skip to content

Commit c5ac928

Browse files
committed
Merge branch 'master' into feat/agent_mode_in_embed_chats_4
2 parents 328611e + 6270a0a commit c5ac928

File tree

150 files changed

+6287
-1952
lines changed

Some content is hidden

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

150 files changed

+6287
-1952
lines changed

.github/workflows/dev-build.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ concurrency:
66

77
on:
88
push:
9-
branches: ['3999-chromium-flags'] # put your current branch to create a build. Core team only.
9+
branches: ['gemini-migration-agents'] # put your current branch to create a build. Core team only.
1010
paths-ignore:
1111
- '**.md'
1212
- 'cloud-deployments/*'

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,9 @@ AnythingLLM divides your documents into objects called `workspaces`. A Workspace
102102
- [Novita AI (chat models)](https://novita.ai/model-api/product/llm-api?utm_source=github_anything-llm&utm_medium=github_readme&utm_campaign=link)
103103
- [PPIO](https://ppinfra.com?utm_source=github_anything-llm)
104104
- [Moonshot AI](https://www.moonshot.ai/)
105+
- [Microsoft Foundry Local](https://github.com/microsoft/Foundry-Local)
105106
- [CometAPI (chat models)](https://api.cometapi.com/)
107+
106108
**Embedder models:**
107109

108110
- [AnythingLLM Native Embedder](/server/storage/models/README.md) (default)
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# Patterns to ignore when building packages.
2+
# This supports shell glob matching, relative path matching, and
3+
# negation (prefixed with !). Only one pattern per line.
4+
.DS_Store
5+
# Common VCS dirs
6+
.git/
7+
.gitignore
8+
.bzr/
9+
.bzrignore
10+
.hg/
11+
.hgignore
12+
.svn/
13+
# Common backup files
14+
*.swp
15+
*.bak
16+
*.tmp
17+
*.orig
18+
*~
19+
# Various IDEs
20+
.project
21+
.idea/
22+
*.tmproj
23+
.vscode/
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
apiVersion: v2
2+
name: anythingllm
3+
description: The all-in-one Desktop & Docker AI application with built-in RAG, AI agents, No-code agent builder, MCP compatibility, and more.
4+
type: application
5+
version: 1.0.0
6+
appVersion: "1.85.0"
7+
icon: https://raw.githubusercontent.com/Mintplex-Labs/anything-llm/refs/heads/master/frontend/public/favicon.png
Lines changed: 149 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,149 @@
1+
# anythingllm
2+
3+
![Version: 1.0.0](https://img.shields.io/badge/Version-1.0.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 1.85.0](https://img.shields.io/badge/AppVersion-1.85.0-informational?style=flat-square)
4+
5+
![AnythingLLM](https://raw.githubusercontent.com/Mintplex-Labs/anything-llm/master/images/wordmark.png)
6+
7+
[AnythingLLM](https://github.com/Mintplex-Labs/anything-llm)
8+
9+
The all-in-one Desktop & Docker AI application with built-in RAG, AI agents, No-code agent builder, MCP compatibility, and more.
10+
11+
**Configuration & Usage**
12+
13+
- **Config vs Secrets:** This chart exposes application configuration via two mechanisms:
14+
- `config` (in `values.yaml`) — rendered into a `ConfigMap` and injected using `envFrom` in the pod. Do NOT place sensitive values (API keys, secrets) in `config` because `ConfigMap`s are not encrypted.
15+
- `env` / `envFrom` — the preferred way to inject secrets. Use Kubernetes `Secret` objects and reference them from `env` (with `valueFrom.secretKeyRef`) or `envFrom.secretRef`.
16+
17+
- **Storage & STORAGE_DIR mapping:** The chart creates (or mounts) a `PersistentVolumeClaim` using the `persistentVolume.*` settings. The container mount path is set from `persistentVolume.mountPath`. Ensure the container `STORAGE_DIR` config key matches that path (defaults are set in `values.yaml`).
18+
19+
**Providing API keys & secrets (recommended)**
20+
21+
Use Kubernetes Secrets. Below are example workflows and `values.yaml` snippets.
22+
23+
1) Create a Kubernetes Secret with API keys:
24+
25+
```
26+
kubectl create secret generic openai-secret --from-literal=OPENAI_KEY="sk-..."
27+
# or from a file
28+
# kubectl create secret generic openai-secret --from-file=OPENAI_KEY=/path/to/keyfile
29+
```
30+
31+
2) Reference the Secret from `values.yaml` using `envFrom` (recommended when your secret contains multiple env keys):
32+
33+
```yaml
34+
envFrom:
35+
- secretRef:
36+
name: openai-secret
37+
```
38+
39+
This will inject all key/value pairs from the `openai-secret` Secret as environment variables in the container.
40+
41+
3) Or reference a single secret key via `env` (explicit mapping):
42+
43+
```yaml
44+
env:
45+
- name: OPENAI_KEY
46+
valueFrom:
47+
secretKeyRef:
48+
name: openai-secret
49+
key: OPENAI_KEY
50+
```
51+
52+
Notes:
53+
- Avoid placing secret values into `config:` (the chart's `ConfigMap`) — `ConfigMap`s are visible to anyone who can read the namespace. Use `Secret` objects for any credentials/tokens.
54+
- If you use a GitOps workflow, consider integrating an external secret operator (ExternalSecrets, SealedSecrets, etc.) so you don't store raw secrets in Git.
55+
56+
**Example `values-secret.yaml` to pass during `helm install`**
57+
58+
```yaml
59+
image:
60+
repository: mintplexlabs/anythingllm
61+
tag: "1.9.0"
62+
63+
service:
64+
type: ClusterIP
65+
port: 3001
66+
67+
# Reference secret containing API keys
68+
envFrom:
69+
- secretRef:
70+
name: openai-secret
71+
72+
# Optionally override other values
73+
persistentVolume:
74+
size: 16Gi
75+
mountPath: /storage
76+
```
77+
78+
Install with:
79+
80+
```
81+
helm install my-anythingllm ./anythingllm -f values-secret.yaml
82+
```
83+
84+
**Best practices & tips**
85+
86+
- Use `envFrom` for convenience when many environment variables are stored in a single `Secret` and use `env`/`valueFrom` for explicit single-key mappings.
87+
- Use `kubectl create secret generic` or your secrets management solution. If you need to reference multiple different provider keys (OpenAI, Anthropic, etc.), create a single `Secret` with multiple keys or multiple Secrets and add multiple `envFrom` entries.
88+
- Keep probe paths and `service.port` aligned. If your probes fail after deployment, check that the probe `port` matches the container port (or named port `http`) and that the `path` is valid.
89+
- For storage, if you have a pre-existing PVC set `persistentVolume.existingClaim` to the PVC name; the chart will mount that claim (and will not attempt to create a new PVC).
90+
- For production, provide resource `requests` and `limits` in `values.yaml` to prevent scheduler starvation and to control cost.
91+
92+
## Values
93+
94+
| Key | Type | Default | Description |
95+
|-----|------|---------|-------------|
96+
| affinity | object | `{}` | |
97+
| config.DISABLE_TELEMETRY | string | `"true"` | |
98+
| config.GID | string | `"1000"` | |
99+
| config.NODE_ENV | string | `"production"` | |
100+
| config.STORAGE_DIR | string | `"/storage"` | |
101+
| config.UID | string | `"1000"` | |
102+
| env | object | `{}` | |
103+
| envFrom | object | `{}` | |
104+
| fullnameOverride | string | `""` | |
105+
| image.pullPolicy | string | `"IfNotPresent"` | |
106+
| image.repository | string | `"mintplexlabs/anythingllm"` | |
107+
| image.tag | string | `"1.9.0"` | |
108+
| imagePullSecrets | list | `[]` | |
109+
| ingress.annotations | object | `{}` | |
110+
| ingress.className | string | `""` | |
111+
| ingress.enabled | bool | `false` | |
112+
| ingress.hosts[0].host | string | `"chart-example.local"` | |
113+
| ingress.hosts[0].paths[0].path | string | `"/"` | |
114+
| ingress.hosts[0].paths[0].pathType | string | `"ImplementationSpecific"` | |
115+
| ingress.tls | list | `[]` | |
116+
| initContainers | list | `[]` | |
117+
| livenessProbe.failureThreshold | int | `3` | |
118+
| livenessProbe.httpGet.path | string | `"/v1/api/health"` | |
119+
| livenessProbe.httpGet.port | int | `8888` | |
120+
| livenessProbe.initialDelaySeconds | int | `15` | |
121+
| livenessProbe.periodSeconds | int | `5` | |
122+
| nameOverride | string | `""` | |
123+
| nodeSelector | object | `{}` | |
124+
| persistentVolume.accessModes[0] | string | `"ReadWriteOnce"` | |
125+
| persistentVolume.annotations | object | `{}` | |
126+
| persistentVolume.existingClaim | string | `""` | |
127+
| persistentVolume.labels | object | `{}` | |
128+
| persistentVolume.mountPath | string | `"/storage"` | |
129+
| persistentVolume.size | string | `"8Gi"` | |
130+
| podAnnotations | object | `{}` | |
131+
| podLabels | object | `{}` | |
132+
| podSecurityContext.fsGroup | int | `1000` | |
133+
| readinessProbe.httpGet.path | string | `"/v1/api/health"` | |
134+
| readinessProbe.httpGet.port | int | `8888` | |
135+
| readinessProbe.initialDelaySeconds | int | `15` | |
136+
| readinessProbe.periodSeconds | int | `5` | |
137+
| readinessProbe.successThreshold | int | `2` | |
138+
| replicaCount | int | `1` | |
139+
| resources | object | `{}` | |
140+
| securityContext | object | `{}` | |
141+
| service.port | int | `3001` | |
142+
| service.type | string | `"ClusterIP"` | |
143+
| serviceAccount.annotations | object | `{}` | |
144+
| serviceAccount.automount | bool | `true` | |
145+
| serviceAccount.create | bool | `true` | |
146+
| serviceAccount.name | string | `""` | |
147+
| tolerations | list | `[]` | |
148+
| volumeMounts | list | `[]` | |
149+
| volumes | list | `[]` | |
Lines changed: 103 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,103 @@
1+
{{ template "chart.header" . }}
2+
{{ template "chart.deprecationWarning" . }}
3+
4+
{{ template "chart.badgesSection" . }}
5+
6+
![AnythingLLM](https://raw.githubusercontent.com/Mintplex-Labs/anything-llm/master/images/wordmark.png)
7+
8+
[AnythingLLM](https://github.com/Mintplex-Labs/anything-llm)
9+
10+
{{ template "chart.description" . }}
11+
12+
{{ template "chart.homepageLine" . }}
13+
14+
{{ template "chart.maintainersSection" . }}
15+
16+
{{ template "chart.sourcesSection" . }}
17+
18+
{{ template "chart.requirementsSection" . }}
19+
20+
**Configuration & Usage**
21+
22+
- **Config vs Secrets:** This chart exposes application configuration via two mechanisms:
23+
- `config` (in `values.yaml`) — rendered into a `ConfigMap` and injected using `envFrom` in the pod. Do NOT place sensitive values (API keys, secrets) in `config` because `ConfigMap`s are not encrypted.
24+
- `env` / `envFrom` — the preferred way to inject secrets. Use Kubernetes `Secret` objects and reference them from `env` (with `valueFrom.secretKeyRef`) or `envFrom.secretRef`.
25+
26+
- **Storage & STORAGE_DIR mapping:** The chart creates (or mounts) a `PersistentVolumeClaim` using the `persistentVolume.*` settings. The container mount path is set from `persistentVolume.mountPath`. Ensure the container `STORAGE_DIR` config key matches that path (defaults are set in `values.yaml`).
27+
28+
29+
**Providing API keys & secrets (recommended)**
30+
31+
Use Kubernetes Secrets. Below are example workflows and `values.yaml` snippets.
32+
33+
1) Create a Kubernetes Secret with API keys:
34+
35+
```
36+
kubectl create secret generic openai-secret --from-literal=OPENAI_KEY="sk-..."
37+
# or from a file
38+
# kubectl create secret generic openai-secret --from-file=OPENAI_KEY=/path/to/keyfile
39+
```
40+
41+
2) Reference the Secret from `values.yaml` using `envFrom` (recommended when your secret contains multiple env keys):
42+
43+
```yaml
44+
envFrom:
45+
- secretRef:
46+
name: openai-secret
47+
```
48+
49+
This will inject all key/value pairs from the `openai-secret` Secret as environment variables in the container.
50+
51+
3) Or reference a single secret key via `env` (explicit mapping):
52+
53+
```yaml
54+
env:
55+
- name: OPENAI_KEY
56+
valueFrom:
57+
secretKeyRef:
58+
name: openai-secret
59+
key: OPENAI_KEY
60+
```
61+
62+
Notes:
63+
- Avoid placing secret values into `config:` (the chart's `ConfigMap`) — `ConfigMap`s are visible to anyone who can read the namespace. Use `Secret` objects for any credentials/tokens.
64+
- If you use a GitOps workflow, consider integrating an external secret operator (ExternalSecrets, SealedSecrets, etc.) so you don't store raw secrets in Git.
65+
66+
67+
**Example `values-secret.yaml` to pass during `helm install`**
68+
69+
```yaml
70+
image:
71+
repository: mintplexlabs/anythingllm
72+
tag: "1.9.0"
73+
74+
service:
75+
type: ClusterIP
76+
port: 3001
77+
78+
# Reference secret containing API keys
79+
envFrom:
80+
- secretRef:
81+
name: openai-secret
82+
83+
# Optionally override other values
84+
persistentVolume:
85+
size: 16Gi
86+
mountPath: /storage
87+
```
88+
89+
Install with:
90+
91+
```
92+
helm install my-anythingllm ./anythingllm -f values-secret.yaml
93+
```
94+
95+
**Best practices & tips**
96+
97+
- Use `envFrom` for convenience when many environment variables are stored in a single `Secret` and use `env`/`valueFrom` for explicit single-key mappings.
98+
- Use `kubectl create secret generic` or your secrets management solution. If you need to reference multiple different provider keys (OpenAI, Anthropic, etc.), create a single `Secret` with multiple keys or multiple Secrets and add multiple `envFrom` entries.
99+
- Keep probe paths and `service.port` aligned. If your probes fail after deployment, check that the probe `port` matches the container port (or named port `http`) and that the `path` is valid.
100+
- For storage, if you have a pre-existing PVC set `persistentVolume.existingClaim` to the PVC name; the chart will mount that claim (and will not attempt to create a new PVC).
101+
- For production, provide resource `requests` and `limits` in `values.yaml` to prevent scheduler starvation and to control cost.
102+
103+
{{ template "chart.valuesSection" . }}
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
1. Get the application URL by running these commands:
2+
3+
{{- if .Values.ingress.enabled }}
4+
{{- range $host := .Values.ingress.hosts }}
5+
{{- range .paths }}
6+
http{{ if $.Values.ingress.tls }}s{{ end }}://{{ $host.host }}{{ .path }}
7+
{{- end }}
8+
{{- end }}
9+
10+
{{- else if contains "NodePort" .Values.service.type }}
11+
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "anythingllm.fullname" . }})
12+
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
13+
echo http://$NODE_IP:$NODE_PORT
14+
15+
{{- else if contains "LoadBalancer" .Values.service.type }}
16+
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
17+
You can watch its status by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "anythingllm.fullname" . }}'
18+
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "anythingllm.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
19+
echo http://$SERVICE_IP:{{ .Values.service.port }}
20+
21+
{{- else if contains "ClusterIP" .Values.service.type }}
22+
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "anythingllm.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
23+
export CONTAINER_PORT=$(kubectl get pod --namespace {{ .Release.Namespace }} $POD_NAME -o jsonpath="{.spec.containers[0].ports[0].containerPort}")
24+
echo "To access locally, run:"
25+
echo " kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:$CONTAINER_PORT"
26+
echo "Then visit http://127.0.0.1:8080"
27+
28+
{{- end }}
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
{{/*
2+
Expand the name of the chart.
3+
*/}}
4+
{{- define "anythingllm.name" -}}
5+
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
6+
{{- end }}
7+
8+
{{/*
9+
Create a default fully qualified app name.
10+
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
11+
If release name contains chart name it will be used as a full name.
12+
*/}}
13+
{{- define "anythingllm.fullname" -}}
14+
{{- if .Values.fullnameOverride }}
15+
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
16+
{{- else }}
17+
{{- $name := default .Chart.Name .Values.nameOverride }}
18+
{{- if contains $name .Release.Name }}
19+
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
20+
{{- else }}
21+
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
22+
{{- end }}
23+
{{- end }}
24+
{{- end }}
25+
26+
{{/*
27+
Create chart name and version as used by the chart label.
28+
*/}}
29+
{{- define "anythingllm.chart" -}}
30+
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
31+
{{- end }}
32+
33+
{{/*
34+
Common labels
35+
*/}}
36+
{{- define "anythingllm.labels" -}}
37+
helm.sh/chart: {{ include "anythingllm.chart" . }}
38+
{{ include "anythingllm.selectorLabels" . }}
39+
{{- if .Chart.AppVersion }}
40+
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
41+
{{- end }}
42+
app.kubernetes.io/managed-by: {{ .Release.Service }}
43+
{{- end }}
44+
45+
{{/*
46+
Selector labels
47+
*/}}
48+
{{- define "anythingllm.selectorLabels" -}}
49+
app.kubernetes.io/name: {{ include "anythingllm.name" . }}
50+
app.kubernetes.io/instance: {{ .Release.Name }}
51+
{{- end }}
52+
53+
{{/*
54+
Create the name of the service account to use
55+
*/}}
56+
{{- define "anythingllm.serviceAccountName" -}}
57+
{{- if .Values.serviceAccount.create }}
58+
{{- default (include "anythingllm.fullname" .) .Values.serviceAccount.name }}
59+
{{- else }}
60+
{{- default "default" .Values.serviceAccount.name }}
61+
{{- end }}
62+
{{- end }}

0 commit comments

Comments
 (0)