Search

Results include substring matches and semantically similar vals. Learn more
sean avatar
alphaVantageSymbolSearch
@sean
An interactive, runnable TypeScript val by sean
Script
const queryString = await toQueryString({
...options,
function: "SYMBOL_SEARCH",
try {
const json = await fetchJSON(
pomdtr avatar
openapi2TS
@pomdtr
An interactive, runnable TypeScript val by pomdtr
Script
import { fetch } from "https://esm.town/v/std/fetch";
import { prettifyTS } from "https://esm.town/v/pomdtr/prettifyTS";
export async function openapi2TS(url: string) {
const yaml = await import("npm:yaml");
const resp = await fetch(url);
yawnxyz avatar
breakdown
@yawnxyz
This project is an argument summarizer that leverages AI to analyze and extract key arguments from a given text. Goals: Provide a user-friendly interface for inputting text Process the input using a large language model (LLama3 via Groq) Extract and structure key arguments, explanations, and relevant quotes Present the summarized arguments in a clear, organized format The main pipeline: User inputs text through a web interface The input is sent to an AI model for processing The AI extracts and structures the arguments The results are validated against a predefined schema The structured arguments are displayed to the user This tool aims to help users quickly understand the main points and supporting evidence in complex texts or discussions, making it valuable for research, debate preparation, or general comprehension of argumentative content.
HTTP
// export const model = "gpt-4o"
// export const provider = "openai"
export const summaryModel = "gpt-4o-mini"
export const summaryProvider = "openai"
// export const smartModel = "models/gemini-1.5-pro-latest"
export const smartModel = "gpt-4o-mini"
export const smartProvider = "openai"
export const cheapModel = "gpt-4o-mini"
export const cheapProvider = "openai"
const argschema = z.object({
tmcw avatar
VALLErun
@tmcw
The actual code for VALL-E: https://www.val.town/v/janpaul123/VALLE
HTTP
import { openai } from "npm:@ai-sdk/openai";
export default function(
unless strictly necessary, for example use APIs that don't require a key, prefer internal function
functions where possible. Unless specified, don't add error handling,
The val should create a "export default async function main" which is the main function that gets
// The val should create a "export default async function main() {" which
// is the main function that gets executed, without any arguments. Don't return a Response object,
function write(text) {
function updateValName(valName) {
function saveVal() {
arash2060 avatar
VALLE
@arash2060
VALL-E LLM code generation for vals! Make apps with a frontend, backend, and database. It's a bit of work to get this running, but it's worth it. Fork this val to your own profile. Make a folder for the temporary vals that get generated, take the ID from the URL, and put it in tempValsParentFolderId . If you want to use OpenAI models you need to set the OPENAI_API_KEY env var . If you want to use Anthropic models you need to set the ANTHROPIC_API_KEY env var . Create a Val Town API token , open the browser preview of this val, and use the API token as the password to log in.
HTTP
* Make a folder for the temporary vals that get generated, take the ID from the URL, and put it in `tempValsParentFolderId`.
* If you want to use OpenAI models you need to set the `OPENAI_API_KEY` [env var](https://www.val.town/settings/environment-v
* If you want to use Anthropic models you need to set the `ANTHROPIC_API_KEY` [env var](https://www.val.town/settings/environ
pigrange avatar
myApi
@pigrange
An interactive, runnable TypeScript val by pigrange
Script
export function myApi(name) {
return JSON.parse(
'{"code": 0,"message": "success","data": {"param1": "va success"}}',
dhvanil avatar
val_6ZdZ89Aqqh
@dhvanil
An interactive, runnable TypeScript val by dhvanil
HTTP
export async function val_6ZdZ89Aqqh(req) {
try {
// Execute the code directly and capture its result
leojia avatar
myApi
@leojia
An interactive, runnable TypeScript val by leojia
Script
export function myApi(name) {
return "hi " + name;
dhvanil avatar
val_QrWukp63gM
@dhvanil
An interactive, runnable TypeScript val by dhvanil
HTTP
export async function val_QrWukp63gM(req) {
try {
// Execute the code directly and capture its result
// Inspired by Conway's Game of Life but with a philosophical twist
// This represents how patterns and meaning can emerge from simple rules
function createLifePattern(size, iterations) {
// Initialize random grid (chaos)
let grid = Array(size).fill().map(() =>
sanjeev avatar
myApi
@sanjeev
An interactive, runnable TypeScript val by sanjeev
Script
export function myApi(name) {
return "hi " + name;
pomdtr avatar
deno_deploy
@pomdtr
An interactive, runnable TypeScript val by pomdtr
Script
console.error(e);
Deno.exit(1);
async function run(payload: sunbeam.Payload<typeof manifest>) {
switch (payload.command) {
case "dashboard": {
return item;
} as sunbeam.List;
function fetchDeployAPI(endpoint: string, init?: RequestInit) {
return fetch(`https://dash.deno.com/api${endpoint}`, {
...init,
sbeben avatar
myApi
@sbeben
An interactive, runnable TypeScript val by sbeben
Script
export function myApi() {
return ` <!DOCTYPE html><html lang=";
en;
Handlethis avatar
helpfulFuchsiaAmphibian
@Handlethis
@jsxImportSource https://esm.sh/react
HTTP
import { createRoot } from "https://esm.sh/react-dom/client";
function App() {
const [generatedImage, setGeneratedImage] = useState("");
useEffect(() => {
async function fetchContent() {
try {
// Generate AI audio description
const { OpenAI } = await import("https://esm.town/v/std/openai");
const openai = new OpenAI();
const audioDescCompletion = await openai.chat.completions.create({
messages: [{
Coding Assistance: Offering explanations, code snippets, and debugging help for developers.
Learning and Experimentation: Helping users explore AI's capabilities and understand how language models function.
Val Town
Val Town empowers users by simplifying the process of creating and deploying small programs and scripts. Its intuitive platfo
Build Functional Programs: Create code for tasks such as automations, integrations, or unique applications.
Coding Support: Generate, test, and refine code in an interactive environment, making it accessible for learning and experi
</div>
function client() {
createRoot(document.getElementById("root")).render(<App />);
client();
export default async function server(request: Request): Promise<Response> {
return new Response(
naturealizor avatar
myApi
@naturealizor
An interactive, runnable TypeScript val by naturealizor
Script
export function myApi(name) {
return "hi " + name;
stevekrouse avatar
newCerebrasModelAlert
@stevekrouse
An interactive, runnable TypeScript val by stevekrouse
Cron
import { email } from "https://esm.town/v/std/email?v=13";
import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON";
export default async function(interval: Interval) {
const historicalModels = await blob.getJSON("cerebras-models.json");
const currentModels = await fetchJSON("https://api.cerebras.ai/v1/models", {