autonomous-valREADME.md1 match
9Configure the following variables in your environment:
10- `AGENT_API_KEY` (This is a secure token that you choose to secure the agent.tsx POST endpoint)
11- `OPENAI_API_KEY` (An OpenAI API Key)
12- `EXA_API_KEY` (Optional, though needed if you use the web search tool)
13
2import process from "node:process";
3import { marked } from "npm:marked";
4import { OpenAI } from "npm:openai";
56function pm(...lines: string[]): string {
github-apiknowledge.md4 matches
94Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
9596### OpenAI
9798```ts
99import { OpenAI } from "https://esm.town/v/std/openai";
100const openai = new OpenAI();
101const completion = await openai.chat.completions.create({
102messages: [
103{ role: "user", content: "Say hello in a creative way" },
loggerknowledge.md4 matches
94Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
9596### OpenAI
9798```ts
99import { OpenAI } from "https://esm.town/v/std/openai";
100const openai = new OpenAI();
101const completion = await openai.chat.completions.create({
102messages: [
103{ role: "user", content: "Say hello in a creative way" },
logger.cursorrules4 matches
94Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
9596### OpenAI
9798```ts
99import { OpenAI } from "https://esm.town/v/std/openai";
100const openai = new OpenAI();
101const completion = await openai.chat.completions.create({
102messages: [
103{ role: "user", content: "Say hello in a creative way" },
854855export default async function(req: Request) {
856const { OpenAI } = await import("https://esm.town/v/std/openai");
857const { PDFExtract } = await import("npm:pdf.js-extract");
858868const action = url.searchParams.get("action");
869const sourceUrl = import.meta.url.replace("esm.town", "val.town");
870const openai = new OpenAI();
871const MAX_TEXT_SUGGEST = 20000;
872const MAX_TEXT_ANALYZE = 30000;
897agentName: string,
898): Promise<object> {
899log.push({ agent: agentName, type: "step", message: `Calling OpenAI gpt-4o...` });
900try {
901const response = await openai.chat.completions.create({
902model: "gpt-4o",
903messages: [{ role: "system", content: systemPrompt }, { role: "user", content: userMessage }],
SON-GOKUAIToolsList.tsx4 matches
11const aiTools: AITool[] = [
12// AI Assistants & Chatbots
13{ name: "ChatGPT", url: "https://chatgpt.com/", category: "Assistant", description: "OpenAI's conversational AI assistant" },
14{ name: "Claude", url: "https://claude.ai/", category: "Assistant", description: "Anthropic's AI assistant for various tasks and conversations" },
15{ name: "Gemini", url: "https://gemini.google.com/", category: "Assistant", description: "Google's advanced AI assistant" },
27// Image Generation & Editing
28{ name: "Midjourney", url: "https://www.midjourney.com/", category: "Images", description: "AI art and image generation platform" },
29{ name: "DALL·E 3", url: "https://openai.com/dall-e-3", category: "Images", description: "OpenAI's advanced image generation model" },
30{ name: "Stable Diffusion", url: "https://stability.ai/", category: "Images", description: "Open-source AI image generation" },
31{ name: "Lexica", url: "https://lexica.art/", category: "Images", description: "AI art search engine and generator" },
73{ name: "Runway", url: "https://runwayml.com/", category: "Video", description: "AI video editing and generation tools" },
74{ name: "Synthesia", url: "https://www.synthesia.io/", category: "Video", description: "AI video generation with virtual avatars" },
75{ name: "Sora", url: "https://openai.com/sora", category: "Video", description: "OpenAI's text-to-video generation model" },
76{ name: "Kling", url: "https://klingai.com/", category: "Video", description: "AI video generation platform" },
77{ name: "Hailuo", url: "https://hailuo.ai/", category: "Video", description: "AI video creation tool" },
318319// AI Research & Platforms
320{ name: "OpenAI", url: "https://openai.com/", category: "Research", description: "AI research and deployment company" },
321{ name: "Anthropic", url: "https://www.anthropic.com/", category: "Research", description: "AI safety research company" },
322{ name: "xAI", url: "https://x.ai/", category: "Research", description: "Elon Musk's AI company" },
stevensDemo.cursorrules4 matches
100Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
101102### OpenAI
103```ts
104import { OpenAI } from "https://esm.town/v/std/openai";
105const openai = new OpenAI();
106const completion = await openai.chat.completions.create({
107messages: [
108{ role: "user", content: "Say hello in a creative way" },
stevensDemo.cursorrules4 matches
100Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
101102### OpenAI
103```ts
104import { OpenAI } from "https://esm.town/v/std/openai";
105const openai = new OpenAI();
106const completion = await openai.chat.completions.create({
107messages: [
108{ role: "user", content: "Say hello in a creative way" },
Galactaopenai.tsx4 matches
1import { OpenAI } from "https://esm.sh/openai@4.96.2"
23const MODEL = "gpt-4.1-2025-04-14"
45export default async function askOpenAI(message: string): Promise<string> {
6const openai = new OpenAI()
7const response = await openai.responses.create({
8input: message,
9model: MODEL,