cpuos

Recipe · python base

SQLite analysis sandbox recipe

A local SQL analysis recipe for uploaded SQLite databases, using read-only inputs, bounded queries and aggregate results for the agent.

When to use this profile

Use a local database snapshot when the agent needs relational analysis without access to the live production database. Open the supplied SQLite file in read-only mode, inspect the schema and run bounded queries. Return aggregates and a compact sample so the model can reason about the answer without receiving an entire customer table.

Prepare a repeatable environment

  • Create a data export with only the rows and columns needed for the task.
  • Open the input through SQLite's read-only URI mode and write derived tables to a separate file.
  • Set query deadlines with a progress handler and impose a maximum result-row count.
Command inside a prepared Linux guest
python /work/query_database.py

Return results the agent can use

  • The SQL query and structured results with column names.
  • CSV exports for approved aggregate tables.
  • A report of rows scanned or returned where the application can measure them.

Query a fixture database, verify a known aggregate and attempt a write that should fail. Include an expensive query to confirm the deadline interrupts it.

Resources and boundaries

Start with 2 vCPU and 4 GB of RAM, then measure peak memory and task duration on a representative fixture. These are workload planning values, not a benchmark or a provisioned configuration. Use the sandbox cost calculator to estimate running time and retained snapshots.

  • Read-only SQL can still be expensive through joins, sorts and recursive queries.
  • Disable loading extensions and avoid attaching arbitrary filesystem paths.
  • A sandbox boundary does not replace data minimization for sensitive database exports.

Keep model inference separate from this execution profile. A hosted model or gpuOS can decide the next action while the CPU environment runs it. The quickstart describes the account workflow and the proposed runtime contract.

Questions

Is this a separate built-in template?
This is a workload recipe based on the python profile. It adds preparation and execution guidance, not a separate built-in image or a new backend runtime.
Can I run the command now?
The command runs in a Linux environment where the listed dependencies and input files are prepared. cpuOS SDK examples describe a proposed contract; confirm runtime access and package versions before integration.
How should I choose CPU and memory?
Use the starting profile to run a representative fixture, measure peak memory and elapsed time, and add room for package installation, worker processes and larger inputs. Enforce a task timeout separately.

Related guides

Plan your sqlite analysis task

Create a workspace and choose a profile. Connect an execution backend before running code.

gpuOS · where models think

Need the model too? Run it on gpuOS

gpuOS serves open models on your own GPUs behind one OpenAI-compatible API. The model reasons on gpuOS, the agent acts in a cpuOS sandbox.