exloop 0.1.0__tar.gz → 0.3.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,8 @@
1
+ dist/
2
+ build/
3
+ *.egg-info/
4
+ __pycache__/
5
+ *.pyc
6
+ .ruff_cache/
7
+ .DS_Store
8
+ # hatchling copies this file into the sdist as it is; keep it free of anything private.
exloop-0.3.0/PKG-INFO ADDED
@@ -0,0 +1,102 @@
1
+ Metadata-Version: 2.5
2
+ Name: exloop
3
+ Version: 0.3.0
4
+ Summary: Human-led exploration skills for any AI tool that reads SKILL.md: a persistent map, structured idea comparison, and a zero-dependency state helper.
5
+ Project-URL: Repository, https://github.com/hzshen88/exloop
6
+ Project-URL: Issues, https://github.com/hzshen88/exloop/issues
7
+ Author: hzshen88
8
+ License-Expression: Apache-2.0
9
+ License-File: LICENSE
10
+ Keywords: claude-code,codex,exploration,human-in-the-loop,research-questions,skill
11
+ Classifier: Development Status :: 3 - Alpha
12
+ Classifier: Intended Audience :: Science/Research
13
+ Classifier: Programming Language :: Python :: 3.11
14
+ Classifier: Programming Language :: Python :: 3.12
15
+ Requires-Python: >=3.11
16
+ Description-Content-Type: text/markdown
17
+
18
+ # exloop
19
+
20
+ **Human-led exploration with a persistent map.** An AI companion that does not answer
21
+ your question for you: it asks one or two honing questions, walks one edge at a time,
22
+ keeps a map of where you have been, and offers the next step that is within reach. When
23
+ you do not yet have enough language or background to form a question, it first offers one
24
+ concrete foothold and lets your response set the direction. When
25
+ several explanations are in play, Idea Lab helps draw, attack, compare, and check them
26
+ without forcing an early winner. Both ship as skills for any AI tool that reads
27
+ `SKILL.md` files — Claude Code, Codex, and the like.
28
+
29
+ ## Installing
30
+
31
+ Most people get exloop by installing [newlife](https://pypi.org/project/newlife/), which
32
+ depends on it:
33
+
34
+ ```bash
35
+ python -m pip install newlife
36
+ newlife start my-research
37
+ ```
38
+
39
+ `start` installs the exloop and Idea Lab skills, together with newlife's own, into every AI tool found
40
+ on the machine.
41
+
42
+ On its own:
43
+
44
+ ```bash
45
+ python -m pip install exloop
46
+ python -c "import exloop; print(exloop.skills_dir())"
47
+ ```
48
+
49
+ and copy the skill directories it contains into your AI tool's skills folder
50
+ (`~/.claude/skills/`, `~/.codex/skills/`, ...).
51
+
52
+ ## Using it
53
+
54
+ Open a folder in your AI tool and say:
55
+
56
+ > Explore this with me: *your curiosity*
57
+
58
+ The AI asks; you answer and decide. The map is kept silently in
59
+ `~/.exloop/explorations/<slug>/`, one folder per exploration — the same folder whichever
60
+ AI tool you switch to, because the identity is the slug, not the chat session. When you
61
+ close an exploration the AI archives the record into your research repository
62
+ (`explorations/<slug>/`). When a boundary has become a decidable question — you can say
63
+ what measurement would make the answer different — the AI says so once, and on your yes
64
+ hands the record to newlife (`questions/<slug>/origin/`), where the preregistration
65
+ discipline takes over.
66
+
67
+ Idea Lab is not a second entry point that must be completed first. It is an optional
68
+ reasoning pattern inside exploration. The AI uses it when competing or underspecified
69
+ explanations need to be made explicit, challenged, and distinguished.
70
+
71
+ ## What is in the package
72
+
73
+ - `skills/exloop/SKILL.md` with its references: the protocol (four events — started,
74
+ marked, pivoted, closed — and the map as their projection), the state model, and a
75
+ bounded evidence-review method that returns source checks to the current exploration.
76
+ - `skills/idea-lab/SKILL.md` with domain profiles for formal theory, empirical and causal
77
+ research, simulation, engineering and product mechanisms, and interpretive research.
78
+ - `skills/exloop/scripts/exploration_state.py`: the zero-dependency helper the skill
79
+ runs — `init`, `mark`, `pivot`, `show`, `close`, `list`, `archive`, `handoff`, and a
80
+ `self-test`.
81
+ - `exloop.skills_dir()`: the one Python function, so that newlife can locate the skill
82
+ files. exloop has no other API and no dependencies.
83
+
84
+ Requires Python 3.11 or newer.
85
+
86
+ ## This repository
87
+
88
+ | Path | What it holds |
89
+ |---|---|
90
+ | `skills/exloop/` | The persistent, human-led exploration skill and state helper. |
91
+ | `skills/idea-lab/` | The optional Draw—Attack—Compare—Check reasoning pattern and domain profiles. |
92
+ | `src/exloop/__init__.py` | `skills_dir()`, the one Python function. |
93
+ | `scripts/install-skill.py` | Installs the master byte for byte into AI tool directories; `--force` to overwrite drifted copies. |
94
+ | `scripts/check_release_artifacts.py` | Refuses to ship anything but the skills: run it on `dist/` before `uv publish`. |
95
+
96
+ ```bash
97
+ python3 skills/exloop/scripts/exploration_state.py self-test
98
+ uv build --out-dir dist && python3 scripts/check_release_artifacts.py dist
99
+ ```
100
+
101
+ The skill is used downstream by [newlife](https://github.com/hzshen88/newlife), which
102
+ depends on this package. Apache-2.0.
exloop-0.3.0/README.md ADDED
@@ -0,0 +1,85 @@
1
+ # exloop
2
+
3
+ **Human-led exploration with a persistent map.** An AI companion that does not answer
4
+ your question for you: it asks one or two honing questions, walks one edge at a time,
5
+ keeps a map of where you have been, and offers the next step that is within reach. When
6
+ you do not yet have enough language or background to form a question, it first offers one
7
+ concrete foothold and lets your response set the direction. When
8
+ several explanations are in play, Idea Lab helps draw, attack, compare, and check them
9
+ without forcing an early winner. Both ship as skills for any AI tool that reads
10
+ `SKILL.md` files — Claude Code, Codex, and the like.
11
+
12
+ ## Installing
13
+
14
+ Most people get exloop by installing [newlife](https://pypi.org/project/newlife/), which
15
+ depends on it:
16
+
17
+ ```bash
18
+ python -m pip install newlife
19
+ newlife start my-research
20
+ ```
21
+
22
+ `start` installs the exloop and Idea Lab skills, together with newlife's own, into every AI tool found
23
+ on the machine.
24
+
25
+ On its own:
26
+
27
+ ```bash
28
+ python -m pip install exloop
29
+ python -c "import exloop; print(exloop.skills_dir())"
30
+ ```
31
+
32
+ and copy the skill directories it contains into your AI tool's skills folder
33
+ (`~/.claude/skills/`, `~/.codex/skills/`, ...).
34
+
35
+ ## Using it
36
+
37
+ Open a folder in your AI tool and say:
38
+
39
+ > Explore this with me: *your curiosity*
40
+
41
+ The AI asks; you answer and decide. The map is kept silently in
42
+ `~/.exloop/explorations/<slug>/`, one folder per exploration — the same folder whichever
43
+ AI tool you switch to, because the identity is the slug, not the chat session. When you
44
+ close an exploration the AI archives the record into your research repository
45
+ (`explorations/<slug>/`). When a boundary has become a decidable question — you can say
46
+ what measurement would make the answer different — the AI says so once, and on your yes
47
+ hands the record to newlife (`questions/<slug>/origin/`), where the preregistration
48
+ discipline takes over.
49
+
50
+ Idea Lab is not a second entry point that must be completed first. It is an optional
51
+ reasoning pattern inside exploration. The AI uses it when competing or underspecified
52
+ explanations need to be made explicit, challenged, and distinguished.
53
+
54
+ ## What is in the package
55
+
56
+ - `skills/exloop/SKILL.md` with its references: the protocol (four events — started,
57
+ marked, pivoted, closed — and the map as their projection), the state model, and a
58
+ bounded evidence-review method that returns source checks to the current exploration.
59
+ - `skills/idea-lab/SKILL.md` with domain profiles for formal theory, empirical and causal
60
+ research, simulation, engineering and product mechanisms, and interpretive research.
61
+ - `skills/exloop/scripts/exploration_state.py`: the zero-dependency helper the skill
62
+ runs — `init`, `mark`, `pivot`, `show`, `close`, `list`, `archive`, `handoff`, and a
63
+ `self-test`.
64
+ - `exloop.skills_dir()`: the one Python function, so that newlife can locate the skill
65
+ files. exloop has no other API and no dependencies.
66
+
67
+ Requires Python 3.11 or newer.
68
+
69
+ ## This repository
70
+
71
+ | Path | What it holds |
72
+ |---|---|
73
+ | `skills/exloop/` | The persistent, human-led exploration skill and state helper. |
74
+ | `skills/idea-lab/` | The optional Draw—Attack—Compare—Check reasoning pattern and domain profiles. |
75
+ | `src/exloop/__init__.py` | `skills_dir()`, the one Python function. |
76
+ | `scripts/install-skill.py` | Installs the master byte for byte into AI tool directories; `--force` to overwrite drifted copies. |
77
+ | `scripts/check_release_artifacts.py` | Refuses to ship anything but the skills: run it on `dist/` before `uv publish`. |
78
+
79
+ ```bash
80
+ python3 skills/exloop/scripts/exploration_state.py self-test
81
+ uv build --out-dir dist && python3 scripts/check_release_artifacts.py dist
82
+ ```
83
+
84
+ The skill is used downstream by [newlife](https://github.com/hzshen88/newlife), which
85
+ depends on this package. Apache-2.0.
@@ -0,0 +1,43 @@
1
+ [project]
2
+ name = "exloop"
3
+ version = "0.3.0"
4
+ description = "Human-led exploration skills for any AI tool that reads SKILL.md: a persistent map, structured idea comparison, and a zero-dependency state helper."
5
+ readme = "README.md"
6
+ license = "Apache-2.0"
7
+ license-files = ["LICENSE"]
8
+ requires-python = ">=3.11"
9
+ authors = [{ name = "hzshen88" }]
10
+ keywords = ["exploration", "research-questions", "skill", "claude-code", "codex", "human-in-the-loop"]
11
+ classifiers = [
12
+ "Development Status :: 3 - Alpha",
13
+ "Intended Audience :: Science/Research",
14
+ "Programming Language :: Python :: 3.11",
15
+ "Programming Language :: Python :: 3.12",
16
+ ]
17
+ dependencies = []
18
+
19
+ [project.urls]
20
+ Repository = "https://github.com/hzshen88/exloop"
21
+ Issues = "https://github.com/hzshen88/exloop/issues"
22
+
23
+ [build-system]
24
+ requires = ["hatchling"]
25
+ build-backend = "hatchling.build"
26
+
27
+ # The masters are under skills/ at the repository top, the copies people read and edit; the
28
+ # wheel carries byte copies under exloop/skills/, located via `import exloop; exloop.skills_dir()`.
29
+ # newlife's `skills install` uses that to install the exploration skills alongside its own,
30
+ # without importing any exloop code.
31
+ [tool.hatch.build.targets.wheel]
32
+ packages = ["src/exloop"]
33
+
34
+ [tool.hatch.build.targets.wheel.force-include]
35
+ "skills/exloop" = "exloop/skills/exloop"
36
+ "skills/idea-lab" = "exloop/skills/idea-lab"
37
+
38
+ # The sdist uses only-include, not include: include patterns are gitignore-style and unanchored,
39
+ # so "README.md" would match every README.md in the tree. only-include takes exactly these paths.
40
+ # scripts/check_release_artifacts.py compares the built artifacts file by file and must pass
41
+ # before anything is published.
42
+ [tool.hatch.build.targets.sdist]
43
+ only-include = ["src/exloop", "skills/exloop", "skills/idea-lab", "README.md", "LICENSE", "pyproject.toml"]
@@ -36,23 +36,21 @@ Before the first substantive reply, read
36
36
  [references/protocol.md](references/protocol.md). It contains the interaction
37
37
  rules and the observed failure modes this skill must resist.
38
38
 
39
- ## Before the first exploration in a research repository: set things up yourself
39
+ ## Set up only the persistence the person requested
40
40
 
41
- The person should never have to type a shell command. If the conversation is happening
42
- inside a research repository (or the person wants their explorations and questions kept
43
- somewhere), do the setup for them, telling them in one line what you are doing:
41
+ The person should never have to type a shell command. Conversation-only exploration needs
42
+ no setup. Sustained exploration uses the helper already shipped with exloop; initialize its
43
+ map and continue without installing NewLife.
44
44
 
45
- 1. `newlife` missing from PATH? Install it: `uv tool install newlife` (fallback:
46
- `pipx install newlife`, then `python3 -m pip install --user newlife`). It brings the
47
- `exloop` package along, so this skill's helper and the two newlife skills arrive too.
48
- 2. Not yet a research repository (no `NEXT.md`)? Run `newlife start .` in it — git init,
49
- `.gitignore`, `NEXT.md`, and the skills installed into every AI tool found. If it
50
- reports a missing git identity, ask the person for a name and email once and set them.
51
- 3. Then continue as below. Every later command — `newlife init`, `pilot`, `freeze`, `run`,
52
- `check`, `audit`, this skill's `archive` and `handoff` — is yours to run at the moment
53
- the skills say so; the person only decides.
45
+ If the person explicitly asks to establish the full NewLife research workflow, install a
46
+ compatible NewLife package and run `newlife start .` in the named repository. Say what will
47
+ be installed and where before changing the environment. A request to explore, keep an
48
+ exloop map, verify a source, or archive into an existing research repository does not by
49
+ itself authorize another package or host-wide skill installation.
54
50
 
55
- Say what you installed and where; never install anything else on the strength of this.
51
+ Run exloop's own helper commands when their documented trigger occurs. Offer `newlife init`
52
+ and formal handoff only when NewLife is available and the person chooses to formalize the
53
+ boundary.
56
54
 
57
55
  ## What you make while exploring goes into the research repository, not a temp directory
58
56
 
@@ -86,12 +84,21 @@ exactly how one exploration in 2026-08 ended up in three directories.
86
84
 
87
85
  ## Core loop
88
86
 
87
+ Before step one, check whether the person can enter the question yet. If they want to
88
+ explore but lack the language, background or current state to form a usable question, use
89
+ the **receive — offer one foothold — return direction** move in
90
+ [the protocol](references/protocol.md). This is a conditional opening move, not a new stage,
91
+ profile or state transition. Skip it when the person already has a direction or wants a
92
+ direct answer.
93
+
89
94
  1. **Hone the question.** If the curiosity is vague, ask one high-leverage
90
95
  question and offer a sharper restatement. Ask at most two rounds. If the
91
96
  person says to start, stop honing immediately.
92
97
  2. **Advance one edge.** Add one mechanism, distinction, counterexample, or
93
98
  piece of evidence—not a complete lecture. Match complexity to the person's
94
- language and corrections.
99
+ language and corrections. When a material factual or novelty claim needs a
100
+ source, use [the bounded evidence review](references/evidence-review.md) and
101
+ return its evidence to this same edge; lookup is not a stage transition.
95
102
  3. **Name what is forming.** When the person offers an inchoate judgment from
96
103
  experience, give it a short reusable name and connect it to a mechanism.
97
104
  4. **Challenge the claim, not the person.** Restate the claim before testing it.
@@ -103,6 +110,30 @@ exactly how one exploration in 2026-08 ended up in three directories.
103
110
  boundaries. They are proposals, not a menu the person must select. A new
104
111
  judgment or fact from the person may legitimately redirect the exploration.
105
112
 
113
+ ## When several explanations are live
114
+
115
+ **REQUIRED SUB-SKILL:** Use `idea-lab` when one observation supports two or more
116
+ plausible mechanisms, the person asks to compare explanations, or a favored story
117
+ needs alternatives before formal framing.
118
+
119
+ Idea Lab is a reasoning pattern inside this exploration, not a stage before or
120
+ after exloop. Do not ask the person to choose between them, start a second
121
+ exploration, or make them complete a four-step worksheet. Exloop continues to own
122
+ the conversation, persistent state, pivots, and handoff; Idea Lab supplies the
123
+ Draw—Attack—Compare—Check structure one useful edge at a time.
124
+
125
+ In sustained mode, project its useful changes into the existing map rather than
126
+ inventing a parallel ledger:
127
+
128
+ - a live candidate explanation is a `node`;
129
+ - a missing discriminator or unsupported premise is `stuck`;
130
+ - a mechanism that survives and transfers is a `framework`;
131
+ - a rejected route, with its reason, is `abandoned`;
132
+ - a reversal or unexpected connection is a `surprise`.
133
+
134
+ Do not mark every row of an Idea Lab board. Preserve only changes that matter to
135
+ future conversation.
136
+
106
137
  ## Human control and pivots
107
138
 
108
139
  - Never change the exploration target merely because another direction looks
@@ -135,8 +166,8 @@ artifact:
135
166
  paths, surprises, and pivots;
136
167
  - state what evidence was observed versus inferred;
137
168
  - record closure in sustained mode (`close`), then copy the record into the
138
- person's **research repository** — the one `newlife start` created, the one
139
- that holds `questions/` — with `archive --repo <research repo>`: it lands in
169
+ person's named **research repository** — including one created by `newlife start` —
170
+ with `archive --repo <research repo>`: it lands in
140
171
  `explorations/<slug>/process/` there, and the first time it also writes the
141
172
  four-section `README.md` skeleton and an empty `artifacts/`. The archive folder
142
173
  carries the same slug as the workbench, so the two never disagree about which
@@ -165,6 +196,15 @@ switch to a workflow that locks the hypothesis, analysis, prediction, and
165
196
  decision rule first. Label anything already inspected as exploratory. Anything
166
197
  run during the exploration counts as *seen* for a later preregistration.
167
198
 
199
+ **The line is not "do not look at data".** Exploration looks at data — that is its job, and
200
+ a hypothesis grown out of what you saw is exactly what it is meant to produce. The line
201
+ falls one step later: once the question is handed off, **the hypothesis and the direction
202
+ you expect must be written down before the pilot runs**, because the pilot looks at every
203
+ quantity a criterion names and may hand you the answer before anything is frozen. Changing
204
+ the hypothesis after that point is HARKing, even though changing it before was the method.
205
+ `newlife-goal` §3 says what must be fixed by then; the second half of `newlife-prereg`
206
+ rule one says what to do when the pilot has already answered the main criterion.
207
+
168
208
  ## Authorization boundary
169
209
 
170
210
  This skill changes conversational behavior and, in sustained mode, writes only
@@ -0,0 +1,63 @@
1
+ # Bounded evidence review
2
+
3
+ Use this reference when a claim inside an exploration materially depends on a source,
4
+ prior method, factual precedent, or novelty judgment. It is an operation inside the current
5
+ conversation or exploration, not a new stage.
6
+
7
+ ## Start with a bounded question
8
+
9
+ Write down, in one sentence each:
10
+
11
+ - the exact claim to check;
12
+ - what current choice or candidate route the answer could change;
13
+ - what would count as enough evidence for that choice.
14
+
15
+ If the request already supplies these, use them. Do not interview the person again. If the
16
+ claim is incidental and cannot change the work, mark it unverified and continue rather than
17
+ opening an unbounded survey.
18
+
19
+ ## Gather evidence in this order
20
+
21
+ 1. Check the current repository, cited artifact and prior work already supplied. Preserve
22
+ exact paths, versions and dates.
23
+ 2. When external lookup is authorized and needed, prefer primary sources: the paper for a
24
+ scientific claim, official documentation or source code for a technical claim, and the
25
+ original dataset/registry for a data claim.
26
+ 3. Read enough of the method and limitations to test the exact claim. A title, abstract,
27
+ search snippet or secondary paraphrase is not evidence for a precise implementation or
28
+ boundary claim.
29
+ 4. Seek the strongest relevant counterexample or conflicting source. Explain differences
30
+ in population, mechanism, implementation, measurement or date rather than averaging
31
+ incompatible evidence into one confidence label.
32
+ 5. Record what was directly observed, what is inferred, and what remains unknown. “No
33
+ source found” means unresolved, never novel or false.
34
+
35
+ For a broad question, split independent searches only when the available host and the
36
+ person's request allow delegation. Sequential work is equally valid. Report every
37
+ pre-specified branch, including disconfirming evidence; do not search variants until one
38
+ supports the favored route.
39
+
40
+ ## Return to the caller
41
+
42
+ Return a compact evidence packet:
43
+
44
+ ```markdown
45
+ **Claim checked:** <exact claim>
46
+ **Finding:** supported | contradicted | mixed | unresolved
47
+ **Evidence:** <source, version/date, and the fact it establishes>
48
+ **Limits:** <what the evidence does not establish>
49
+ **Effect on the current exploration:** <which route/assumption changed, or none>
50
+ ```
51
+
52
+ Then resume the question or comparison that requested the check. Do not create a formal
53
+ question, analysis plan, preregistration, repository edit or new persistent ledger merely
54
+ because the lookup finished. Those actions require their own request or transition.
55
+
56
+ ## Provenance
57
+
58
+ This bounded form adapts the useful source-grounding and anti-cherry-picking principles in
59
+ K-Dense's Science-Superpowers `surveying-prior-work` and
60
+ `dispatching-parallel-investigations`, pinned for this integration at commit
61
+ `ccc1b2d41a389b2d6dadf1945603f81d66c5e85e` (MIT). The text and stage boundaries here are
62
+ specific to exloop and were rewritten for its single-state workflow.
63
+
@@ -17,6 +17,25 @@ Do not fill all four slots mechanically. A short question can be the whole turn.
17
17
  The purpose is to advance one edge and leave room for the person to supply the
18
18
  fact or judgment that changes the target.
19
19
 
20
+ ## Make the question enterable when needed
21
+
22
+ Use this opening move only when the person wants to explore but lacks the language,
23
+ background or current state needed to form a usable question:
24
+
25
+ 1. **Receive.** Reflect the curiosity or difficulty without classifying the person. If they
26
+ explicitly sound tired or overwhelmed, reduce the ambition of the turn and leave stopping
27
+ as a valid path.
28
+ 2. **Offer one foothold.** Give one concrete example, distinction or minimal model they can
29
+ inspect. Supply only enough common ground for them to participate, not a prerequisite
30
+ lecture.
31
+ 3. **Return direction.** Ask what in that foothold feels alive, strange or connected to
32
+ their experience. Treat their answer, correction or rejection as the source of the
33
+ direction, then enter the ordinary exploration loop.
34
+
35
+ Do not use an intake questionnaire, assign a readiness level, persist a deficit judgment or
36
+ require a research-shaped question. Skip this move when the person already has a direction
37
+ or only wants a direct answer.
38
+
20
39
  ## Hone without turning it into intake
21
40
 
22
41
  - Infer complexity from the person's language; do not ask for age, credentials,
@@ -105,6 +124,7 @@ an experiment, a decision, a design, or simply a map to resume later.
105
124
  | “They ignored my options, so I should ask again.” | Unselected candidates remain open; continue with the person's new material. |
106
125
  | “They changed topics, so the old path is abandoned.” | Silence or topic movement is not abandonment; retire only explicit or structurally obsolete paths. |
107
126
  | “I cannot paraphrase this, but the person has not said they are confused.” | Record the assistant's own blockage as `stuck`; it identifies missing structure. |
127
+ | “They cannot answer my honing question, so I should diagnose their readiness or ask for background.” | Offer one concrete foothold, let their response supply direction, and keep any inference temporary and correctable. |
108
128
  | “This new direction is clearly better, so I can pivot.” | Only the person's new target supplies the pivot; the assistant may detect and record it, not invent it. |
109
129
  | “More explanation is more helpful.” | Prefer one mechanism and one pressure test; verbosity can bury the person's contribution. |
110
130
  | “A polished synthesis proves the exploration succeeded.” | Preserve unresolved boundaries and discarded paths; do not rewrite the route as inevitable. |
@@ -109,8 +109,8 @@ Render or inspect the current map (do this at the start of every resumed turn):
109
109
  python3 $H/scripts/exploration_state.py show --id 2026-09-05-university-after-ai
110
110
  ```
111
111
 
112
- Record explicit closure, then copy the record into the person's research
113
- repository (the one `newlife start` created):
112
+ Record explicit closure, then copy the record into the person's named research
113
+ repository (which may be one `newlife start` created):
114
114
 
115
115
  ```bash
116
116
  python3 $H/scripts/exploration_state.py close --id 2026-09-05-university-after-ai \
@@ -9,8 +9,8 @@ thread id** — that is how one exploration ended up scattered across
9
9
  `~/.codex/explorations/<thread>/` and `~/.workbuddy/explorations/<session>/`
10
10
  in 2026-08, and why the tool-specific defaults were removed.
11
11
 
12
- Where the record goes when the exploration ends is the **research repository** (the one
13
- `newlife start` creates): `archive --repo` puts it under `explorations/<slug>/process/`,
12
+ Where the record goes when the exploration ends is the person's named **research repository**
13
+ (including one created by `newlife start`): `archive --repo` puts it under `explorations/<slug>/process/`,
14
14
  `handoff --repo` under `questions/<slug>/origin/`. Not the exloop repository.
15
15
  """
16
16
 
@@ -431,8 +431,8 @@ def command_list(args: argparse.Namespace) -> None:
431
431
  def _target(args: argparse.Namespace, ident: str, default_rel: str) -> Path:
432
432
  """Where an archive or handoff lands: `--to <dir>` verbatim, or derived from `--repo`.
433
433
 
434
- `--repo` is the research repository — the same one `newlife start` created and the
435
- one that holds `questions/`. The archive goes to `explorations/<slug>/process/` there,
434
+ `--repo` is the person's named research repository. The archive goes to
435
+ `explorations/<slug>/process/` there,
436
436
  the handoff to `questions/<slug>/origin/`; same slug on both sides, so the two never
437
437
  disagree about which exploration a question came from.
438
438
  """
@@ -0,0 +1,179 @@
1
+ ---
2
+ name: idea-lab
3
+ description: Use when an open-ended research, mechanism, or design question has competing or underspecified explanations and the person is not ready for formal framing or execution. Not for direct factual answers, implementation, debugging, or confirmatory analysis.
4
+ ---
5
+
6
+ # Idea Lab
7
+
8
+ Use **Draw—Attack—Compare—Check** to turn an intuition into a small portfolio of explanations
9
+ whose differences can be discussed and eventually tested. This is an exploratory
10
+ reasoning pattern, not an evidence-producing or confirmatory workflow.
11
+
12
+ The person owns the question, target, and consequential choices. Do not replace
13
+ their original idea merely because another route is easier to formalize.
14
+
15
+ ## Fit with the exploration workflow
16
+
17
+ - For a short exchange, use this pattern in conversation only.
18
+ - **REQUIRED SUB-SKILL:** Use `exloop` when the person asks for sustained
19
+ exploration, a persistent map, or a handoff into a research repository.
20
+ - When source verification, prior art, or a novelty judgment becomes material,
21
+ follow [the bounded evidence review](../exloop/references/evidence-review.md),
22
+ then return to this comparison. It does not advance the workflow.
23
+ - Hand off to `newlife-goal` only when the person can say what observation or
24
+ measurement would make the answer different.
25
+
26
+ “Plan the next step” means the next exploratory discriminator while this skill is
27
+ active. It does not by itself authorize a transition into study design,
28
+ preregistration, implementation, or intervention. Name the possible handoff and
29
+ let the person choose it.
30
+
31
+ Anything observed, computed, or read during Idea Lab is exploratory and therefore
32
+ *seen* for any later preregistration. This skill never freezes a hypothesis, runs a
33
+ confirmatory analysis, or promotes an explored result to confirmation.
34
+
35
+ ## Choose the domain profile
36
+
37
+ Classify by the dominant inferential risk, not by the researcher's department.
38
+ Read only the one profile that fits:
39
+
40
+ - [formal theory](references/formal-theory.md);
41
+ - [empirical or causal research](references/empirical-causal.md);
42
+ - [simulation or computational research](references/simulation-computational.md);
43
+ - [engineering or product mechanisms](references/engineering-product.md);
44
+ - [interpretive or historical research](references/interpretive-historical.md);
45
+ - [generic mechanism exploration](references/generic.md) when none dominates.
46
+
47
+ If two profiles genuinely apply, state the boundary and use only the relevant
48
+ checks from each. Do not duplicate the whole workflow.
49
+
50
+ ## Draw — make the alternatives explicit
51
+
52
+ Preserve the person's idea as one candidate. Add only enough alternatives to
53
+ expose the consequential uncertainty—usually two to four live candidates, never
54
+ cosmetic rewrites of the same story.
55
+
56
+ For each candidate, make explicit:
57
+
58
+ - the claim in one sentence;
59
+ - the mechanism chain: what changes what;
60
+ - necessary assumptions;
61
+ - an expected pattern if it is right;
62
+ - a boundary or observation that would weaken it.
63
+
64
+ Include a reversed mechanism, selection effect, measurement artifact, or null
65
+ explanation when one is genuinely plausible. Do not manufacture symmetry merely
66
+ to fill a list.
67
+
68
+ ## Attack — challenge before repairing
69
+
70
+ Attack each candidate on its own terms. Ask for the cheapest decisive weakness:
71
+ a counterexample, violated invariant, hidden assumption, scope boundary, rival
72
+ mechanism, or artifact that produces the same observation.
73
+
74
+ Keep the roles separate:
75
+
76
+ 1. state the strongest version of the candidate;
77
+ 2. attack that version;
78
+ 3. classify the damage as contradiction, unsupported premise, limited scope, or
79
+ unresolved;
80
+ 4. repair only if the repair yields a new consequence that was not built into it.
81
+
82
+ Do not erase failed routes. Record why they failed so they are not rediscovered
83
+ later. A repair that merely fits the motivating observation is curve-fitting, not
84
+ progress.
85
+
86
+ ## Compare — seek discriminators, not a winner
87
+
88
+ Compare candidates at the point where they predict different observations,
89
+ timings, interventions, counterfactuals, or failure signatures. Prefer the
90
+ cheapest observation that can make one route lose while another survives.
91
+
92
+ Do not rank explanations as “most likely” without evidence tied to the current
93
+ case. General plausibility, familiarity, theoretical elegance, and labels such as
94
+ “typical amplifier” are not case evidence. If the person asks for a ranking that
95
+ the available evidence cannot support, refuse the ranking and state the first
96
+ observation that would change it. Do not invent numerical thresholds.
97
+
98
+ Candidates need not be mutually exclusive. When one is a trigger and another an
99
+ amplifier, represent their composition and identify evidence for each link rather
100
+ than forcing a single winner.
101
+
102
+ ## Check — audit provenance and claimed novelty
103
+
104
+ Maintain these statuses for material claims:
105
+
106
+ | Status | Meaning |
107
+ |---|---|
108
+ | `user` | Supplied by the person |
109
+ | `observed` | Directly seen in a source, code, data, or run |
110
+ | `established` | Supported by verified prior work |
111
+ | `inferred` | Reasoned from stated premises but not independently verified |
112
+ | `unverified` | Plausible factual claim awaiting a source |
113
+ | `candidate-novelty` | A potentially new combination or claim, not yet established as novel |
114
+
115
+ “No source found” never means “novel.” This skill does not itself authorize web
116
+ research, data access, repository edits, or experiments; use the authority in the
117
+ person's request and the appropriate skill.
118
+
119
+ ## Run it as a loop, not a four-part lecture
120
+
121
+ Advance one useful edge per conversational turn. Do not dump every candidate,
122
+ attack, comparison, source question, study design, and preregistration plan at
123
+ once. “Help me explore” or “plan the next step” is not a request for a full board;
124
+ reserve that for an explicit request for a synthesis, matrix, or complete map.
125
+
126
+ After identifying the first useful discriminator, stop at that boundary. Do not
127
+ specify randomization, estimators, sample sizes, success thresholds, or a frozen
128
+ hypothesis unless the person explicitly chooses to leave Idea Lab for formal
129
+ framing or design.
130
+
131
+ Loop back when:
132
+
133
+ - an attack changes a candidate's mechanism;
134
+ - candidates make the same observable prediction;
135
+ - prior work collapses a supposed distinction;
136
+ - a new observation opens a materially different route.
137
+
138
+ Stop adding branches when four or five live routes are open, or when several turns
139
+ add routes without choosing, resolving, or retiring one. Inventory instead.
140
+
141
+ ## Compact board for synthesis or handoff
142
+
143
+ When the person asks for a synthesis, or a boundary is ready for `newlife-goal`,
144
+ render only what has actually been developed:
145
+
146
+ ```markdown
147
+ ## Current question
148
+ <question and scope>
149
+
150
+ ## Candidate routes
151
+ | Route | Mechanism | Necessary assumptions | Expected pattern | Status |
152
+
153
+ ## Attack ledger
154
+ | Route | Strongest attack | Damage | Repair or reason retained |
155
+
156
+ ## Discriminators
157
+ | Observation or intervention | Route A predicts | Route B predicts | Seen or unobserved |
158
+
159
+ ## Source ledger
160
+ | Claim | Provenance status | Source or missing check |
161
+
162
+ ## Open boundary
163
+ <the one missing distinction, fact, or judgment that most changes the next step>
164
+ ```
165
+
166
+ The board is a map, not a scorecard. Preserve incompatible live routes, abandoned
167
+ routes, and unresolved provenance. End with one reachable next edge, not a verdict.
168
+
169
+ ## Self-check
170
+
171
+ - Did the person's original idea remain visible?
172
+ - Are the candidates mechanistically different rather than differently worded?
173
+ - Did every surviving route face a real attack?
174
+ - Is there at least one discriminator, or an explicit statement that none is known?
175
+ - Are trigger and amplifier separated where relevant?
176
+ - Are factual support, inference, and possible novelty visibly distinct?
177
+ - Did the exploration avoid inventing a threshold or jumping into confirmation?
178
+ - If asked to rank, was the ranking supported by current case evidence rather than
179
+ a generic story about what is common?
@@ -0,0 +1,4 @@
1
+ interface:
2
+ display_name: "Idea Lab"
3
+ short_description: "Explore ideas through draw, attack, compare, check"
4
+ default_prompt: "Use $idea-lab to turn this intuition into competing explanations and find what would distinguish them."
@@ -0,0 +1,19 @@
1
+ # Empirical and causal research profile
2
+
3
+ **Draw:** population, unit, exposure or treatment, outcome construct, time order,
4
+ estimand, and a causal graph or verbal equivalent. Keep data-generating mechanisms
5
+ separate from measurement mechanisms.
6
+
7
+ **Attack:** confounding, reverse causation, selection, attrition, interference,
8
+ measurement non-equivalence, post-treatment conditioning, researcher degrees of
9
+ freedom, and external-validity limits.
10
+
11
+ **Compare:** observations that distinguish mechanisms—timing, negative controls,
12
+ heterogeneous predictions, natural or randomized variation, and measurements that
13
+ do not reuse the motivating outcome. At this stage, identify the discriminator;
14
+ do not turn it into a full design.
15
+
16
+ **Check:** label all already-viewed outcomes as seen. Do not turn an exploratory
17
+ chart into a confirmatory direction on the same data. When the person chooses to
18
+ move toward testing, use fresh or protected evidence under the preregistration
19
+ workflow.
@@ -0,0 +1,17 @@
1
+ # Engineering and product mechanism profile
2
+
3
+ **Draw:** users or components, state transitions, interfaces, timing, feedback
4
+ loops, incentives, and observability. Separate initiating faults from propagation
5
+ and amplification.
6
+
7
+ **Attack:** race conditions, stale state, correlated clients, retries, partial
8
+ failure, telemetry gaps, survivorship, rollout interaction, and mitigation that
9
+ masks rather than identifies the cause.
10
+
11
+ **Compare:** event ordering, trace signatures, invariants, controlled fault
12
+ injection, canaries, and reversible changes. A safe mitigation may be worthwhile
13
+ without proving the root cause; label those outcomes separately.
14
+
15
+ **Check:** ground claims in the actual request path, logs, code, and deployed
16
+ configuration. Do not infer probability from a generic failure pattern and do not
17
+ invent a success threshold from intuition.
@@ -0,0 +1,16 @@
1
+ # Formal theory profile
2
+
3
+ **Draw:** primitives, actors, information, timing, feasible actions, objectives,
4
+ solution concept, and predicted comparative statics. Seek minimal models that
5
+ differ in one consequential assumption.
6
+
7
+ **Attack:** consistency of primitives; existence and multiplicity; hidden
8
+ regularity assumptions; degenerate cases; sign reversals; whether the claimed
9
+ result is encoded directly in an assumption; counterexamples at the boundary.
10
+
11
+ **Compare:** theorem statements, counterexamples, comparative statics, welfare
12
+ ranking, or a prediction that survives when a disputed assumption is relaxed.
13
+
14
+ **Check:** distinguish a known theorem, an adaptation of an established model, a
15
+ new proof route, and a candidate-new proposition. Mathematical validity and
16
+ literature novelty are separate questions.
@@ -0,0 +1,14 @@
1
+ # Generic mechanism profile
2
+
3
+ Use when no specialized inferential risk dominates.
4
+
5
+ **Draw:** actors or objects, state, mechanism chain, assumptions, expected change.
6
+
7
+ **Attack:** missing link, reverse direction, common cause, boundary case,
8
+ measurement artifact, or a null process that yields the same observation.
9
+
10
+ **Compare:** identify a timing, intervention, counterfactual, or failure signature
11
+ on which the candidates diverge.
12
+
13
+ **Check:** separate what the person supplied, what was observed, what was inferred,
14
+ and what remains unverified.
@@ -0,0 +1,16 @@
1
+ # Interpretive and historical research profile
2
+
3
+ **Draw:** candidate interpretations, relevant actors, chronology, proposed motives
4
+ or structures, scope, and the source base each interpretation needs.
5
+
6
+ **Attack:** anachronism, source dependence, archival silence, survivorship,
7
+ translation or category drift, hindsight, and whether the account explains only
8
+ selected cases.
9
+
10
+ **Compare:** contradictory primary sources, chronology, coverage of difficult
11
+ cases, assumptions required, and whether one interpretation explains evidence the
12
+ other treats as exceptional.
13
+
14
+ **Check:** record source type, date, authorship, transmission, independence, and
15
+ contestation. Do not force statistical falsifiability onto a conceptual or
16
+ interpretive claim; demand source-sensitive constraints instead.
@@ -0,0 +1,16 @@
1
+ # Simulation and computational research profile
2
+
3
+ **Draw:** entities, state variables, update rules, scheduler, environment,
4
+ stochasticity, scale, initialization, and observables. Separate properties imposed
5
+ by construction from behavior decided by running.
6
+
7
+ **Attack:** implementation artifact, scheduler dependence, initial-condition
8
+ dependence, finite-size effect, seed instability, parameter tuning, insufficient
9
+ power, invalid proxy, and a control that cannot actually turn red.
10
+
11
+ **Compare:** analytic limits, matched controls, mechanism ablations, sensitivity
12
+ surfaces, seed ensembles, scaling behavior, and out-of-calibration predictions.
13
+
14
+ **Check:** every number must be traceable to an artifact and configuration. Runs
15
+ inside Idea Lab are exploratory and seen; they cannot later serve as blind
16
+ confirmation.
@@ -1,11 +1,11 @@
1
1
  """exloop — human-led exploration with a persistent map.
2
2
 
3
3
  This package exists so that installing newlife (which will depend on it) puts the
4
- exloop skill on the machine without a trip to GitHub. It ships the skill files
4
+ exploration skills on the machine without a trip to GitHub. It ships the skill files
5
5
  and the zero-dependency state helper the skill uses, and nothing else. newlife never
6
6
  imports exloop's code: the interface between the two is files — `handoff` writes into a
7
- newlife question's `origin/`. The skill master is `skills/exloop/` in the exloop
8
- repository; the wheel carries a byte copy under `exloop/skills/`.
7
+ newlife question's `origin/`. The skill masters are under `skills/` in the exloop
8
+ repository; the wheel carries byte copies under `exloop/skills/`.
9
9
  """
10
10
 
11
11
  from __future__ import annotations
@@ -16,7 +16,7 @@ __all__ = ["skills_dir"]
16
16
 
17
17
 
18
18
  def skills_dir() -> Path:
19
- """The directory holding the skill masters (`exloop/SKILL.md` and friends).
19
+ """The directory holding the skill masters (`exloop/`, `idea-lab/`, and friends).
20
20
 
21
21
  In an installed wheel it is `exloop/skills/`, force-included at build time. In an
22
22
  editable checkout the files are the repository's own `skills/`, two levels up from this
exloop-0.1.0/.gitignore DELETED
@@ -1,20 +0,0 @@
1
- node_modules/
2
- dist/
3
- build/
4
- *.egg-info/
5
- *.log
6
- .DS_Store
7
- __pycache__/
8
- .ruff_cache/
9
- *.pyc
10
- .gstack/
11
-
12
- # Local scratch and tool caches, never versioned
13
- tmp/
14
- output/
15
- .workbuddy/
16
- AGENTS.md
17
-
18
- # hatchling copies this file into the sdist as it is, so no path under the sealed
19
- # exploration archive is named here; per-exploration derived caches (npz, wiki caches)
20
- # are listed in the local .git/info/exclude instead.
exloop-0.1.0/PKG-INFO DELETED
@@ -1,72 +0,0 @@
1
- Metadata-Version: 2.5
2
- Name: exloop
3
- Version: 0.1.0
4
- Summary: Human-led exploration with a persistent map: the exloop skill for any AI tool that reads SKILL.md, plus the zero-dependency state helper it uses.
5
- Author: hzshen88
6
- License-Expression: Apache-2.0
7
- License-File: LICENSE
8
- Keywords: claude-code,codex,exploration,human-in-the-loop,research-questions,skill
9
- Classifier: Development Status :: 3 - Alpha
10
- Classifier: Intended Audience :: Science/Research
11
- Classifier: Programming Language :: Python :: 3.11
12
- Classifier: Programming Language :: Python :: 3.12
13
- Requires-Python: >=3.11
14
- Description-Content-Type: text/markdown
15
-
16
- # exloop
17
-
18
- **Human-led exploration with a persistent map.** An AI companion that does not answer
19
- your question for you: it asks one or two honing questions, walks one edge at a time,
20
- keeps a map of where you have been, and offers the next step that is within reach. It
21
- ships as a skill for any AI tool that reads `SKILL.md` files — Claude Code, Codex, and
22
- the like.
23
-
24
- ## Installing
25
-
26
- Most people get exloop by installing [newlife](https://pypi.org/project/newlife/), which
27
- depends on it:
28
-
29
- ```bash
30
- python -m pip install newlife
31
- newlife start my-research
32
- ```
33
-
34
- `start` installs the exloop skill, together with newlife's own, into every AI tool found
35
- on the machine.
36
-
37
- On its own:
38
-
39
- ```bash
40
- python -m pip install exloop
41
- python -c "import exloop; print(exloop.skills_dir() / 'exloop')"
42
- ```
43
-
44
- and copy the directory that prints into your AI tool's skills folder
45
- (`~/.claude/skills/`, `~/.codex/skills/`, ...).
46
-
47
- ## Using it
48
-
49
- Open a folder in your AI tool and say:
50
-
51
- > Explore this with me: *your curiosity*
52
-
53
- The AI asks; you answer and decide. The map is kept silently in
54
- `~/.exloop/explorations/<slug>/`, one folder per exploration — the same folder whichever
55
- AI tool you switch to, because the identity is the slug, not the chat session. When you
56
- close an exploration the AI archives the record into your research repository
57
- (`explorations/<slug>/`). When a boundary has become a decidable question — you can say
58
- what measurement would make the answer different — the AI says so once, and on your yes
59
- hands the record to newlife (`questions/<slug>/origin/`), where the preregistration
60
- discipline takes over.
61
-
62
- ## What is in the package
63
-
64
- - `skills/exloop/SKILL.md` with its references: the protocol (four events — started,
65
- marked, pivoted, closed — and the map as their projection) and the state model.
66
- - `skills/exloop/scripts/exploration_state.py`: the zero-dependency helper the skill
67
- runs — `init`, `mark`, `pivot`, `show`, `close`, `list`, `archive`, `handoff`, and a
68
- `self-test`.
69
- - `exloop.skills_dir()`: the one Python function, so that newlife can locate the skill
70
- files. exloop has no other API and no dependencies.
71
-
72
- Requires Python 3.11 or newer.
@@ -1,57 +0,0 @@
1
- # exloop
2
-
3
- **Human-led exploration with a persistent map.** An AI companion that does not answer
4
- your question for you: it asks one or two honing questions, walks one edge at a time,
5
- keeps a map of where you have been, and offers the next step that is within reach. It
6
- ships as a skill for any AI tool that reads `SKILL.md` files — Claude Code, Codex, and
7
- the like.
8
-
9
- ## Installing
10
-
11
- Most people get exloop by installing [newlife](https://pypi.org/project/newlife/), which
12
- depends on it:
13
-
14
- ```bash
15
- python -m pip install newlife
16
- newlife start my-research
17
- ```
18
-
19
- `start` installs the exloop skill, together with newlife's own, into every AI tool found
20
- on the machine.
21
-
22
- On its own:
23
-
24
- ```bash
25
- python -m pip install exloop
26
- python -c "import exloop; print(exloop.skills_dir() / 'exloop')"
27
- ```
28
-
29
- and copy the directory that prints into your AI tool's skills folder
30
- (`~/.claude/skills/`, `~/.codex/skills/`, ...).
31
-
32
- ## Using it
33
-
34
- Open a folder in your AI tool and say:
35
-
36
- > Explore this with me: *your curiosity*
37
-
38
- The AI asks; you answer and decide. The map is kept silently in
39
- `~/.exloop/explorations/<slug>/`, one folder per exploration — the same folder whichever
40
- AI tool you switch to, because the identity is the slug, not the chat session. When you
41
- close an exploration the AI archives the record into your research repository
42
- (`explorations/<slug>/`). When a boundary has become a decidable question — you can say
43
- what measurement would make the answer different — the AI says so once, and on your yes
44
- hands the record to newlife (`questions/<slug>/origin/`), where the preregistration
45
- discipline takes over.
46
-
47
- ## What is in the package
48
-
49
- - `skills/exloop/SKILL.md` with its references: the protocol (four events — started,
50
- marked, pivoted, closed — and the map as their projection) and the state model.
51
- - `skills/exloop/scripts/exploration_state.py`: the zero-dependency helper the skill
52
- runs — `init`, `mark`, `pivot`, `show`, `close`, `list`, `archive`, `handoff`, and a
53
- `self-test`.
54
- - `exloop.skills_dir()`: the one Python function, so that newlife can locate the skill
55
- files. exloop has no other API and no dependencies.
56
-
57
- Requires Python 3.11 or newer.
@@ -1,44 +0,0 @@
1
- [project]
2
- name = "exloop"
3
- version = "0.1.0"
4
- description = "Human-led exploration with a persistent map: the exloop skill for any AI tool that reads SKILL.md, plus the zero-dependency state helper it uses."
5
- # The repository README.md is the author's own (Chinese, linking into private directories); PyPI gets its own page.
6
- readme = "README.pypi.md"
7
- license = "Apache-2.0"
8
- license-files = ["LICENSE"]
9
- requires-python = ">=3.11"
10
- authors = [{ name = "hzshen88" }]
11
- keywords = ["exploration", "research-questions", "skill", "claude-code", "codex", "human-in-the-loop"]
12
- classifiers = [
13
- "Development Status :: 3 - Alpha",
14
- "Intended Audience :: Science/Research",
15
- "Programming Language :: Python :: 3.11",
16
- "Programming Language :: Python :: 3.12",
17
- ]
18
- dependencies = []
19
-
20
- [build-system]
21
- requires = ["hatchling"]
22
- build-backend = "hatchling.build"
23
-
24
- # The master is skills/exloop/ at the repository top, the copy people read and edit; the wheel
25
- # carries a byte copy under exloop/skills/, located via `import exloop; exloop.skills_dir()`.
26
- # newlife's `skills install` uses that to install the exploration skill alongside its own,
27
- # without importing any exloop code.
28
- [tool.hatch.build.targets.wheel]
29
- packages = ["src/exloop"]
30
-
31
- [tool.hatch.build.targets.wheel.force-include]
32
- "skills/exloop" = "exloop/skills/exloop"
33
-
34
- # The sdist uses only-include, not include: include patterns are gitignore-style and unanchored,
35
- # so "README.md" matches every README.md in the tree — on 2026-09-06 that pulled the READMEs of
36
- # 13 sealed explorations, docs/science-superpowers and vendor into the sdist. only-include takes
37
- # exactly these paths. scripts/check_release_artifacts.py compares the built artifacts file by
38
- # file and must pass before anything is published.
39
- [tool.hatch.build.targets.sdist]
40
- only-include = ["src/exloop", "skills/exloop", "README.pypi.md", "LICENSE", "pyproject.toml"]
41
- exclude = [".gitignore"]
42
-
43
- # No [project.urls]: the source repository is private and a public reader cannot open it. Point
44
- # here at the clean public repository once it exists (README.md, the paragraph on going public).
File without changes