Skip to content

Commit b141b64

Browse files
authored
Merge pull request #5 from m0n0x41d/release_3.1.0
release 3.1.0
2 parents d563df7 + b0397c8 commit b141b64

22 files changed

+422
-150
lines changed

CHANGELOG.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,32 @@ All notable changes to Quint Code will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [3.1.0] - 2025-12-14
9+
10+
### Added: Deep Reasoning Capabilities
11+
12+
#### Context Slicing (A.2.6)
13+
- **Structured Context:** `.fpf/context.md` is now structured into explicit slices:
14+
- **Slice: Grounding** (Infrastructure, Region)
15+
- **Slice: Tech Stack** (Language, Frameworks)
16+
- **Slice: Constraints** (Compliance, Budget, Team)
17+
- **Context-Aware Init:** `/q0-init` now scans `package.json`, `Dockerfile`, etc., to auto-populate slices.
18+
19+
#### Explicit Role Injection (A.2)
20+
- **Role-Swapping Prompts:** Commands now enforce specific FPF roles to prevent "AI drift":
21+
- `/q1-hypothesize`: **ExplorerRole** (Creative, Abductive)
22+
- `/q2-check`: **LogicianRole** (Strict, Deductive)
23+
- `/q4-audit`: **AuditorRole** (Adversarial, Normative)
24+
25+
#### Context Drift Analysis
26+
- **New Audit Step:** `/q4-audit` now includes a mandatory **Context Drift Check**.
27+
- **Validation:** Verifies that hypotheses generated in step 1 still match the constraints in step 4 (preventing "works on my machine" architecture).
28+
29+
### Changed
30+
- **Command Prompts:** Updated `q0`, `q1`, `q2`, `q4` to enforce the new reasoning standards.
31+
32+
---
33+
834
## [3.0.0] - 2025-12-14
935

1036
### Major Breaking Change: Rebrand to Quint Code

README.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,6 +217,22 @@ Problem Statement
217217

218218
## Key Concepts
219219

220+
### Deep Reasoning (v3.1)
221+
222+
Quint Code now enforces **Context Slicing** and **Explicit Roles** to prevent "works on my machine" architecture and AI drift.
223+
224+
**1. Context Slicing (A.2.6)**
225+
Truth depends on where you stand. `q0-init` now scans your repo to generate structured slices:
226+
- **Slice: Grounding** (Infrastructure, Region)
227+
- **Slice: Tech Stack** (Language, Frameworks)
228+
- **Slice: Constraints** (Compliance, Budget)
229+
230+
**2. Explicit Role Injection**
231+
The AI isn't just a chatbot; it enacts specific FPF roles per phase:
232+
- **ExplorerRole** (Hypothesize): Creative, divergent.
233+
- **LogicianRole** (Check): Strict, deductive.
234+
- **AuditorRole** (Audit): Adversarial, critical.
235+
220236
### Assurance Levels
221237

222238
| Level | Name | Meaning | How to Reach |

dist/claude/q0-init.md

Lines changed: 22 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -47,25 +47,30 @@ mkdir -p .fpf/sessions
4747
- Ask **specific** questions for what you can't see (Scale, Budget, Constraints).
4848
- *Example:* "I see this is a web app. What is the target user scale? (<1k, >1M?)"
4949

50-
3. **Write `.fpf/context.md`:**
51-
- Combine your findings and the user's answers.
50+
3. **Write `.fpf/context.md` (Context Slicing A.2.6):**
51+
- Combine your findings and the user's answers into structured slices.
5252

5353
```markdown
54-
# Repository Context (A.2.6 Context Slice)
55-
56-
## Tech Stack (Inferred)
57-
- **Language:** [e.g. Python 3.11]
58-
- **Frameworks:** [e.g. Django 4.2]
59-
- **Infra:** [e.g. Docker, AWS]
60-
61-
## Scale & Performance (User-Defined)
62-
- **Users:** [Value]
63-
- **Traffic:** [Value]
64-
- **Latency Target:** [Value]
65-
66-
## Hard Constraints (User-Defined)
67-
- [Constraint 1]
68-
- [Constraint 2]
54+
# Project Context (A.2.6 Context Slice)
55+
56+
## Slice: Grounding (Infrastructure)
57+
> The physical/virtual environment where the code runs.
58+
- **Platform:** [e.g. AWS Lambda / Kubernetes / Vercel]
59+
- **Region:** [e.g. us-east-1]
60+
- **Storage:** [e.g. S3, EBS]
61+
62+
## Slice: Tech Stack (Software)
63+
> The capabilities available to us.
64+
- **Language:** [e.g. TypeScript 5.3]
65+
- **Framework:** [e.g. NestJS 10]
66+
- **Database:** [e.g. PostgreSQL 15]
67+
68+
## Slice: Constraints (Normative)
69+
> The rules we cannot break.
70+
- **Compliance:** [e.g. GDPR, HIPAA, SOC2]
71+
- **Budget:** [e.g. < $500/mo]
72+
- **Team:** [e.g. 2 Backend, 1 Frontend]
73+
- **Timeline:** [e.g. MVP by Q3]
6974
```
7075

7176
### 4. Create Session File

dist/claude/q1-hypothesize.md

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,9 @@ Complete current cycle with /q5-decide or /q-reset first.
3232

3333
## Your Role
3434

35-
You are the **Abductor**. Generate multiple competing hypotheses, not one "best" solution.
35+
You are the **Transformer** enacting the **ExplorerRole** (Abductive).
36+
37+
Your goal is to generate multiple competing hypotheses, not one "best" solution. Explore the solution space.
3638

3739
**Critical:** You generate options. Human decides which to pursue. This is the Transformer Mandate.
3840

@@ -42,11 +44,14 @@ Problem: `$ARGUMENTS.problem`
4244

4345
## Process
4446

45-
### 1. Load Context
47+
### 1. Load Context (A.2.6 Slice Check)
4648

4749
- Read `.fpf/session.md` for any active context
48-
- Read `.fpf/context.md` for project context (Tech Stack, Scale, Constraints)
49-
- Read relevant project files to understand constraints
50+
- Read `.fpf/context.md` for **Context Slices**:
51+
- **Slice: Grounding** (Infrastructure constraints)
52+
- **Slice: Tech Stack** (Available capabilities)
53+
- **Slice: Constraints** (Budget, Team, Compliance)
54+
- **Constraint Check:** Ensure all hypotheses are compatible with these slices. Flag any deviations as explicit risks.
5055
- Check `.fpf/knowledge/L2/` for verified facts that constrain solution space
5156
- Check `.fpf/knowledge/invalid/` for approaches already disproven
5257

dist/claude/q2-check.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,11 @@ Proceed with /q3-test, /q3-research, or continue current phase.
3737

3838
## Your Role
3939

40-
You are the **Deductor**. Verify logical consistency without running code or experiments.
40+
You are the **Transformer** enacting the **LogicianRole** (Deductive).
41+
42+
- **Do not generate ideas.** That was Phase 1.
43+
- **Do not be polite.** Validation theater helps no one.
44+
- **Only validate logical soundness.**
4145

4246
This phase answers: **"Does this hypothesis make sense? Are there logical contradictions?"**
4347

dist/claude/q4-audit.md

Lines changed: 40 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,11 @@ Complete /q3-test or /q3-research first.
3232

3333
## Your Role
3434

35-
You are the **Scrutineer**. Challenge assumptions, find blind spots, stress-test thinking.
35+
You are the **Transformer** enacting the **AuditorRole** (Adversarial).
36+
37+
- **Assume the decision is wrong.** Prove it right.
38+
- **Find the Weakest Link.** What breaks first?
39+
- **Check Context Drift.** Do these solutions still fit the current slices?
3640

3741
This phase answers: **"What are we missing? What could go wrong that we haven't considered?"**
3842

@@ -64,7 +68,35 @@ cat .fpf/evidence/*.md
6468
cat .fpf/session.md
6569
```
6670

67-
### 2. WLNK Analysis (Weakest Link)
71+
### 2. Context Drift Analysis (A.2.6 Slice Check)
72+
73+
Verify that hypotheses still fit the project's **Context Slices** (`.fpf/context.md`):
74+
75+
```markdown
76+
## Context Drift Check
77+
78+
### Slice: Grounding (Infrastructure)
79+
| Hypothesis | Compatible? | Issues |
80+
|------------|-------------|--------|
81+
| H1 | ✓/✗ | [e.g., Requires Lambda but we use K8s] |
82+
| H2 | ✓/✗ | [e.g., Data sovereignty risk] |
83+
84+
### Slice: Tech Stack
85+
| Hypothesis | Compatible? | Issues |
86+
|------------|-------------|--------|
87+
| H1 | ✓/✗ | [e.g., Requires library not in stack] |
88+
| H2 | ✓/✗ | [e.g., Incompatible language version] |
89+
90+
### Slice: Constraints
91+
| Hypothesis | Compatible? | Issues |
92+
|------------|-------------|--------|
93+
| H1 | ✓/✗ | [e.g., Violates budget] |
94+
| H2 | ✓/✗ | [e.g., Team skills gap] |
95+
96+
**Verdict:** [All aligned / Drift detected in H(n)]
97+
```
98+
99+
### 3. WLNK Analysis (Weakest Link)
68100

69101
**CRITICAL: Assurance = min(evidence assurances), NEVER average**
70102

@@ -116,7 +148,7 @@ Hypothesis R_eff = min(1.00, 1.00, 0.85, 0.45) = 0.45
116148
3. Accept the risk with documented justification
117149
```
118150

119-
### 3. Assumption Inventory
151+
### 4. Assumption Inventory
120152

121153
List ALL assumptions — explicit and implicit:
122154

@@ -147,7 +179,7 @@ List ALL assumptions — explicit and implicit:
147179
- [ ] Budget constraints hold
148180
```
149181

150-
### 4. Bias Check
182+
### 5. Bias Check
151183

152184
Actively look for cognitive biases:
153185

@@ -190,7 +222,7 @@ Are we only looking at successful examples?
190222
- **Mitigation:** [action if needed]
191223
```
192224

193-
### 5. Adversarial Analysis
225+
### 6. Adversarial Analysis
194226

195227
Think like an attacker / skeptic:
196228

@@ -223,7 +255,7 @@ Think like an attacker / skeptic:
223255
[Failure mode requiring least effort to trigger]
224256
```
225257

226-
### 6. Evidence Quality Review
258+
### 7. Evidence Quality Review
227259

228260
```markdown
229261
## Evidence Quality Audit
@@ -260,7 +292,7 @@ Think like an attacker / skeptic:
260292
| [claim 2] | 3 | ✓ Multiple sources |
261293
```
262294

263-
### 7. Final Scrutiny Verdict
295+
### 8. Final Scrutiny Verdict
264296

265297
```markdown
266298
## Audit Verdict
@@ -300,7 +332,7 @@ Think like an attacker / skeptic:
300332
[Present the strongest counter-argument]
301333
```
302334

303-
### 8. Update Session
335+
### 9. Update Session
304336

305337
```markdown
306338
## Status

dist/codex/q0-init.md

Lines changed: 22 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -52,25 +52,30 @@ mkdir -p .fpf/sessions
5252
- Ask **specific** questions for what you can't see (Scale, Budget, Constraints).
5353
- *Example:* "I see this is a web app. What is the target user scale? (<1k, >1M?)"
5454

55-
3. **Write `.fpf/context.md`:**
56-
- Combine your findings and the user's answers.
55+
3. **Write `.fpf/context.md` (Context Slicing A.2.6):**
56+
- Combine your findings and the user's answers into structured slices.
5757

5858
```markdown
59-
# Repository Context (A.2.6 Context Slice)
60-
61-
## Tech Stack (Inferred)
62-
- **Language:** [e.g. Python 3.11]
63-
- **Frameworks:** [e.g. Django 4.2]
64-
- **Infra:** [e.g. Docker, AWS]
65-
66-
## Scale & Performance (User-Defined)
67-
- **Users:** [Value]
68-
- **Traffic:** [Value]
69-
- **Latency Target:** [Value]
70-
71-
## Hard Constraints (User-Defined)
72-
- [Constraint 1]
73-
- [Constraint 2]
59+
# Project Context (A.2.6 Context Slice)
60+
61+
## Slice: Grounding (Infrastructure)
62+
> The physical/virtual environment where the code runs.
63+
- **Platform:** [e.g. AWS Lambda / Kubernetes / Vercel]
64+
- **Region:** [e.g. us-east-1]
65+
- **Storage:** [e.g. S3, EBS]
66+
67+
## Slice: Tech Stack (Software)
68+
> The capabilities available to us.
69+
- **Language:** [e.g. TypeScript 5.3]
70+
- **Framework:** [e.g. NestJS 10]
71+
- **Database:** [e.g. PostgreSQL 15]
72+
73+
## Slice: Constraints (Normative)
74+
> The rules we cannot break.
75+
- **Compliance:** [e.g. GDPR, HIPAA, SOC2]
76+
- **Budget:** [e.g. < $500/mo]
77+
- **Team:** [e.g. 2 Backend, 1 Frontend]
78+
- **Timeline:** [e.g. MVP by Q3]
7479
```
7580

7681
### 4. Create Session File

dist/codex/q1-hypothesize.md

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,9 @@ Complete current cycle with /q5-decide or /q-reset first.
3737

3838
## Your Role
3939

40-
You are the **Abductor**. Generate multiple competing hypotheses, not one "best" solution.
40+
You are the **Transformer** enacting the **ExplorerRole** (Abductive).
41+
42+
Your goal is to generate multiple competing hypotheses, not one "best" solution. Explore the solution space.
4143

4244
**Critical:** You generate options. Human decides which to pursue. This is the Transformer Mandate.
4345

@@ -47,11 +49,14 @@ Problem: `$ARGUMENTS.problem`
4749

4850
## Process
4951

50-
### 1. Load Context
52+
### 1. Load Context (A.2.6 Slice Check)
5153

5254
- Read `.fpf/session.md` for any active context
53-
- Read `.fpf/context.md` for project context (Tech Stack, Scale, Constraints)
54-
- Read relevant project files to understand constraints
55+
- Read `.fpf/context.md` for **Context Slices**:
56+
- **Slice: Grounding** (Infrastructure constraints)
57+
- **Slice: Tech Stack** (Available capabilities)
58+
- **Slice: Constraints** (Budget, Team, Compliance)
59+
- **Constraint Check:** Ensure all hypotheses are compatible with these slices. Flag any deviations as explicit risks.
5560
- Check `.fpf/knowledge/L2/` for verified facts that constrain solution space
5661
- Check `.fpf/knowledge/invalid/` for approaches already disproven
5762

dist/codex/q2-check.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,11 @@ Proceed with /q3-test, /q3-research, or continue current phase.
4242

4343
## Your Role
4444

45-
You are the **Deductor**. Verify logical consistency without running code or experiments.
45+
You are the **Transformer** enacting the **LogicianRole** (Deductive).
46+
47+
- **Do not generate ideas.** That was Phase 1.
48+
- **Do not be polite.** Validation theater helps no one.
49+
- **Only validate logical soundness.**
4650

4751
This phase answers: **"Does this hypothesis make sense? Are there logical contradictions?"**
4852

0 commit comments

Comments
 (0)