Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

sqlite-utils-ask

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sqlite-utils-ask

Ask questions of your data with LLM assistance

  • 0.2
  • PyPI
  • Socket score

Maintainers
1

sqlite-utils-ask

PyPI Changelog Tests License

Ask questions of your data with LLM assistance

Installation

Install this plugin in the same environment as sqlite-utils.

sqlite-utils install sqlite-utils-ask

sqlite-utils ask

Ask questions of a SQLite database file like this:

sqlite-utils ask content.db 'How many repos?'

The tool will use an LLM (gpt-4o-mini by default) to generate the appropriate SQL query by passing through your question and the database schema, and will then execute the query and return the result.

sqlite-utils ask-files

You can also ask questions directly of CSV, TSV or JSON files. These will be imported into an in-memory SQLite database prior to running the query.

sqlite-utils ask-files data.csv 'How many repos?'

You can pass multiple files and run queries across multiple resulting tables.

sqlite-utils ask-files legislators.csv votes.csv 'How many votes did each legislator cast?'

Development

To set up this plugin locally, first checkout the code. Then create a new virtual environment:

cd sqlite-utils-ask
python -m venv venv
source venv/bin/activate

Now install the dependencies and test dependencies:

pip install -e '.[test]'

To run the tests:

python -m pytest

To capture new HTTP interactions, run:

PYTEST_OPENAI_API_KEY=your-key python -m pytest --record-mode once

Or use --record-mode all to re-record all interactions.

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc