@yourgpt/copilot-sdk 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +61 -0
- package/dist/chunk-2ZCWVAAK.cjs +1915 -0
- package/dist/chunk-2ZCWVAAK.cjs.map +1 -0
- package/dist/chunk-N4OA2J32.js +1844 -0
- package/dist/chunk-N4OA2J32.js.map +1 -0
- package/dist/chunk-QUGTRQSS.js +3100 -0
- package/dist/chunk-QUGTRQSS.js.map +1 -0
- package/dist/chunk-W6KQT7YZ.cjs +3152 -0
- package/dist/chunk-W6KQT7YZ.cjs.map +1 -0
- package/dist/core/index.cjs +288 -0
- package/dist/core/index.cjs.map +1 -0
- package/dist/core/index.d.cts +870 -0
- package/dist/core/index.d.ts +870 -0
- package/dist/core/index.js +3 -0
- package/dist/core/index.js.map +1 -0
- package/dist/react/index.cjs +137 -0
- package/dist/react/index.cjs.map +1 -0
- package/dist/react/index.d.cts +1824 -0
- package/dist/react/index.d.ts +1824 -0
- package/dist/react/index.js +4 -0
- package/dist/react/index.js.map +1 -0
- package/dist/styles.css +48 -0
- package/dist/thread-C2FjuGLb.d.cts +1225 -0
- package/dist/thread-C2FjuGLb.d.ts +1225 -0
- package/dist/ui/index.cjs +4116 -0
- package/dist/ui/index.cjs.map +1 -0
- package/dist/ui/index.d.cts +1143 -0
- package/dist/ui/index.d.ts +1143 -0
- package/dist/ui/index.js +4019 -0
- package/dist/ui/index.js.map +1 -0
- package/package.json +100 -0
package/README.md
ADDED
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# @yourgpt/copilot-sdk
|
|
2
|
+
|
|
3
|
+
Build AI copilots with app context awareness.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @yourgpt/copilot-sdk
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
```tsx
|
|
14
|
+
// React hooks & provider
|
|
15
|
+
import {
|
|
16
|
+
CopilotProvider,
|
|
17
|
+
useTools,
|
|
18
|
+
useAIContext,
|
|
19
|
+
} from "@yourgpt/copilot-sdk/react";
|
|
20
|
+
|
|
21
|
+
// UI components
|
|
22
|
+
import { CopilotChat } from "@yourgpt/copilot-sdk/ui";
|
|
23
|
+
|
|
24
|
+
// Core types and utilities
|
|
25
|
+
import { tool, success, type ToolDefinition } from "@yourgpt/copilot-sdk/core";
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Styling (Tailwind CSS v4)
|
|
29
|
+
|
|
30
|
+
Add the SDK source to your Tailwind config:
|
|
31
|
+
|
|
32
|
+
```css
|
|
33
|
+
/* app/globals.css */
|
|
34
|
+
@import "tailwindcss";
|
|
35
|
+
|
|
36
|
+
@source "node_modules/@yourgpt/copilot-sdk/src/**/*.{ts,tsx}";
|
|
37
|
+
|
|
38
|
+
@custom-variant dark (&:is(.dark *));
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
For theming, optionally import the default CSS variables:
|
|
42
|
+
|
|
43
|
+
```css
|
|
44
|
+
@import "@yourgpt/copilot-sdk/ui/styles.css";
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
## Subpath Exports
|
|
48
|
+
|
|
49
|
+
| Subpath | Description |
|
|
50
|
+
| -------- | ------------------------------ |
|
|
51
|
+
| `/core` | Types, utilities, tool helpers |
|
|
52
|
+
| `/react` | React hooks and provider |
|
|
53
|
+
| `/ui` | Pre-built UI components |
|
|
54
|
+
|
|
55
|
+
## Documentation
|
|
56
|
+
|
|
57
|
+
Visit [https://copilot-sdk.yourgpt.ai](https://copilot-sdk.yourgpt.ai)
|
|
58
|
+
|
|
59
|
+
## License
|
|
60
|
+
|
|
61
|
+
MIT
|