Files
SwiftDBAI/Package.swift
Krishna Kumar b1724fe7ca Initial implementation of SwiftDBAI
Chat with any SQLite database using natural language. Built on
AnyLanguageModel (HuggingFace) for LLM-agnostic provider support
and GRDB for SQLite access.

Core features:
- Auto schema introspection from sqlite_master (zero config)
- NL → SQL generation via any AnyLanguageModel provider
- Three rendering modes: text summary, data table, Swift Charts
- Drop-in DataChatView (SwiftUI) and headless ChatEngine
- Operation allowlist with read-only default
- Mutation policy with per-table control
- ToolExecutionDelegate for destructive operation confirmation
- Multi-turn conversation context
- 352 tests across 24 suites, all passing

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-04 09:30:56 -05:00

42 lines
1.0 KiB
Swift

// swift-tools-version: 6.1
import PackageDescription
let package = Package(
name: "SwiftDBAI",
platforms: [
.iOS(.v17),
.macOS(.v14),
.visionOS(.v1),
],
products: [
.library(
name: "SwiftDBAI",
targets: ["SwiftDBAI"]
),
],
dependencies: [
.package(url: "https://github.com/groue/GRDB.swift.git", from: "7.0.0"),
.package(url: "https://github.com/huggingface/AnyLanguageModel.git", branch: "main"),
],
targets: [
.target(
name: "SwiftDBAI",
dependencies: [
.product(name: "GRDB", package: "GRDB.swift"),
.product(name: "AnyLanguageModel", package: "AnyLanguageModel"),
],
swiftSettings: [
.swiftLanguageMode(.v6),
]
),
.testTarget(
name: "SwiftDBAITests",
dependencies: ["SwiftDBAI"],
swiftSettings: [
.swiftLanguageMode(.v6),
]
),
]
)