
Security News
TypeScript is Porting Its Compiler to Go for 10x Faster Builds
TypeScript is porting its compiler to Go, delivering 10x faster builds, lower memory usage, and improved editor performance for a smoother developer experience.
@breadboard-ai/build
Advanced tools
JavaScript library for building boards and defining new node types for the Breadboard AI prototyping library
The Breadboard Build API allows you to design and compose boards with TypeScript.
It is an alternative to the Visual Editor, designed for users who prefer a code-first approach to working with Breadboard.
Boards that you create with the Build API can be serialized to BGL (Breadboard Graph Language), which can then be executed directly, or imported into the Visual Editor.
npm i @breadboard-ai/build
Please refer to the Build API section of the Breadboard Documentation site for full documentation.
import { board, input, output } from "@breadboard-ai/build";
import { prompt } from "@google-labs/template-kit";
import { geminiText } from "@google-labs/gemini-kit";
const topic = input({
description: "What should the poem be about?",
examples: ["Coffee in the morning", "The mind of a cat"],
});
const stanzas = input({
type: "number",
description: "How many stanzas should the poem have?",
default: 4,
});
const poemPrompt = prompt`
Write a poem about ${topic} with ${stanzas} stanzas.`;
const poemWriter = geminiText({
text: poemPrompt,
model: "gemini-1.5-flash-latest",
});
const poem = output(poemWriter.outputs.text, {
title: "Poem",
description: "The poem that Gemini generated.",
});
export default board({
id: "poem-writer",
title: "Poem Writer",
description: "Write a poem with Gemini.",
inputs: { topic, stanzas },
outputs: { poem },
});
FAQs
JavaScript library for building boards and defining new node types for the Breadboard AI prototyping library
The npm package @breadboard-ai/build receives a total of 442 weekly downloads. As such, @breadboard-ai/build popularity was classified as not popular.
We found that @breadboard-ai/build demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
TypeScript is porting its compiler to Go, delivering 10x faster builds, lower memory usage, and improved editor performance for a smoother developer experience.
Research
Security News
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.