Files
project-lyra/docker-compose.yml
serversdwn 64429b19e6 feat: Implement Trillium notes executor for searching and creating notes via ETAPI
- Added `trillium.py` for searching and creating notes with Trillium's ETAPI.
- Implemented `search_notes` and `create_note` functions with appropriate error handling and validation.

feat: Add web search functionality using DuckDuckGo

- Introduced `web_search.py` for performing web searches without API keys.
- Implemented `search_web` function with result handling and validation.

feat: Create provider-agnostic function caller for iterative tool calling

- Developed `function_caller.py` to manage LLM interactions with tools.
- Implemented iterative calling logic with error handling and tool execution.

feat: Establish a tool registry for managing available tools

- Created `registry.py` to define and manage tool availability and execution.
- Integrated feature flags for enabling/disabling tools based on environment variables.

feat: Implement event streaming for tool calling processes

- Added `stream_events.py` to manage Server-Sent Events (SSE) for tool calling.
- Enabled real-time updates during tool execution for enhanced user experience.

test: Add tests for tool calling system components

- Created `test_tools.py` to validate functionality of code execution, web search, and tool registry.
- Implemented asynchronous tests to ensure proper execution and result handling.

chore: Add Dockerfile for sandbox environment setup

- Created `Dockerfile` to set up a Python environment with necessary dependencies for code execution.

chore: Add debug regex script for testing XML parsing

- Introduced `debug_regex.py` to validate regex patterns against XML tool calls.

chore: Add HTML template for displaying thinking stream events

- Created `test_thinking_stream.html` for visualizing tool calling events in a user-friendly format.

test: Add tests for OllamaAdapter XML parsing

- Developed `test_ollama_parser.py` to validate XML parsing with various test cases, including malformed XML.
2025-12-26 03:49:20 -05:00

195 lines
4.9 KiB
YAML

networks:
lyra_net:
driver: bridge
volumes:
postgres_data:
driver: local
neo4j_data:
driver: local
code_executions:
driver: local
services:
# # ============================================================
# # NeoMem: Postgres
# # ============================================================
# neomem-postgres:
# image: ankane/pgvector:v0.5.1
# container_name: neomem-postgres
# restart: unless-stopped
# environment:
# POSTGRES_USER: neomem
# POSTGRES_PASSWORD: neomempass
# POSTGRES_DB: neomem
# volumes:
# - ./volumes/postgres_data:/var/lib/postgresql/data
# ports:
# - "5432:5432"
# healthcheck:
# test: ["CMD-SHELL", "pg_isready -U neomem -d neomem || exit 1"]
# interval: 5s
# timeout: 5s
# retries: 10
# networks:
# - lyra_net
# # ============================================================
# # NeoMem: Neo4j Graph
# # ============================================================
# neomem-neo4j:
# image: neo4j:5
# container_name: neomem-neo4j
# restart: unless-stopped
# environment:
# NEO4J_AUTH: "neo4j/neomemgraph"
# NEO4JLABS_PLUGINS: '["graph-data-science"]'
# volumes:
# - ./volumes/neo4j_data:/data
# ports:
# - "7474:7474"
# - "7687:7687"
# healthcheck:
# test: ["CMD-SHELL", "cypher-shell -u neo4j -p neomemgraph 'RETURN 1' || exit 1"]
# interval: 10s
# timeout: 10s
# retries: 10
# networks:
# - lyra_net
# ============================================================
# NeoMem API
# ============================================================
# neomem-api:
# build:
# context: ./neomem
# image: lyra-neomem:latest
# container_name: neomem-api
# restart: unless-stopped
# env_file:
# - ./neomem/.env
# - ./.env
# volumes:
# - ./neomem_history:/app/history
# ports:
# - "7077:7077"
# depends_on:
# neomem-postgres:
# condition: service_healthy
# neomem-neo4j:
# condition: service_healthy
# networks:
# - lyra_net
# ============================================================
# Relay (host mode)
# ============================================================
relay:
build:
context: ./core/relay
container_name: relay
restart: unless-stopped
env_file:
- ./.env
volumes:
- ./core/relay/sessions:/app/sessions
ports:
- "7078:7078"
networks:
- lyra_net
# ============================================================
# UI Server
# ============================================================
lyra-ui:
image: nginx:alpine
container_name: lyra-ui
restart: unless-stopped
ports:
- "8081:80"
volumes:
- ./core/ui:/usr/share/nginx/html:ro
networks:
- lyra_net
# ============================================================
# Cortex
# ============================================================
cortex:
build:
context: ./cortex
container_name: cortex
restart: unless-stopped
env_file:
- ./cortex/.env
- ./.env
volumes:
- ./cortex:/app
- /var/run/docker.sock:/var/run/docker.sock:ro
ports:
- "7081:7081"
networks:
- lyra_net
# ============================================================
# Code Sandbox (for tool execution)
# ============================================================
code-sandbox:
build:
context: ./sandbox
container_name: lyra-code-sandbox
restart: unless-stopped
security_opt:
- no-new-privileges:true
cap_drop:
- ALL
cap_add:
- CHOWN
- SETUID
- SETGID
network_mode: "none"
volumes:
- code_executions:/executions
mem_limit: 512m
cpus: 1.0
pids_limit: 100
user: sandbox
command: tail -f /dev/null
# ============================================================
# Intake
# ============================================================
# intake:
# build:
# context: ./intake
# container_name: intake
# restart: unless-stopped
# env_file:
# - ./intake/.env
# - ./.env
# ports:
# - "7080:7080"
# volumes:
# - ./intake:/app
# - ./intake-logs:/app/logs
# depends_on:
# - cortex
# networks:
# - lyra_net
# ============================================================
# RAG Service
# ============================================================
# rag:
# build:
# context: ./rag
# container_name: rag
# restart: unless-stopped
# environment:
# NEOMEM_URL: http://neomem-api:7077
# ports:
# - "7090:7090"
# networks:
# - lyra_net