Update environment variables, Docker configuration, and dependencies; refactor token management and chat agent logic. Added FastAPI server setup and improved message handling in GigaChat client.

This commit is contained in:
12 changed files with 348 additions and 50 deletions

View File

@@ -1,14 +1,15 @@
version: '3.8'
services:
ai-agents:
ports:
- "8001:8000"
build:
context: .
dockerfile: Dockerfile
container_name: new-planet-ai-agents
environment:
- REDIS_URL=redis://redis:6379/0
- REDIS_URL=redis://newplanet-redis:6379/0
- GIGACHAT_CLIENT_ID=${GIGACHAT_CLIENT_ID}
- GIGACHAT_CLIENT_SECRET=${GIGACHAT_CLIENT_SECRET}
- PYTHONUNBUFFERED=1
@@ -20,13 +21,12 @@ services:
- ./services:/app/services
- ./prompts:/app/prompts
- ./scripts:/app/scripts
- ./app.py:/app/app.py
networks:
- new-planet-network
# По умолчанию запускается Python REPL для интерактивного использования
# Можно переопределить через docker-compose run или command
stdin_open: true
tty: true
# Запуск FastAPI сервера
command: uvicorn app:app --host 0.0.0.0 --port 8000
networks:
new-planet-network:
external: true
external: true