Who it is forA team member with a GPU machine who runs big jobs that take longer than a laptop session should stay connected.
The problemA long-running LLM job can fail or be lost if the client disconnects while it runs.
The outcomeA saved query on the server that you can watch, reconnect to by query id, and collect results from when it finishes.
What you need first
- Python 3.12
- An NVIDIA CUDA GPU from the supported list (for example H100 SXM)
- uv installed to run the pip install command
- A table of text rows (for example reviews with an id and a body column)
Steps
- On the GPU machine, run
uv pip install "quail-engine[server]"to install the server extra. - Start the HTTP server by running
quail-server. - From the client, open Quail.Session with endpoint set to the server address, then call session.sql(sql, dialect="bq").submit().
- Call run.watch() to print progress, or note the query id and later call get_run(query_id) to reconnect.
- Call run.result().collect() to get the table once the run is done.
Prompt for your agent
Use the repo fsdatalab/quail to submit the SQL query in <sql_file> to a Quail Server at <server_address>, save the query id, and later call get_run to fetch the result table. Output the final table as CSV. Verify that the server returned a completed status before collecting results.
Caveat. The server runs on the machine that has the GPU, so you need network access to that machine and the README does not describe authentication for the endpoint.
Use this in your AI agent
Ask your agent
Using the Deduped MCP, get the setup steps for fsdatalab/quail and "Run a long LLM query on a GPU server and reconnect later"
Add Deduped to Claude Code once
claude mcp add --transport http deduped https://dedupedai.com/mcp
Every Monday: the 5 hottest repos and exactly how to use them. Free, one email a week, unsubscribe anytime.
Get them freeShare: X LinkedIn Hacker News Email Copy link
Third-party repos we don't own. AI-written use cases can be wrong. Disclaimer