Model your domain.Put it to work.

A TypeScript framework for ontology-powered apps and AI.

bun create sixb my-app
From customer context to an approved quotePipedrive, CompanyCam, Google Drive, and PandaDoc connect to a shared model of customers, sites, quotes, and contracts. Prepared data flows up to an app, an agent, and an approval workflow. Creating the quote sends an action back down to PandaDoc. This is an interactive illustration with fictional data; it does not create an external document.PandaDocPipedriveCompanyCamGoogle DriveprojectionSiteQ-1042Riverside$12,400QuoteContractRiversideCustomerAppsQuotesQ-1042$12,400DraftAgentsQuoteassistantPreparingWorkflowsDraftReviewPublish
Q-1042 · $12,400Preparing a quote from connected customer and site information.

From data to working software.

One framework. Every layer.

01 Connect

Start with your data.

Give your project access to the systems you already use. Choose a connector from the library, or bring your own client.

Explore connectors
connectors/pipedrive.ts
import { defineConnector } from "@sixb/core"
import { pipedrive } from "@sixb/connector-pipedrive"

export const crm = defineConnector(
  "pipedrive",
  pipedrive({
    apiToken: () => process.env.PIPEDRIVE_API_TOKEN!,
  })
)
TypeScript

02 Collect

Give every row a home.

Describe the data you want to keep. A sync reads your connector and brings those records into a typed dataset.

Explore datasets and syncs
datasets/customers.ts
import { col, defineDataset } from "@sixb/core"

export const rawCustomers = defineDataset(
  "pipedrive.customers",
  {
    schema: [
      col("id", "string"),
      col("name", "string"),
    ],
    primaryKey: "id",
  }
)
TypeScript

03 Prepare

Make the pieces fit.

Clean names, join sources, and shape records with SQL or TypeScript. Pipelines turn your raw datasets into data you can build on.

Explore pipelines
pipelines/customers.ts
const cleanNames = definePipelineStep("clean-names")
  .inputs({ customers: rawCustomers })
  .output(cleanCustomers)
  .sql(({ customers }) => `
    select id, trim(name) as name
    from ${customers}
  `)

export const prepareCustomers =
  definePipeline("prepare-customers")
    .then(cleanNames)
TypeScript

04 Model

Give your data meaning.

Define the things your software works with and how they relate. Map dataset rows into that shared model, ready for your apps and AI.

Explore the ontology
ontology/customer.ts
export const Customer = defineObjectType({
  id: "Customer",
  name: "Customer",
  properties: [
    prop("id", "string", {
      required: true,
      primary: true,
    }),
    prop("name", "string", { required: true }),
  ],
})
TypeScript

05 Analyze

Ask better questions.

Query your model with typed filters. Bring the results into an AI prompt to summarize, explain, or help decide what to do next.

Explore queries
Find quotes ready for review
const { objects: quotes } = await sixb
  .objects(Quote)
  .query()
  .where((quote) => quote.p.status.eq("ready"))
  .limit(20)
  .list()

for (const quote of quotes) {
  console.log(quote.properties.title)
}
TypeScript

06 Automate

Turn decisions into action.

Connect steps into a repeatable process. Pause for a person's approval, then run an action that writes back to your external system.

Explore workflows
workflows/quote-review.ts
export const quoteReview = defineWorkflow("quote-review")
  .input({
    quote: ref(Quote),
    templateId: "string",
    recipientEmail: "string",
  })
  .then(reviewQuote, ({ input }) => ({ quote: input.quote }))
  .then(createQuoteDocument, ({ input, steps }) => ({
    subject: input.quote,
    params: {
      approved: steps.reviewQuote.approved,
      templateId: input.templateId,
      recipientEmail: input.recipientEmail,
    },
  }))
TypeScript

07 Operate

Put it in people's hands.

Build a React interface on the same model. Your screens, agents, and automation work with the same data and logic.

Explore building apps
app/quotes/page.tsx
import { useObjectsQuery } from "@sixb/client/hooks"
import { objects } from "@sixb/client/query"
import { Quote } from "../../ontology/quote"

export default function Quotes() {
  const query = objects(Quote).query()
    .where((q) => q.p.status.eq("ready"))
  const { data } = useObjectsQuery(query)

  return data?.objects.map((quote) => (
    <article key={quote.primaryId}>
      <h2>{quote.properties.title}</h2>
      <p>{quote.properties.scope}</p>
    </article>
  ))
}
TypeScript

08 Secure

Make access intentional.

Organize people into groups. Give each group a role with explicit grants for the data they can see and the operations they can perform.

Explore permissions
security/roles/quote-reviewers.ts
import { reviewers } from "../groups/reviewers"

export const quoteReviewer = defineRole("quote-reviewer", {
  grantedTo: [reviewers],
  grants: [
    can.access(applications.app),
    can.view([Customer, Quote]),
    can.apply(createQuoteDocument),
  ],
})
TypeScript

09 Extend

Use it wherever you build.

Run your project from the CLI. Access its data over HTTP, or subscribe to changes over WebSockets. The same framework, beyond the browser.

Explore the HTTP API
Terminal
# Start your local project
bun sixb dev

# Build for deployment
bun sixb build

# Start the production API
bun sixb api
Shell

See it come together

Real code. A complete application.

Explore Northline, a working service operations app built with Sixb. Follow the data from connected systems to human decisions and automated actions.

Open example on GitHub Build your own

Search docs

Search the documentation