Skip to content

Commit 23811b8

Browse files
Merge branch 'main' into ci/update
2 parents 43d0f28 + f22d66b commit 23811b8

File tree

5 files changed

+77
-50
lines changed

5 files changed

+77
-50
lines changed

README.md

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,25 @@ There are mainly 2 ways of installing Cairo Coder - With Docker, Without Docker.
117117
database, while the second is used by your application to connect to it.
118118

119119

120-
7. Run the application using one of the following methods:
120+
7. **Configure LangSmith (Optional)**
121+
122+
Cairo Coder can use LangSmith to record and monitor LLM calls. This step is optional but recommended for development and debugging.
123+
124+
- Create an account at [LangSmith](https://smith.langchain.com/)
125+
- Create a new project in the LangSmith dashboard
126+
- Retrieve your API credentials
127+
- Create a `.env` file in the `packages/backend` directory with the following variables:
128+
```
129+
LANGSMITH_TRACING=true
130+
LANGSMITH_ENDPOINT="https://api.smith.langchain.com"
131+
LANGSMITH_API_KEY="<your-api-key>"
132+
LANGCHAIN_PROJECT="<your-project-name>"
133+
```
134+
135+
With this configuration, all LLM calls and chain executions will be logged to your LangSmith project, allowing you to debug, analyze, and improve the system's performance.
136+
137+
138+
9. Run the application using one of the following methods:
121139

122140
```bash
123141
docker-compose up --build

docker-compose.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ services:
2222
- 3001:3001
2323
extra_hosts:
2424
- host.docker.internal:host-gateway
25+
env_file:
26+
- packages/backend/.env
2527
depends_on:
2628
postgres:
2729
condition: service_started

packages/backend/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,16 @@
1313
"test:unit": "jest --config jest.config.js --testMatch=\"**/__tests__/unit/**/*.test.[jt]s?(x)\""
1414
},
1515
"dependencies": {
16+
"@cairo-coder/agents": "workspace:*",
1617
"@iarna/toml": "^2.2.5",
1718
"@langchain/anthropic": "^0.2.18",
1819
"@langchain/community": "^0.3.32",
1920
"@langchain/core": "^0.2.36",
2021
"@langchain/google-genai": "^0.1.8",
2122
"@langchain/openai": "^0.0.25",
22-
"@cairo-coder/agents": "workspace:*",
2323
"@types/node": "^20",
2424
"cors": "^2.8.5",
25+
"dotenv": "^16.4.7",
2526
"express": "^4.21.2",
2627
"node-fetch": "2.7.0",
2728
"uuid": "^11.1.0",

packages/backend/src/app.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
import { createApplication } from './server';
22
import { logger } from '@cairo-coder/agents/utils/index';
3+
import dotenv from 'dotenv';
4+
5+
dotenv.config();
36

47
// Error handling for uncaught exceptions
58
process.on('uncaughtException', (err, origin) => {

pnpm-lock.yaml

Lines changed: 51 additions & 48 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)