Skip to content

Commit d35ad54

Browse files
committed
improve readme
1 parent 6c4b033 commit d35ad54

File tree

1 file changed

+19
-4
lines changed

1 file changed

+19
-4
lines changed

README.md

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,37 @@
11
## setup node project
2-
npm init es6 -y && npm install langchain openai dotenv @types/node typescript ts-node
2+
1. install dependencies
3+
```npm init es6 -y && npm install langchain openai dotenv @types/node
4+
```
5+
2. setup node project
6+
```
7+
```
8+
typescript ts-node
9+
```
10+
```
311
npx tsc --init --rootDir src --outDir ./dist --esModuleInterop --lib ES2020 --target ES2020 --module nodenext --noImplicitAny true
12+
```
13+
14+
3. Update Package.json
415
5-
### add to package.json
616
```
717
"scripts": {
818
"build": "tsc",
919
"start": "node ./dist/app.js",
1020
"dev": "ts-node --esm ./src/app.ts"
1121
},
1222
```
13-
### Create an app.ts source file in the src folder. Add code to it to display a test string.
23+
24+
4. Create app.ts in the src folder.
25+
```
1426
mkdir src
1527
echo "console.log('Welcome to the LangChain.js tutorial by LangChainers.')" > src/app.ts
28+
```
1629
17-
### boot up
30+
5. boot up
31+
```
1832
npm run build
1933
npm run start
34+
```
2035
2136
## blog post tutorial https://langchainers.hashnode.dev/getting-started-with-langchainjs
2237

0 commit comments

Comments
 (0)