This PR is a revision of #593
I've confirmed that workflows pass in my forked repo.
New dependencies detected. Learn more about Socket for GitHub ↗︎
| Package |
New capabilities |
Transitives |
Size |
Publisher |
| npm/@remix-run/[email protected] |
None |
0 |
13.1 kB |
mjackson |
| npm/@remix-run/[email protected] |
environment, filesystem Transitive: eval, network, shell, unsafe |
+410 |
283 MB |
mjackson |
| npm/@remix-run/[email protected] |
Transitive: environment, filesystem, shell, unsafe |
+197 |
28.1 MB |
mjackson |
| npm/@remix-run/[email protected] |
Transitive: environment, filesystem, network |
+28 |
23.2 MB |
mjackson |
| npm/@remix-run/[email protected] |
environment, network Transitive: filesystem |
+8 |
5.09 MB |
mjackson |
| npm/@remix-run/[email protected] |
Transitive: environment, eval, filesystem, network, unsafe |
+62 |
2.77 MB |
mjackson |
| npm/@types/[email protected] |
None |
+1 |
2.13 MB |
types |
| npm/@types/[email protected] |
None |
0 |
37.8 kB |
types |
| npm/@types/[email protected] |
None |
+2 |
1.69 MB |
types |
| npm/@vercel/[email protected] |
Transitive: environment, eval, filesystem, network, shell, unsafe |
+448 |
318 MB |
vercel-release-bot |
| npm/[email protected] |
environment Transitive: filesystem, unsafe |
+50 |
5.59 MB |
eslintbot |
| npm/[email protected] |
None |
0 |
29.2 kB |
omrilotan |
| npm/[email protected] |
environment |
+2 |
4.62 MB |
react-bot |
| npm/[email protected] |
environment |
+1 |
333 kB |
react-bot |
| npm/[email protected] |
environment, filesystem Transitive: shell, unsafe |
+55 |
11.8 MB |
adamwathan |
| npm/[email protected] |
None |
0 |
32.4 MB |
typescript-bot |
View full report↗︎
Would you update it with AI SDK 3.1?
Looks like it is supposed to be something like this:
import { createOpenAI } from '@ai-sdk/openai';
import { config } from '#app/config.server';
import { defineAction } from '#app/unstable';
import { StreamingTextResponse, streamText } from 'ai';
export default defineAction(async ({ request }) => {
const openai = createOpenAI({
apiKey: config.OPENAI_API_KEY,
compatibility: 'strict',
});
const model = openai('gpt-4o');
const { messages } = await request.json();
const response = await streamText({
messages,
model,
});
return new StreamingTextResponse(response.textStream);
});