Skip to content

Commit

Permalink
docs: reorder pages (#1150)
Browse files Browse the repository at this point in the history
  • Loading branch information
Yonom authored Nov 11, 2024
1 parent dd8b131 commit 132e5ba
Show file tree
Hide file tree
Showing 10 changed files with 16 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ title: Architecture
---

import Image from "next/image";
import architecture from "../../assets/docs/architecture.png";
import architecture from "@/assets/docs/architecture.png";

### Architecture

Expand Down
2 changes: 1 addition & 1 deletion apps/docs/content/docs/concepts/meta.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"title": "Concepts",
"pages": ["runtime-layer"]
"pages": ["architecture", "runtime-layer"]
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 4 additions & 0 deletions apps/docs/content/docs/guides/meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"title": "Guides",
"pages": ["Attachments", "Branching", "Editing", "Speech", "ToolUI"]
}
12 changes: 5 additions & 7 deletions apps/docs/content/docs/meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,13 @@
"root": true,
"pages": [
"getting-started",
"architecture",
"guides",
"concepts",
"migrations",
"reference",
"---UI---",
"...ui",
"---Runtimes---",
"...runtimes",
"---Advanced---",
"...advanced",
"concepts",
"migrations",
"reference"
"...runtimes"
]
}
10 changes: 5 additions & 5 deletions apps/docs/content/docs/reference/context.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ The context is split into four hierarchies:

import { ParametersTable } from "@/components/docs";
import {
AssistantRuntimeState,
AssistantToolUIsState,
ThreadState,
ThreadMessagesState,
Expand All @@ -27,26 +26,27 @@ import {
ComposerAttachmentState,
MessageAttachmentState,
} from "@/components/docs/parameters/context";
import { AssistantRuntime, ThreadRuntime } from "@/generated/typeDocs";

## Assistant Context

#### `useAssistantRuntime`
### `useAssistantRuntime`

```tsx
import { useAssistantRuntime } from "@assistant-ui/react";

const runtime = useAssistantRuntime();
```

<ParametersTable {...AssistantRuntimeState} />
<ParametersTable {...AssistantRuntime} />

### `useToolUIs`

```tsx
import { useToolUIs } from "@assistant-ui/react";

const toolUIs = useToolUIs();
const getToolUI = useToolUIs((m) => m.getToolUI);
const webSearchToolUI = useToolUIs((m) => m.getToolUI("web_search"));
```

<ParametersTable {...AssistantToolUIsState} />
Expand All @@ -61,7 +61,7 @@ import { useThreadRuntime } from "@assistant-ui/react";
const thread = useThreadRuntime();
```

<ParametersTable {...ThreadRuntimeState} />
<ParametersTable {...ThreadRuntime} />

### `useThread`

Expand Down

0 comments on commit 132e5ba

Please sign in to comment.