← All projects/ soilsaint

// Personal project · natural-language data

SoilSaint

A natural-language interface for exploring structured agricultural data without writing SQL by hand.

PythonFlaskReactMySQLOpenAI API

No verified current runtime screenshot is available. The architecture overview describes the public implementation.

// 01

The problem

Agricultural datasets are structured, but the questions people want to ask are usually plain English. SoilSaint connects the two through a natural-language-to-SQL workflow.

// 02

My contribution

Built the application described in my resume: a Python/Flask pipeline integrating the OpenAI API with MySQL, returning query results through a React interface. The public repository contains the backend and frontend implementation.

// 03

Architecture overview

  1. 01Question in React
  2. 02Flask → OpenAI API → generated SQL
  3. 03MySQL → structured results

Conceptual data flow based on the public README, backend/app.py, and frontend query component. It describes the prototype, not a security-reviewed production deployment.

// 04

Engineering decisions

Connect language to a structured schema

The backend exposes a natural_query POST route. The public implementation separates input preprocessing, SQL generation, query postprocessing, and request handling.

Return data through the interface

The React query component submits a question to the backend and presents the returned data, keeping the model integration on the Python side.

Treat generated SQL as a trust boundary

Model output is not a database permission boundary. A production evolution would require a read-only database role, constrained query validation, time and row limits, and evaluation against known questions. Those protections are recommendations, not claimed completed features.

// 05

Outcome & next steps

A working prototype at its last documented deployment. The README explicitly notes that updates or debugging may be needed before reuse, so this portfolio links the source rather than presenting an always-on demo.

Before another public deployment, validate generated queries against a constrained schema and test incorrect, ambiguous, and adversarial questions. Keep credentials and database access outside the browser.

Sources: supplied resume, public repository README, backend/app.py, and soilSaint/frontend/src/NaturalQuery.js. No farm records or example query results are represented as measured outcomes.

← Back to selected workTalk about the project ↗

Where would you like to go?

Search projects, experience, or contact. Use Tab or arrow keys to explore, Enter to open.