Skip to content

Commit 8edb21d

Browse files
committed
feat: litellm support
1 parent db5b042 commit 8edb21d

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

src/server/docker-compose.yaml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,22 @@ services:
9090
networks:
9191
- sentient_network
9292

93+
# 6. LiteLLM Proxy for Gemini Models
94+
litellm:
95+
image: ghcr.io/berriai/litellm:main-latest # Use the latest stable image
96+
container_name: litellm-proxy
97+
restart: unless-stopped
98+
networks:
99+
- sentient_network # Join the shared network for internal access
100+
volumes:
101+
- ./litellm-config.yaml:/app/config.yaml:ro # Mount your config (create in src\server if needed)
102+
command: ["--config", "/app/config.yaml", "--port", "4000"] # Run with config; optional: add "--detailed_debug"
103+
env_file:
104+
- ./.env # Loads GEMINI_API_KEY and others
105+
# depends_on: [] # No dependencies needed, but add if required (e.g., for a DB)
106+
# ports: # Optional: Expose if you need external access (e.g., for testing)
107+
# - "4000:4000"
108+
93109
# Defines the shared network for all services
94110
networks:
95111
sentient_network:

src/server/litellm-config.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
model_list:
2+
- model_name: gemini-2.5-flash
3+
litellm_params:
4+
model: gemini/gemini-2.5-flash-lite
5+
api_key: os.environ/GEMINI_API_KEY
6+
7+
litellm_settings:
8+
drop_params: true

0 commit comments

Comments
 (0)