Skip to content

Commit

Permalink
examples(langgraph): add markdown parser (#758)
Browse files Browse the repository at this point in the history
  • Loading branch information
Yonom authored Sep 7, 2024
1 parent eaa726b commit dd77187
Show file tree
Hide file tree
Showing 8 changed files with 30 additions and 22 deletions.
12 changes: 6 additions & 6 deletions apps/docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@
"dependencies": {
"@ai-sdk/openai": "^0.0.54",
"@ai-sdk/provider": "^0.0.22",
"@assistant-ui/react": "workspace:^",
"@assistant-ui/react-ai-sdk": "workspace:^",
"@assistant-ui/react-langgraph": "workspace:^",
"@assistant-ui/react-markdown": "workspace:^",
"@assistant-ui/react-syntax-highlighter": "workspace:^",
"@assistant-ui/tsconfig": "workspace:^",
"@assistant-ui/react": "workspace:*",
"@assistant-ui/react-ai-sdk": "workspace:*",
"@assistant-ui/react-langgraph": "workspace:*",
"@assistant-ui/react-markdown": "workspace:*",
"@assistant-ui/react-syntax-highlighter": "workspace:*",
"@assistant-ui/tsconfig": "workspace:*",
"@langchain/core": "^0.2.31",
"@langchain/langgraph-sdk": "^0.0.8",
"@radix-ui/react-avatar": "^1.1.0",
Expand Down
5 changes: 4 additions & 1 deletion examples/with-langgraph/app/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ import { Thread } from "@assistant-ui/react";
import { PriceSnapshotTool } from "@/components/tools/price-snapshot/PriceSnapshotTool";
import { PurchaseStockTool } from "@/components/tools/purchase-stock/PurchaseStockTool";
import { ToolFallback } from "@/components/tools/ToolFallback";
import { makeMarkdownText } from "@assistant-ui/react-markdown";

const MarkdownText = makeMarkdownText({});

export default function Home() {
return (
Expand All @@ -22,7 +25,7 @@ export default function Home() {
},
],
}}
assistantMessage={{ components: { ToolFallback } }}
assistantMessage={{ components: { Text: MarkdownText, ToolFallback } }}
tools={[PriceSnapshotTool, PurchaseStockTool]}
/>
</div>
Expand Down
1 change: 1 addition & 0 deletions examples/with-langgraph/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"dependencies": {
"@assistant-ui/react": "workspace:*",
"@assistant-ui/react-langgraph": "workspace:*",
"@assistant-ui/react-markdown": "workspace:*",
"@langchain/langgraph-sdk": "^0.0.8",
"@radix-ui/react-slot": "^1.1.0",
"class-variance-authority": "^0.7.0",
Expand Down
1 change: 1 addition & 0 deletions examples/with-langgraph/tailwind.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ const config = {
plugins: [
require("tailwindcss-animate"),
require("@assistant-ui/react/tailwindcss")({ shadcn: true }),
require("@assistant-ui/react-markdown/tailwindcss"),
],
} satisfies Config;

Expand Down
2 changes: 1 addition & 1 deletion examples/with-playground/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"tailwindcss-animate": "^1.0.7"
},
"devDependencies": {
"@assistant-ui/tsconfig": "workspace:^",
"@assistant-ui/tsconfig": "workspace:*",
"@types/node": "^22",
"@types/react": "^18",
"@types/react-dom": "^18",
Expand Down
2 changes: 1 addition & 1 deletion packages/react-markdown/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
}
},
"devDependencies": {
"@assistant-ui/tailwindcss-transformer": "workspace:^",
"@assistant-ui/tailwindcss-transformer": "workspace:*",
"@assistant-ui/tsconfig": "workspace:*",
"@types/node": "^22.5.2",
"autoprefixer": "^10.4.20",
Expand Down
2 changes: 1 addition & 1 deletion packages/shadcn-registry/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"devDependencies": {
"@assistant-ui/react": "workspace:*",
"@assistant-ui/react-markdown": "workspace:*",
"@assistant-ui/react-syntax-highlighter": "workspace:^",
"@assistant-ui/react-syntax-highlighter": "workspace:*",
"@assistant-ui/tsconfig": "workspace:*",
"@radix-ui/react-avatar": "^1.1.0",
"@radix-ui/react-icons": "^1.3.0",
Expand Down
27 changes: 15 additions & 12 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit dd77187

Please sign in to comment.