theta-agent0.7.0
Theta — a science co-researcher agent built as a package for the pi coding agent harness
Untested on omp
This is a pi package. No one has reported whether it works on omp yet. If you try it, add your result below.
Reports 0
No reports yet.
Readme
Theta (θ)
A science co-researcher agent for the pi coding-agent harness.
Theta is the fundamental parameter of the coalescent — the standard model of how genetic diversity arises — and the universal symbol for the parameters a model fits. One letter, both halves of "computational biology + AI."
Status
Very early development (0.7.0). The architecture, skill-selection plan, and
milestones are being designed in the open. M1 through M6 are built: the theta
launcher plus the Tier-1 research-loop skill library — K-Dense skills vendored
verbatim plus the self-authored theta-research-loop orchestrator (see
Vendored skills) — the first connector skill,
theta-lit-search (PubMed, arXiv, Semantic Scholar; connectors are skills per
ADR 0002), the
project notebook, theta-notebook (dated provenance entries carrying
content-addressed, graded evidence snapshots, recorded inside the research
loop and after standalone searches per
ADR 0003), and the
compute path — the hebmu-cluster-slurm fixed scripts over the researcher's
own SSH access (ADR 0010),
with the earlier MCP compute gateway theta-compute in its own repository
(hugolld/theta-compute;
ADR 0004) for deployments
that need its server-side audit trail — the M5 safety gates: the gateway's
deploy-time submit capability and per-principal submit ceiling
(ADR 0006), and the
stacked gate framework with its session gate log on the theta side — and the M6
eval suite: the replay net's
sanitized-capture fixtures pinned per model-visible surface class and the
benchmark layer's tasks graded workspace-as-oracle in the rig
(ADR 0007,
docs/agents/eval.md). Past M6, the skill pool landed in steps
(ADR 0008):
Tier-3 domain packs at pool/, vendored verbatim and loaded per research
project through a keyed, gated loader, and the M7a demo slice shipped the
demo surfaces — the notebook entry cards, the /notebook and /roadmap
commands, the /demo-lit-triage prompt template, and the Theta theme.
The milestones below continue from there.
What Theta will be
Describe a scientific task in plain language; Theta plans, searches literature, writes and runs code, executes analyses, and reports results with a visible trace — built as a pi package rather than a monolithic fork:
- Skills: curated science skills (literature review, hypothesis generation, experimental design, statistics, domain libraries) following the open Agent Skills specification
- Connectors: literature and database tools (PubMed, arXiv, UniProt, …) as Theta-owned connector skills
- Compute: remote Slurm-cluster jobs — fixed scripts over your own SSH access by default (ADR 0010), or an MCP compute gateway where a deployment needs its audit trail — with a light local sandbox for small tasks
- Models: any of pi's available providers — bring your own key
Theta works today as a pi package from a checkout. The staged plan (M7–M8)
grows it into a standalone theta application with pi embedded as the core
engine — macOS and Linux first, Windows later.
Roadmap
- M1 — package skeleton,
thetalauncher (bin), Tier-1 research-loop skills - M2 — literature connectors (PubMed, arXiv, Semantic Scholar)
- M3 — project notebook: provenance entries with graded evidence
- M4 — compute: Slurm MCP gateway + typed AlphaFold3 tool
- M5 — safety gates + containerized execution
- M6 — eval suite (MCP client is built into pi)
- M7 — standalone
thetashell on pi's headless core (macOS/Linux) - M8 — installers & release channel: Homebrew, deb/AUR, Windows
Install
pi install npm:theta-agent@0.7.0
Requires theta-agent ≥ 0.7.0 on the registry — 0.3.0 and earlier predate the compute gateway, 0.4.0 predates the M5 safety gates, 0.5.0 predates the eval suite, 0.6.0 predates the HEBMU-first compute path, and a version-pinned install fails loudly until 0.7.0 is visible. If the registry is not there yet, run Theta from a checkout instead — see Try it.
Try it
theta rides on the pi coding agent, and pi is a peer dependency — install it first. The zero-registry path is a checkout:
git clone https://github.com/hugolld/theta-agent
cd theta-agent
npm i -g @earendil-works/pi-coding-agent
node bin/theta.mjs --dev
node bin/theta.mjs --dev launches pi with this checkout preloaded;
from a checkout you can also name another directory with
$THETA_DEV_ROOT (theta never loads an arbitrary current directory
this way). Theta targets pi ≥ 1.4.0; if the launcher reports
pi not found, install pi with the command above and retry.
Once theta-agent ≥ 0.7.0 is on the registry (0.3.0 and earlier predate the compute gateway, 0.4.0 predates the M5 safety gates, 0.5.0 predates the eval suite, and 0.6.0 predates the HEBMU-first compute path — until 0.7.0 is visible, stay on the checkout path above), the installed form is:
npm i -g theta-agent@0.7.0
theta
That launches pi with the Theta package preloaded.
Model routing
A session can route each request through the project's own two-tier model
pool. Routing is opt-in, and nothing routes until the researcher selects
theta:auto like any other model, for example with pi --model theta/auto.
The thinking level is the tier dial. high sends the request to the strong
tier, and low sends it to the cheap tier. The pool lives in
.theta/routing.json in the project:
{
"strong": ["provider-a/model-x"],
"cheap": ["provider-b/model-y"]
}
Both keys are required, the order of a list is the preference, and an empty
list means that tier refuses. Each entry is provider/model-id. A tier with
no reachable model ends the request with a refusal that names the tier and
the file. The policy never substitutes the other tier. A continuation stays
on the model that handled the turn, and a retry stays on the model that
failed (ADR 0009).
Cluster compute over SSH
If you already SSH to your cluster and submit with Slurm, the
hebmu-cluster-slurm skill runs jobs through your own access — no gateway
server, no port-forward, no token
(ADR 0010).
It is the default compute route since spec #221. Setup is one file you own,
outside any repository, on top of access you already have:
Key-based SSH access to the cluster, under your own account — an alias in your
~/.ssh/configthatssh <alias>reaches without a password prompt. The skill never holds a key or a token of its own.A connection config file naming the connection — JSON holding the alias and the absolute cluster path that runs stage under. Placeholder values here; the real ones never belong in a repository:
{ "ssh_host": "<alias>", "runs_root": "<absolute path>" }By default the scripts read
~/.config/theta/cluster.json;THETA_CLUSTER_CONFIGpoints them at a file elsewhere.
With the file in place, a session's compute tasks run through the skill's five
fixed scripts — staging inputs, submitting, polling status, fetching artifacts,
cancelling — and close out as a job record in the project notebook, graded
re-executed once the artifacts came back. The submit and cancel scripts
prompt you for confirmation before they run (the script gate); the other three
run without prompts. A script that refuses before connecting names the failed
check on stderr — a missing or malformed config file, a directive the
allow-list refuses; fix the input and carry on. The compute doctrine
lives in the skill's SKILL.md; the script invariants in
docs/agents/connector-scripts.md.
Compute gateway setup
Cluster compute can also ride the theta-compute compute gateway — an MCP
server deployed on your institution's Slurm cluster, living in its own
repository (hugolld/theta-compute) —
the route for a deployment that needs a server-side audit trail
(ADR 0004). Its server-side
bounds — the deploy-time submit capability and the per-principal submit
ceiling — still hold (ADR 0006);
this package ships no client-side gate for gateway calls since spec #221
(the submit gate retired with the gateway's client surface). The
cluster-side deploy, the port-forward, and the registration recipe are that
repository's: follow its README's deploy steps, ending in the one-time
pi mcp add theta-compute --url http://127.0.0.1:8421/mcp \
--header "Authorization=Bearer <token>"
with the bearer token living only in your own ~/.pi/agent/mcp.json,
never in any repo.
Vendored skills
The research-loop skill library starts from the K-Dense
scientific-agent-skills
library, vendored verbatim per ADR 0001:
upstream names, directory shapes, and content unchanged except a provenance
header in each vendored SKILL.md. Re-syncs happen at milestone boundaries.
Currently vendored (upstream release v2.72.0, commit 526ebce) — the
Tier-1 research-loop set:
literature-review— systematic, scoping, and narrative literature reviews with reproducible searches and citation checkspaper-lookup— searches 18 scholarly APIs for papers, citations, abstracts, and open-access full text with reproducible provenancepaperzilla— reads Paperzilla projects, searches project feeds, and retrieves recommendations and canonical papersbgpt-paper-search— searches BGPT scientific papers by topic or DOI and retrieves claim-level evidence from full textresearch-lookup— compiles current scholarly evidence for manuscripts and research briefs via Parallel Search, Extract, and Researchcitation-management— citation search, metadata validation, and BibTeX generation across OpenAlex, PubMed, and Google Scholarpyzotero— manages Zotero reference libraries through the pyzotero Python client and the Zotero Web APIpeer-review— evidence-bounded, constructive peer-review drafts and structured manuscript assessmentsscholar-evaluation— qualitative-first, evidence-traceable developmental review of scholarly works and research-assessment rubricsscientific-writing— drafts, revises, and audits manuscripts with explicit evidence provenance and reporting-guideline coveragescientific-critical-thinking— evaluates scientific claims and evidence quality: validity, bias, confounders, and evidence gradingscientific-brainstorming— evidence-aware scientific ideation with structured discussion, adversarial review, and decision logshypothesis-generation— evidence-bounded candidate hypotheses, rival explanations, and preregistration-ready analysis planshypogenic— plans and audits LLM-assisted hypothesis generation from labeled text datasets with HypoGeniC/HypoRefineexperimental-design— designs experiments before data collection: randomization, blocking, factorial designs, and treatment layoutsstatistical-analysis— guided test selection, assumption checking, effect sizes, power analysis, and APA-formatted reportingstatistical-power— sample-size and power calculation, closed-form and simulation-based, for study planninguncertainty-and-units— unit tracking and measurement-uncertainty propagation in scientific calculationsexploratory-data-analysis— bounded, local first-pass analysis profiles of supported scientific file formats
The theta-research-loop orchestrator that routes the research loop into the
library is Theta's own, self-authored work.
One deliberate omission: pi-agent, a Tier-1 candidate that documents the pi
harness itself. It would duplicate pi's own documentation, drift against
installed pi releases, and add nothing to the research loop. The skip is
recorded on issue #5.
Skill pool
Theta's skill surface spans the role classes it inherits from K-Dense as
tiers, plus Theta's own skills beside them. The Tier-1 research-loop
core (see Vendored skills) ships in the package and
loads in every session. Tier-2 compute infrastructure stays excluded —
theta-compute replaces K-Dense's compute stack
(ADR 0001). And the third
inherited tier — Tier-3 domain modules, the domain skills a given
research project actually calls — is the skill pool: vendored trees at
pool/, verbatim under the same ADR 0001 rules, organized as one domain
pack per research domain and loaded per research project rather than
shipped in the package
(ADR 0008).
Beside the tiers, the repo's own skills are self-authored: the
connector skills
wrapping scholarly APIs (theta-lit-search), the project notebook
(theta-notebook), and the fixed-script cluster skill
(hebmu-cluster-slurm; the gateway skill retired with the gateway's
client surface at spec #221).
pool/index.md is the map: every skill with its class
column — local (no credential, no spend), key (a credential, no metered
spend), cloud (credential plus metered spend) — verified against each
skill's stated requirements. The loader's machine-readable twin of that
column, pool/classes.json, gates what loads; a per-project state file
(.theta/skills.json) carries each project's pack selection and class
allowance, and only a one-call judgment over the project notebook — firing
once at a keyed session's start, and thereafter only as an explicit owner
act — can widen that allowance beyond local. A keyless session never
widens it: it loads exactly what the committed state admits. The K-Dense
attribution and citation below cover the pool trees too.
First wave (upstream release v2.72.0, commit 526ebce, vendored 2026-11-15):
protein-engineering (5), bioinformatics (32), cheminformatics (11) — 48 skills.
K-Dense's skills are MIT-licensed, © K-Dense Inc. If you use them in research, please cite their paper:
Kassis, T., Agarwal, V., He, Y., Patel, D., & Brueckner, A. M. (2026). Scientific Agent Skills: A Library of Procedural Knowledge for Research Agents. arXiv:2609.00065. https://doi.org/10.48550/arXiv.2609.00065
License
MIT