-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
executable file
·142 lines (128 loc) · 4.71 KB
/
docker-compose.yml
File metadata and controls
executable file
·142 lines (128 loc) · 4.71 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
services:
just-chat-agents:
container_name: just-chat-agents
# image: ghcr.io/longevity-genie/just-agents/chat-ui-agents:main
image: ghcr.io/longevity-genie/just-semantic-search/rag-server:main
environment:
# Web server configuration
APP_HOST: "0.0.0.0" # app host inside container, 0's to expose
APP_PORT: "8091" # app port inside container
# Agent core configuration
AGENT_TITLE: "Chat AGENTS REST API node"
AGENT_WORKERS: "1"
AGENT_SECTION: "" # for one agent
AGENT_PARENT_SECTION: "agent_profiles"
AGENT_FAILFAST: "true" # fail fast on startup in case of profile errors or just drop bad profiles
AGENT_DEBUG: "true"
AGENT_CONFIG_PATH: "/app/chat_agent_profiles.yaml"
# Agent connectivity for chat UI
AGENT_HOST: "http://just-chat-agents" # agent host for chat to access
AGENT_PORT: "8091" # agent port for chat to access
# Directory configuration
APP_DIR: "/app"
TMP_DIR: "tmp"
LOG_DIR: "logs"
DATA_DIR: "data"
MODELS_DIR: "/app/models.d" # used by chat-ui to get models
# Environment files
ENV_KEYS_PATH: "/app/env/.env.keys" # used by agents to get keys
ENV_MODELS_PATH: "/app/env/.env.local" # used by chat-ui to get models
# Additional configuration options
TRAP_CHAT_NAMES: "true" #re-route naming to dedicated agent or use default (first in list) agent intead for this purpose
# User/group configuration
USER_ID: ${USER_ID:-${UID}}
GROUP_ID: ${GROUP_ID:-${GID}}
# Meilisearch configuration
MEILI_MASTER_KEY: "fancy_master_key"
MEILISEARCH_HOST: "meilisearch"
MEILISEARCH_PORT: 7700
MEILISEARCH_SEMANTIC_RATIO: 0.5
# RAG configuration
EMBEDDING_MODEL: "jinaai/jina-embeddings-v3"
INDEX_CHARACTERS_FOR_ABSTRACT: 100000
INDEX_MAX_SEQ_LENGTH: 36000
ports:
- "127.0.0.1:8091:8091"
#entrypoint: [ "/usr/local/bin/entrypoint.sh" ]
healthcheck:
test: ["CMD-SHELL", "curl -s 0.0.0.0:8091/docs | grep 'Swagger' && test -f ./env/.env.local"]
interval: 15s
retries: 10
start_period: 15s
timeout: 1s
volumes:
# - "./scripts/replacement_entrypoint.sh:/usr/local/bin/entrypoint.sh"
- "./scripts/init_env.py:/app/init.py:Z"
- "./data:/app/data:z"
- "./env:/app/env:z"
- "./logs:/app/logs:z"
- "./scripts:/app/scripts:z"
- "./agent_tools:/app/agent_tools:Z"
- "./chat_agent_profiles.yaml:/app/chat_agent_profiles.yaml:Z"
restart: on-failure:3
#command: ["python", "-m", "just_agents.web.run_agent", "run-chat-ui-server-command"]
command: "python -m just_semantic_search.server.run_rag_server --workers 1 --agent-profiles /app/chat_agent_profiles.yaml"
huggingchat-ui:
container_name: chat-ui
image: ghcr.io/longevity-genie/chat-ui/chat-ui:latest
# image: ghcr.io/longevity-genie/chat-ui/chat-ui:sha-6b47a62
environment:
ALLOW_INSECURE_COOKIES: "true"
INCLUDE_DB: "False"
volumes:
- "./env/.env.local:/app/.env.local:z"
ports:
- "0.0.0.0:3000:3000"
depends_on:
just-chat-agents:
condition: service_healthy
chat-mongo:
condition: service_started
restart: unless-stopped
chat-mongo:
container_name: just-chat-mongodb-for-agents
image: docker.io/library/mongo:latest
restart: always
env_file:
- ./env/.env.mongo
ports:
- "27017"
volumes:
- "mongo-data:/data/db"
# - "./volumes/mongo/db:/data/db"
depends_on:
just-chat-agents:
condition: service_healthy
meilisearch:
image: docker.io/getmeili/meilisearch:v1.26.0
environment:
- MEILI_MASTER_KEY=fancy_master_key
- MEILI_NO_ANALYTICS=true
- MEILI_ENV=development
- MEILI_LOG_LEVEL=debug
- MEILI_DB_PATH=/data.ms
- MEILI_EXPERIMENTAL_ENABLE_METRICS=true
- MEILI_EXPERIMENTAL_ENABLE_VECTORS=true
- MEILI_EXPERIMENTAL_DUMPLESS_UPGRADE=true
- MEILI_IGNORE_DUMP_IF_DB_EXISTS=true
- MEILI_IGNORE_MISSING_DUMP=true
- MEILI_DUMP_DIR=/dumps
# User/group configuration
- USER_ID=${USER_ID:-${UID}}
- GROUP_ID=${GROUP_ID:-${GID}}
ports:
- 7700:7700
#cap_add: # uncomment this section if you experience permissions issues in podman
# - DAC_OVERRIDE
volumes:
# Using anonymous volume - use 'USER_ID=$(id -u) GROUP_ID=$(id -g) docker compose up -V' to reset only MeiliSearch DB
- meili-data:/data.ms
- "./dumps:/dumps:z"
restart: unless-stopped
command: "meilisearch --import-dump /dumps/just_chat_rag.dump"
volumes:
mongo-data:
meili-data:
networks:
default:
name: chat-server-for-agents