Skip to main content
Guide
A generation asks Foundry’s agent to draft a new version of an ontology: its types, links, mappings from your tables, routes for your documents, rules and the questions it should answer. Each draft is stored as a new version beside the others. Nothing changes until you make a version current. Creating an ontology drafts its first version, and until the ontology is set up its overview carries on from there: generate, review, make current, load. Generate drafts the next versions.

Generate a draft, review it and make it current.

Generate a draft

1

Say what it should serve

On the ontology, select Generate. Under What should it serve?, write the questions people will ask of it, in your words. The goal is optional, up to 2,000 characters, and names the generation.Copy prompt for your agent copies a prompt for your own AI assistant to write the goal with you. It describes the tables and document sets you chose, quotes the goal so far, and asks the assistant to draw on what it knows of your work, ask you at most five questions, and reply with a goal you paste back here. Foundry sends nothing itself.
2

Choose its tables

Under Tables, choose the connectors whose synced tables go in; every table a chosen connector has synced is included. Connectors are grouped by kind: a kind with one connector shows it on its own, and a kind with several nests them under one choice. Expand that choice to pick some of them; it then shows as partly chosen. Expand a connector to see its tables. A generation reads at most 50 tables.Add data connects another source without leaving the form. Its first sync shows in its row, and it is chosen once it has synced.
The Generate an ontology form with a goal and Copy prompt for your agent, Stripe chosen, and PostgreSQL's two connectors expanded with one of them chosen
3

Choose its API sources

Under API sources, choose the API sources it reads, and how each is read: Structured mappings map its fields to types and properties, like a table’s columns; Entity extraction reads the text of its newest 500 pieces for the entities and facts they describe, from the source’s text field, which owners and admins can choose here. A source can be chosen once its first pieces have synced.
The API sources section of the Generate form, with Order lines chosen and read through Structured mappings
4

Choose its documents

Under Documents, choose the document sets the new version reads. You pick whole sets, the folders of the Connectors explorer’s Documents. The choice starts as the current version’s sets, or none for a first generation. Leave every set unticked for a version that reads no documents. A generation reads at most 20 sets. Upload documents, or the upload button on a set’s row, uploads files from here and chooses the set they went into.The agent reads up to five of the newest documents in each set, with the set’s description, and drafts routes for them: what each set’s documents may fill. It drafts mappings for the table files in them, as it does for synced tables. Loads of the new version read the documents of these sets, and only theirs.
The Documents section of the Generate form, with General chosen and its contract.md listed, and Board minutes not chosen
5

Generate

Select Generate. The generation’s page follows it as it runs.

Follow a generation

A generation is Queued, then Running, then Succeeded or Failed. It can take several minutes. An attempt that fails for a passing reason is retried, up to three attempts; while it waits, the page says it is retrying, why, and when it runs next. Other failures, such as a draft the agent refused, fail at once. An ontology runs one generation at a time, and a workspace starts at most 10 generations and version edits an hour.
A succeeded generation that drafted version 4, with Review version 4
A generation’s page shows its goal, its tables and its steps. Open it from its version’s page, where the version is named for it, or from a failed generation’s row in Schema versions. A failed generation offers Try again, which opens the form with the same goal, connectors and document sets.

Schema versions

Schema versions, on the ontology’s overview below its schema, lists every version, newest first, named by the generation that drafted it, with the generations that failed among them. Each row shows the version’s status, title, format and when it was made. Select a row to open the version, or a failed generation’s row to see why it failed.
Schema versions listing versions 4 to 1 by title, version 3 current, and a failed generation among them

Review a version

Select Review version on a generation or in Schema versions. A version’s header says whether it is current, its format, the document sets its loads read (Reads …) and the generation it was drafted for. An agent draft opens on its summary and its graph, with a tab for each part:
Version 3, an agent draft that reads General, with its summary, Graph tab and the Sources and Edit tabs

Edit a version

Versions never change. To change a finished agent draft without generating again, use its Edit tab, which makes a new version from your edits:
  1. Choose an item to edit, or Add document route, Add rule or Add constraint, write it as TOML, and select Stage item. Stage as many as you need.
  2. Select Preview edits. Foundry checks the edits and says what they would change, without storing a version.
  3. Select Create version, then View new version. Make it current and load it to apply your edits.
Edits cover document routes, the identifiers of a type, rules and constraints. A route that names a document set adds that set to the new version’s reads, so an existing ontology can read a new set without a new generation. To change which tables fill a type, or the types and links themselves, generate again with a sharper goal or different tables.

Make a version current

Select Make current on a version’s page, or on the overview, which offers it for a version ready to review, and confirm. The current version is the one the overview shows and the one a load writes. To roll back, make an older version current. If someone else makes another version current at the same time, Foundry refuses yours, says why, and shows the version that is current now.
Only an Agent draft the agent finished can be loaded. A draft it stopped early, or a version in the older Definition v1 format, can be reviewed and made current, but not loaded.

Who can do what

Owners and admins generate, edit versions and make them current. Members see every generation and version.

Next steps

Load data

Write the current version into the ontology’s database.

Upload documents

Put documents into sets for a version to read.