Skip to content

Commit ae002f1

Browse files
committed
fix(docs): generate tool inputs for factory-built tools
The four embeddings tools rendered header-only Input tables. `extractToolInfo` finds a tool's `params` by regex over the tool's own file, and these files hold nothing but a `createEmbeddingTool({...})` call — the params live in the factory's module. There was already a fallback for a same-file `...spread` base, so this adds the cross-module equivalent: follow the factory's import and read `params` from there. Two things surfaced once the tables populated. `hosting` was not in the set of keys that terminate the `params` capture, so the non-greedy match ran past it to `request:` and swallowed the whole hosting block. Every tool with a `hosting:` section between `params:` and `request:` was publishing `pricing` and `rateLimit` as if they were user-facing inputs — this drops those rows from eight unrelated integration pages as well. The shared apiKey description was a template literal, which the regex emitted verbatim as `${name} API key`. It is now a static string, matching how every other tool in the repo declares one. Docs: the Embeddings page keeps a prose intro in its MANUAL-CONTENT block like other integrations, with the hand-written input/output tables removed now that the generated ones are correct. The sunset `openai` page loses its `encodingFormat` row — page generation skips hidden blocks, so that page is frozen and would otherwise keep advertising a parameter the aliased tool no longer accepts.
1 parent dd636b8 commit ae002f1

12 files changed

Lines changed: 72 additions & 104 deletions

File tree

apps/docs/content/docs/en/integrations/embeddings.mdx

Lines changed: 27 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -13,46 +13,13 @@ import { BlockInfoCard } from "@/components/ui/block-info-card"
1313
{/* MANUAL-CONTENT-START:intro */}
1414
An embedding turns a piece of text into a list of numbers that captures its meaning. Two texts that mean similar things get similar numbers, so you can compare meaning directly instead of matching keywords. That is what powers semantic search, grouping related items, and spotting near-duplicates that are worded differently.
1515

16-
The Embeddings block generates those numbers from one provider of your choice. Pick a provider, pick a model, pass in text, and get a vector back.
17-
18-
### Providers and models
19-
20-
| Provider | Models | Vector size | Max input |
21-
| -------- | ------ | ----------- | --------- |
22-
| **OpenAI** | `text-embedding-3-small`, `text-embedding-3-large`, `text-embedding-ada-002` | 1536 / 3072 / 1536 | 8192 tokens |
23-
| **Google Gemini** | `gemini-embedding-001` | 3072 | 2048 tokens |
24-
| **Cohere** | `embed-v4.0` | 1536 | 128k tokens |
25-
| **Mistral** | `mistral-embed`, `codestral-embed` | 1024 / 1536 (up to 3072) | 8192 tokens |
26-
27-
Use `text-embedding-3-small` for cost-efficient general work, `gemini-embedding-001` for the highest retrieval quality, `embed-v4.0` for multilingual content, and `codestral-embed` for source code.
28-
29-
### Inputs
30-
31-
| Field | Required | Description |
32-
| ----- | -------- | ----------- |
33-
| **Input Text** | Yes | The text to embed. Also accepts an array of texts to embed in one call — up to 1000 items and 1,000,000 characters per request. |
34-
| **Provider** | Yes | OpenAI, Google Gemini, Cohere, or Mistral. Defaults to OpenAI. |
35-
| **Model** | Yes | The embedding model. The list changes to match the provider you picked. |
36-
| **Task Type** | No | What the vector is for: Document, Query, Semantic Similarity, Classification, or Clustering. Only shown for `gemini-embedding-001` and `embed-v4.0`, the two models that condition on it. Everything else ignores it. |
37-
| **Dimensions** | No | A different vector size, when the model supports one. Only shown for models that do. Smaller vectors cost less to store and search, with some loss in quality. `codestral-embed` also goes the other way, up to 3072. |
38-
| **API Key** | Yes | Your provider key. On Sim's cloud this field is hidden — all four providers run on Sim's keys and are billed to your workspace per input token. Self-hosted installs supply their own key here. |
39-
40-
### Outputs
41-
42-
| Field | Type | Description |
43-
| ----- | ---- | ----------- |
44-
| `embeddings` | json | One vector per input, in the same order you supplied them. |
45-
| `model` | string | The model that produced the vectors. |
46-
| `provider` | string | The provider that produced the vectors. |
47-
| `dimensions` | number | The size of each vector. |
48-
| `usage` | json | Input token counts, as `prompt_tokens` and `total_tokens`. |
49-
50-
### Things to know
51-
52-
- **Vectors are only comparable within one model at one size.** A vector from `text-embedding-3-small` cannot be meaningfully compared against one from `embed-v4.0`, or against the same model at a different **Dimensions** setting. Re-embed everything if you change either.
53-
- **Switching provider resets the model.** A model saved under one provider will not survive a switch to another; the block falls back to that provider's default.
54-
- **Long text is shortened, not rejected.** Input above the model's token limit is truncated to fit, and the run logs a warning. Split long documents into chunks yourself when you care about the tail.
55-
- **Knowledge bases are separate.** Sim's knowledge bases embed on a fixed 1536-wide setting and only offer models that can produce it. This block is for embedding text yourself inside a workflow.
16+
The Embeddings block generates those numbers using OpenAI, Google Gemini, Cohere, or Mistral. Pick a provider, pick one of its models, pass in text, and get a vector back — one vector per input, in the order you supplied them. You can embed a single string or a list of strings in one call.
17+
18+
Models differ in what they are good at and what they cost. `text-embedding-3-small` is the cost-efficient general choice, `gemini-embedding-001` gives the highest retrieval quality, `embed-v4.0` handles multilingual content, and `codestral-embed` is tuned for source code. Some models also let you trade vector size against quality, and some accept a task type so the vector is conditioned for how it will be used — the block only offers those controls for the models that actually support them.
19+
20+
Two things worth knowing before you build on it. Vectors are only comparable when they come from the same model at the same size, so changing either means re-embedding everything you intend to compare. And input longer than the model's limit is shortened to fit rather than rejected, with a warning in the run, so chunk long documents yourself when the tail matters.
21+
22+
Sim's knowledge bases embed separately, at a fixed vector width and from a smaller set of models. This block is for embedding text yourself inside a workflow.
5623
{/* MANUAL-CONTENT-END */}
5724

5825

@@ -72,6 +39,11 @@ Generate embeddings from text using OpenAI's embedding models
7239

7340
| Parameter | Type | Required | Description |
7441
| --------- | ---- | -------- | ----------- |
42+
| `input` | string | Yes | Text to embed, or an array of texts to embed in one call |
43+
| `model` | string | No | Embedding model to use |
44+
| `taskType` | string | No | What the embedding is for, when the model supports task conditioning: document, query, similarity, classification, or clustering |
45+
| `dimensions` | number | No | Output dimensions, when the model supports truncation. Defaults to native. |
46+
| `apiKey` | string | Yes | API key for the selected embedding provider |
7547

7648
#### Output
7749

@@ -91,6 +63,11 @@ Generate embeddings from text using Google's Gemini embedding models
9163

9264
| Parameter | Type | Required | Description |
9365
| --------- | ---- | -------- | ----------- |
66+
| `input` | string | Yes | Text to embed, or an array of texts to embed in one call |
67+
| `model` | string | No | Embedding model to use |
68+
| `taskType` | string | No | What the embedding is for, when the model supports task conditioning: document, query, similarity, classification, or clustering |
69+
| `dimensions` | number | No | Output dimensions, when the model supports truncation. Defaults to native. |
70+
| `apiKey` | string | Yes | API key for the selected embedding provider |
9471

9572
#### Output
9673

@@ -110,6 +87,11 @@ Generate embeddings from text using Cohere's embedding models
11087

11188
| Parameter | Type | Required | Description |
11289
| --------- | ---- | -------- | ----------- |
90+
| `input` | string | Yes | Text to embed, or an array of texts to embed in one call |
91+
| `model` | string | No | Embedding model to use |
92+
| `taskType` | string | No | What the embedding is for, when the model supports task conditioning: document, query, similarity, classification, or clustering |
93+
| `dimensions` | number | No | Output dimensions, when the model supports truncation. Defaults to native. |
94+
| `apiKey` | string | Yes | API key for the selected embedding provider |
11395

11496
#### Output
11597

@@ -129,6 +111,11 @@ Generate embeddings from text using Mistral's embedding models
129111

130112
| Parameter | Type | Required | Description |
131113
| --------- | ---- | -------- | ----------- |
114+
| `input` | string | Yes | Text to embed, or an array of texts to embed in one call |
115+
| `model` | string | No | Embedding model to use |
116+
| `taskType` | string | No | What the embedding is for, when the model supports task conditioning: document, query, similarity, classification, or clustering |
117+
| `dimensions` | number | No | Output dimensions, when the model supports truncation. Defaults to native. |
118+
| `apiKey` | string | Yes | API key for the selected embedding provider |
132119

133120
#### Output
134121

apps/docs/content/docs/en/integrations/exa.mdx

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,6 @@ Search the web using Exa AI. Returns relevant search results with titles, URLs,
7171
| `startCrawlDate` | string | No | Deprecated: use startPublishedDate. Only include results crawled on or after this ISO 8601 date |
7272
| `endCrawlDate` | string | No | Deprecated: use endPublishedDate. Only include results crawled on or before this ISO 8601 date |
7373
| `apiKey` | string | Yes | Exa AI API Key |
74-
| `pricing` | custom | No | No description |
75-
| `rateLimit` | string | No | No description |
7674

7775
#### Output
7876

@@ -120,8 +118,6 @@ Retrieve the contents of webpages using Exa AI. Returns the title, text content,
120118
| `livecrawlTimeout` | number | No | Live crawl timeout in milliseconds \(max 90000\). Default: 10000 |
121119
| `livecrawl` | string | No | Deprecated: use maxAgeHours instead. Live crawling mode: never, fallback, always, or preferred |
122120
| `apiKey` | string | Yes | Exa AI API Key |
123-
| `pricing` | custom | No | No description |
124-
| `rateLimit` | string | No | No description |
125121

126122
#### Output
127123

@@ -162,8 +158,6 @@ Find webpages similar to a given URL using Exa AI. Deprecated by Exa in favor of
162158
| `livecrawlTimeout` | number | No | Live crawl timeout in milliseconds \(max 90000\). Default: 10000 |
163159
| `livecrawl` | string | No | Deprecated: use maxAgeHours instead. Live crawling mode: never, fallback, always, or preferred |
164160
| `apiKey` | string | Yes | Exa AI API Key |
165-
| `pricing` | custom | No | No description |
166-
| `rateLimit` | string | No | No description |
167161

168162
#### Output
169163

@@ -191,8 +185,6 @@ Get an AI-generated answer to a question with citations from the web using Exa A
191185
| `text` | boolean | No | Include the full page text of each cited source \(default: false\). This does not affect the answer itself. |
192186
| `outputSchema` | json | No | JSON Schema describing the answer shape. When supplied, the answer is returned as a structured object instead of a string. |
193187
| `apiKey` | string | Yes | Exa AI API Key |
194-
| `pricing` | custom | No | No description |
195-
| `rateLimit` | string | No | No description |
196188

197189
#### Output
198190

@@ -222,8 +214,6 @@ Run a deep research task with Exa Agent. Handles multi-step list building, enric
222214
| `systemPrompt` | string | No | Additional guidance for how the agent should behave or format its answer |
223215
| `previousRunId` | string | No | ID of a completed agent run to continue from, for follow-up questions |
224216
| `apiKey` | string | Yes | Exa AI API Key |
225-
| `pricing` | custom | No | No description |
226-
| `rateLimit` | string | No | No description |
227217

228218
#### Output
229219

apps/docs/content/docs/en/integrations/google_books.mdx

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,6 @@ Search for books using the Google Books API
4646
| `startIndex` | number | No | Index of the first result to return \(for pagination\) |
4747
| `maxResults` | number | No | Maximum number of results to return \(1-40\) |
4848
| `langRestrict` | string | No | Restrict results to a specific language \(ISO 639-1 code\) |
49-
| `pricing` | per_request | No | No description |
50-
| `rateLimit` | string | No | No description |
5149

5250
#### Output
5351

@@ -84,8 +82,6 @@ Get detailed information about a specific book volume
8482
| `apiKey` | string | Yes | Google Books API key |
8583
| `volumeId` | string | Yes | The ID of the volume to retrieve |
8684
| `projection` | string | No | Projection level \(full, lite\) |
87-
| `pricing` | per_request | No | No description |
88-
| `rateLimit` | string | No | No description |
8985

9086
#### Output
9187

apps/docs/content/docs/en/integrations/google_maps.mdx

Lines changed: 0 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,6 @@ Get current air quality data for a location
5050
| `lat` | number | Yes | Latitude coordinate |
5151
| `lng` | number | Yes | Longitude coordinate |
5252
| `languageCode` | string | No | Language code for the response \(e.g., "en", "es"\) |
53-
| `pricing` | per_request | No | No description |
54-
| `rateLimit` | string | No | No description |
5553

5654
#### Output
5755

@@ -93,8 +91,6 @@ Get directions and route information between two locations
9391
| `waypoints` | json | No | Array of intermediate waypoints |
9492
| `units` | string | No | Unit system: metric or imperial |
9593
| `language` | string | No | Language code for results \(e.g., en, es, fr\) |
96-
| `pricing` | per_request | No | No description |
97-
| `rateLimit` | string | No | No description |
9894

9995
#### Output
10096

@@ -139,8 +135,6 @@ Calculate travel distance and time between multiple origins and destinations
139135
| `avoid` | string | No | Features to avoid: tolls, highways, or ferries |
140136
| `units` | string | No | Unit system: metric or imperial |
141137
| `language` | string | No | Language code for results \(e.g., en, es, fr\) |
142-
| `pricing` | custom | No | No description |
143-
| `rateLimit` | string | No | No description |
144138

145139
#### Output
146140

@@ -169,8 +163,6 @@ Get elevation data for a location
169163
| `apiKey` | string | Yes | Google Maps API key |
170164
| `lat` | number | Yes | Latitude coordinate |
171165
| `lng` | number | Yes | Longitude coordinate |
172-
| `pricing` | per_request | No | No description |
173-
| `rateLimit` | string | No | No description |
174166

175167
#### Output
176168

@@ -193,8 +185,6 @@ Convert an address into geographic coordinates (latitude and longitude)
193185
| `address` | string | Yes | The address to geocode |
194186
| `language` | string | No | Language code for results \(e.g., en, es, fr\) |
195187
| `region` | string | No | Region bias as a ccTLD code \(e.g., us, uk\) |
196-
| `pricing` | per_request | No | No description |
197-
| `rateLimit` | string | No | No description |
198188

199189
#### Output
200190

@@ -227,8 +217,6 @@ Geolocate a device using WiFi access points, cell towers, or IP address
227217
| `considerIp` | boolean | No | Whether to use IP address for geolocation \(default: true\) |
228218
| `cellTowers` | array | No | Array of cell tower objects with cellId, locationAreaCode, mobileCountryCode, mobileNetworkCode |
229219
| `wifiAccessPoints` | array | No | Array of WiFi access point objects with macAddress \(required\), signalStrength, etc. |
230-
| `pricing` | per_request | No | No description |
231-
| `rateLimit` | string | No | No description |
232220

233221
#### Output
234222

@@ -250,8 +238,6 @@ Get detailed information about a specific place
250238
| `placeId` | string | Yes | Google Place ID |
251239
| `fields` | string | No | Comma-separated list of fields to return |
252240
| `language` | string | No | Language code for results \(e.g., en, es, fr\) |
253-
| `pricing` | per_request | No | No description |
254-
| `rateLimit` | string | No | No description |
255241

256242
#### Output
257243

@@ -306,8 +292,6 @@ Search for places of a given type within a radius of a location
306292
| `rankPreference` | string | No | How to rank results: POPULARITY \(default\) or DISTANCE |
307293
| `languageCode` | string | No | Language code for the response \(e.g., en, es\) |
308294
| `regionCode` | string | No | Region bias as a ccTLD code \(e.g., us, uk\) |
309-
| `pricing` | per_request | No | No description |
310-
| `rateLimit` | string | No | No description |
311295

312296
#### Output
313297

@@ -342,8 +326,6 @@ Search for places using a text query
342326
| `language` | string | No | Language code for results \(e.g., en, es, fr\) |
343327
| `region` | string | No | Region bias as a ccTLD code \(e.g., us, uk\) |
344328
| `pageToken` | string | No | Token from a previous search response to fetch the next page of results. Wait a couple seconds after receiving the token before using it, or the API returns INVALID_REQUEST |
345-
| `pricing` | per_request | No | No description |
346-
| `rateLimit` | string | No | No description |
347329

348330
#### Output
349331

@@ -378,8 +360,6 @@ Get a daily pollen forecast (grass, tree, weed) for a location
378360
| `days` | number | No | Number of forecast days to return \(1-5, defaults to 1\) |
379361
| `languageCode` | string | No | Language code for the response \(e.g., "en", "es"\) |
380362
| `plantsDescription` | boolean | No | Include detailed plant descriptions \(defaults to true\) |
381-
| `pricing` | per_request | No | No description |
382-
| `rateLimit` | string | No | No description |
383363

384364
#### Output
385365

@@ -413,8 +393,6 @@ Convert geographic coordinates (latitude and longitude) into a human-readable ad
413393
| `lat` | number | Yes | Latitude coordinate |
414394
| `lng` | number | Yes | Longitude coordinate |
415395
| `language` | string | No | Language code for results \(e.g., en, es, fr\) |
416-
| `pricing` | per_request | No | No description |
417-
| `rateLimit` | string | No | No description |
418396

419397
#### Output
420398

@@ -439,8 +417,6 @@ Snap GPS coordinates to the nearest road segment
439417
| `apiKey` | string | Yes | Google Maps API key with Roads API enabled |
440418
| `path` | string | Yes | Pipe-separated list of lat,lng coordinates \(e.g., "60.170880,24.942795\|60.170879,24.942796"\) |
441419
| `interpolate` | boolean | No | Whether to interpolate additional points along the road |
442-
| `pricing` | per_request | No | No description |
443-
| `rateLimit` | string | No | No description |
444420

445421
#### Output
446422

@@ -466,8 +442,6 @@ Get solar potential and panel insights for the building nearest a location
466442
| `lat` | number | Yes | Latitude coordinate |
467443
| `lng` | number | Yes | Longitude coordinate |
468444
| `requiredQuality` | string | No | Minimum imagery quality to accept \(HIGH, MEDIUM, or BASE\) |
469-
| `pricing` | per_request | No | No description |
470-
| `rateLimit` | string | No | No description |
471445

472446
#### Output
473447

@@ -525,8 +499,6 @@ Get timezone information for a location
525499
| `lng` | number | Yes | Longitude coordinate |
526500
| `timestamp` | number | No | Unix timestamp to determine DST offset \(defaults to current time\) |
527501
| `language` | string | No | Language code for timezone name \(e.g., en, es, fr\) |
528-
| `pricing` | per_request | No | No description |
529-
| `rateLimit` | string | No | No description |
530502

531503
#### Output
532504

@@ -552,8 +524,6 @@ Validate and standardize a postal address
552524
| `regionCode` | string | No | ISO 3166-1 alpha-2 country code \(e.g., "US", "CA"\) |
553525
| `locality` | string | No | City or locality name |
554526
| `enableUspsCass` | boolean | No | Enable USPS CASS validation for US addresses |
555-
| `pricing` | per_request | No | No description |
556-
| `rateLimit` | string | No | No description |
557527

558528
#### Output
559529

apps/docs/content/docs/en/integrations/google_pagespeed.mdx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,6 @@ Analyze a webpage for performance, accessibility, SEO, and best practices using
5555
| `category` | string | No | Lighthouse categories to analyze \(comma-separated\): performance, accessibility, best-practices, seo |
5656
| `strategy` | string | No | Analysis strategy: desktop or mobile |
5757
| `locale` | string | No | Locale for results \(e.g., en, fr, de\) |
58-
| `pricing` | per_request | No | No description |
59-
| `rateLimit` | string | No | No description |
6058

6159
#### Output
6260

apps/docs/content/docs/en/integrations/google_translate.mdx

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,6 @@ Translate text between languages using the Google Cloud Translation API. Support
4343
| `target` | string | Yes | Target language code \(e.g., "es", "fr", "de", "ja"\) |
4444
| `source` | string | No | Source language code. If omitted, the API will auto-detect the source language. |
4545
| `format` | string | No | Format of the text: "text" for plain text, "html" for HTML content |
46-
| `pricing` | custom | No | No description |
47-
| `rateLimit` | string | No | No description |
4846

4947
#### Output
5048

@@ -63,8 +61,6 @@ Detect the language of text using the Google Cloud Translation API.
6361
| --------- | ---- | -------- | ----------- |
6462
| `apiKey` | string | Yes | Google Cloud API key with Cloud Translation API enabled |
6563
| `text` | string | Yes | The text to detect the language of |
66-
| `pricing` | custom | No | No description |
67-
| `rateLimit` | string | No | No description |
6864

6965
#### Output
7066

apps/docs/content/docs/en/integrations/linkup.mdx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,6 @@ Search the web for information using Linkup
5151
| `includeDomains` | string | No | Comma-separated list of domain names to restrict search results to |
5252
| `includeInlineCitations` | boolean | No | Add inline citations to answers \(only applies when outputType is "sourcedAnswer"\) |
5353
| `includeSources` | boolean | No | Include sources in response |
54-
| `pricing` | custom | No | No description |
55-
| `rateLimit` | string | No | No description |
5654

5755
#### Output
5856

apps/docs/content/docs/en/integrations/openai.mdx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ Generate embeddings from text using OpenAI's embedding models
4545
| --------- | ---- | -------- | ----------- |
4646
| `input` | string | Yes | Text to generate embeddings for |
4747
| `model` | string | No | Model to use for embeddings |
48-
| `encodingFormat` | string | No | The format to return the embeddings in |
4948
| `apiKey` | string | Yes | OpenAI API key |
5049

5150
#### Output

0 commit comments

Comments
 (0)