Val Town Code SearchReturn to Val Town

API Access

You can access search results via JSON API by adding format=json to your query:

https://codesearch.val.run/...?q=openai&page=49&format=json

For typeahead suggestions, use the /typeahead endpoint:

https://codesearch.val.run/typeahead?q=openai

Returns an array of strings in format "username" or "username/projectName"

Found 2291 results for "openai"(7599ms)

Townie.cursorrules4 matches

@pachchigaryash•Updated 4 weeks ago
94Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
95
96### OpenAI
97
98```ts
99import { OpenAI } from "https://esm.town/v/std/openai";
100const openai = new OpenAI();
101const completion = await openai.chat.completions.create({
102 messages: [
103 { role: "user", content: "Say hello in a creative way" },

Townie.cursorrules4 matches

@gueejla•Updated 4 weeks ago
94Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
95
96### OpenAI
97
98```ts
99import { OpenAI } from "https://esm.town/v/std/openai";
100const openai = new OpenAI();
101const completion = await openai.chat.completions.create({
102 messages: [
103 { role: "user", content: "Say hello in a creative way" },

scifi-bedtime-story-timestoryGenerator.ts4 matches

@dthyresson•Updated 4 weeks ago
1import { OpenAI } from "https://esm.town/v/std/openai";
2import { StoryOptions, generateCuteCharacterName } from "../../shared/types.ts";
3
4const openai = new OpenAI();
5
6export async function generateStory(options: StoryOptions): Promise<{ title: string; content: string; characterName: string }> {
27 `;
28
29 // Generate the story using OpenAI
30 const completion = await openai.chat.completions.create({
31 messages: [
32 { role: "system", content: "You are a creative children's sci-fi storyteller who creates engaging, age-appropriate bedtime stories with robots, aliens, spaceships and other space themes." },

bedtime-story-timestoryGenerator.ts4 matches

@dthyresson•Updated 4 weeks ago
1import { OpenAI } from "https://esm.town/v/std/openai";
2import { StoryOptions, generateCuteAnimalName } from "../../shared/types.ts";
3
4const openai = new OpenAI();
5
6export async function generateStory(options: StoryOptions): Promise<{ title: string; content: string; animalName: string }> {
27 `;
28
29 // Generate the story using OpenAI
30 const completion = await openai.chat.completions.create({
31 messages: [
32 { role: "system", content: "You are a creative children's storyteller who creates engaging, age-appropriate bedtime stories." },

Towniesystem_prompt.txt4 matches

@maxm•Updated 4 weeks ago
88Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
89
90### OpenAI
91
92```ts
93import { OpenAI } from "https://esm.town/v/std/openai";
94const openai = new OpenAI();
95const completion = await openai.chat.completions.create({
96 messages: [
97 { role: "user", content: "Say hello in a creative way" },

Townie.cursorrules4 matches

@maxm•Updated 4 weeks ago
94Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
95
96### OpenAI
97
98```ts
99import { OpenAI } from "https://esm.town/v/std/openai";
100const openai = new OpenAI();
101const completion = await openai.chat.completions.create({
102 messages: [
103 { role: "user", content: "Say hello in a creative way" },

stevens-demo.cursorrules4 matches

@mrexception•Updated 4 weeks ago
100Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
101
102### OpenAI
103```ts
104import { OpenAI } from "https://esm.town/v/std/openai";
105const openai = new OpenAI();
106const completion = await openai.chat.completions.create({
107 messages: [
108 { role: "user", content: "Say hello in a creative way" },

Towniesystem_prompt.txt4 matches

@johndevor•Updated 4 weeks ago
88Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
89
90### OpenAI
91
92```ts
93import { OpenAI } from "https://esm.town/v/std/openai";
94const openai = new OpenAI();
95const completion = await openai.chat.completions.create({
96 messages: [
97 { role: "user", content: "Say hello in a creative way" },

Townie.cursorrules4 matches

@johndevor•Updated 4 weeks ago
94Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
95
96### OpenAI
97
98```ts
99import { OpenAI } from "https://esm.town/v/std/openai";
100const openai = new OpenAI();
101const completion = await openai.chat.completions.create({
102 messages: [
103 { role: "user", content: "Say hello in a creative way" },

Towniesystem_prompt.txt4 matches

@maxm•Updated 4 weeks ago
88Note: When changing a SQLite table's schema, change the table's name (e.g., add _2 or _3) to create a fresh table.
89
90### OpenAI
91
92```ts
93import { OpenAI } from "https://esm.town/v/std/openai";
94const openai = new OpenAI();
95const completion = await openai.chat.completions.create({
96 messages: [
97 { role: "user", content: "Say hello in a creative way" },

HelloWorldOPENAI

@wolf•Updated 1 hour ago

openai-client4 file matches

@cricks_unmixed4u•Updated 22 hours ago
reconsumeralization
import { OpenAI } from "https://esm.town/v/std/openai"; import { sqlite } from "https://esm.town/v/stevekrouse/sqlite"; /** * Practical Implementation of Collective Content Intelligence * Bridging advanced AI with collaborative content creation */ exp
kwhinnery_openai