chore: import upstream snapshot with attribution
CF: Deploy Dev Docs / deploy (push) Has been cancelled
Sync Labels / build (push) Has been cancelled
tests / unit tests (macos-latest) (push) Has been cancelled
tests / unit tests (windows-latest) (push) Has been cancelled
tests / unit tests (ubuntu-latest) (push) Has been cancelled

This commit is contained in:
wehub-resource-sync
2026-07-13 13:32:45 +08:00
commit e04ed9c211
1798 changed files with 307905 additions and 0 deletions
+4
View File
@@ -0,0 +1,4 @@
---
title: "SQLite"
weight: 1
---
@@ -0,0 +1,5 @@
---
title: "Prebuilt Configs"
type: docs
description: "Prebuilt configurations for Sqlite."
---
@@ -0,0 +1,17 @@
---
title: "SQLite"
type: docs
description: "Details of the SQLite prebuilt configuration."
---
## SQLite
* `--prebuilt` value: `sqlite`
* **Environment Variables:**
* `SQLITE_DATABASE`: The path to the SQLite database file (e.g.,
`./sample.db`).
* **Permissions:**
* File system read/write permissions for the specified database file.
* **Tools:**
* `execute_sql`: Executes a SQL query.
* `list_tables`: Lists tables in the database.
+80
View File
@@ -0,0 +1,80 @@
---
title: "SQLite Source"
linkTitle: "Source"
type: docs
weight: 1
description: >
SQLite is a C-language library that implements a small, fast, self-contained,
high-reliability, full-featured, SQL database engine.
no_list: true
---
## About
[SQLite](https://sqlite.org/) is a software library that provides a relational
database management system. The lite in SQLite means lightweight in terms of
setup, database administration, and required resources.
SQLite has the following notable characteristics:
- Self-contained with no external dependencies
- Serverless - the SQLite library accesses its storage files directly
- Single database file that can be easily copied or moved
- Zero-configuration - no setup or administration needed
- Transactional with ACID properties
## Available Tools
{{< list-tools >}}
### Pre-built Configurations
- [SQLite using MCP](../../documentation/connect-to/ides/sqlite_mcp.md)
Connect your IDE to SQlite using Toolbox.
## Requirements
### Database File
You need a SQLite database file. This can be:
- An existing database file
- A path where a new database file should be created
- `:memory:` for an in-memory database
## Example
```yaml
kind: source
name: my-sqlite-db
type: "sqlite"
database: "/path/to/database.db"
```
For an in-memory database:
```yaml
kind: source
name: my-sqlite-memory-db
type: "sqlite"
database: ":memory:"
```
## Reference
### Configuration Fields
| **field** | **type** | **required** | **description** |
|-----------|:--------:|:------------:|---------------------------------------------------------------------------------------------------------------------|
| type | string | true | Must be "sqlite". |
| database | string | true | Path to SQLite database file, or ":memory:" for an in-memory database. |
| sqlCommenter | boolean | false | Overrides the global `--sql-commenter` flag for this source. When set, it takes priority; when omitted, the global flag applies. |
### Connection Properties
SQLite connections are configured with these defaults for optimal performance:
- `MaxOpenConns`: 1 (SQLite only supports one writer at a time)
- `MaxIdleConns`: 1
@@ -0,0 +1,4 @@
---
title: "Tools"
weight: 2
---
@@ -0,0 +1,41 @@
---
title: "sqlite-execute-sql"
type: docs
weight: 1
description: >
A "sqlite-execute-sql" tool executes a single SQL statement against a SQLite database.
---
## About
A `sqlite-execute-sql` tool executes a single SQL statement against a SQLite
database.
This tool is designed for direct execution of SQL statements. It takes a single
`sql` input parameter and runs the SQL statement against the configured SQLite
`source`.
> **Note:** This tool is intended for developer assistant workflows with
> human-in-the-loop and shouldn't be used for production agents.
## Compatible Sources
{{< compatible-sources >}}
## Example
```yaml
kind: tool
name: execute_sql_tool
type: sqlite-execute-sql
source: my-sqlite-db
description: Use this tool to execute a SQL statement.
```
## Reference
| **field** | **type** | **required** | **description** |
|-------------|:--------:|:------------:|----------------------------------------------------|
| type | string | true | Must be "sqlite-execute-sql". |
| source | string | true | Name of the source the SQL should execute on. |
| description | string | true | Description of the tool that is passed to the LLM. |
@@ -0,0 +1,83 @@
---
title: "sqlite-sql"
type: docs
weight: 1
description: >
Execute SQL statements against a SQLite database.
---
## About
A `sqlite-sql` tool executes SQL statements against a SQLite database.
SQLite uses the `?` placeholder for parameters in SQL statements. Parameters are
bound in the order they are provided.
The statement field supports any valid SQLite SQL statement, including `SELECT`,
`INSERT`, `UPDATE`, `DELETE`, `CREATE/ALTER/DROP` table statements, and other
DDL statements.
## Compatible Sources
{{< compatible-sources >}}
## Example
> **Note:** This tool uses parameterized queries to prevent SQL injections.
> Query parameters can be used as substitutes for arbitrary expressions.
> Parameters cannot be used as substitutes for identifiers, column names, table
> names, or other parts of the query.
```yaml
kind: tool
name: search-users
type: sqlite-sql
source: my-sqlite-db
description: Search users by name and age
parameters:
- name: name
type: string
description: The name to search for
- name: min_age
type: integer
description: Minimum age
statement: SELECT * FROM users WHERE name LIKE ? AND age >= ?
```
### Example with Template Parameters
> **Note:** This tool allows direct modifications to the SQL statement,
> including identifiers, column names, and table names. **This makes it more
> vulnerable to SQL injections**. Using basic parameters only (see above) is
> recommended for performance and safety reasons. For more details, please check
> [templateParameters](../../../documentation/configuration/tools/_index.md#template-parameters).
```yaml
kind: tool
name: list_table
type: sqlite-sql
source: my-sqlite-db
statement: |
SELECT * FROM {{.tableName}};
description: |
Use this tool to list all information from a specific table.
Example:
{{
"tableName": "flights",
}}
templateParameters:
- name: tableName
type: string
description: Table to select from
```
## Reference
| **field** | **type** | **required** | **description** |
|--------------------|:--------------------------------------------:|:------------:|----------------------------------------------------------------------------------------------------------------------------------------|
| type | string | true | Must be "sqlite-sql". |
| source | string | true | Name of the source the SQLite source configuration. |
| description | string | true | Description of the tool that is passed to the LLM. |
| statement | string | true | The SQL statement to execute. |
| parameters | [parameters](../../../documentation/configuration/tools/_index.md#specifying-parameters) | false | List of [parameters](../../../documentation/configuration/tools/_index.md#specifying-parameters) that will be inserted into the SQL statement. |
| templateParameters | [templateParameters](../../../documentation/configuration/tools/_index.md#template-parameters) | false | List of [templateParameters](../../../documentation/configuration/tools/_index.md#template-parameters) that will be inserted into the SQL statement before executing prepared statement. |