Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 9 additions & 8 deletions .claude/CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,15 @@ Copyright (c) Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk>
-->
## Machine-Readable Artefacts

The following files in `.machine_readable/` contain structured project metadata:

- `STATE.scm` - Current project state and progress
- `META.scm` - Architecture decisions and development practices
- `ECOSYSTEM.scm` - Position in the ecosystem and related projects
- `AGENTIC.scm` - AI agent interaction patterns
- `NEUROSYM.scm` - Neurosymbolic integration config
- `PLAYBOOK.scm` - Operational runbook
The 6 core A2ML metadata files live in `.machine_readable/6a2/` (the canonical
RSR layout — see https://github.com/hyperpolymath/standards):

- `STATE.a2ml` - Current project state and progress
- `META.a2ml` - Architecture decisions and development practices
- `ECOSYSTEM.a2ml` - Position in the ecosystem and related projects
- `AGENTIC.a2ml` - AI agent interaction patterns
- `NEUROSYM.a2ml` - Neurosymbolic integration config
- `PLAYBOOK.a2ml` - Operational runbook

---

Expand Down
8 changes: 7 additions & 1 deletion .machine_readable/6a2/AGENTIC.a2ml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# AGENTIC.a2ml — AI agent constraints and capabilities
[metadata]
version = "0.1.0"
last-updated = "2026-04-11"
last-updated = "2026-06-18"

[agent-permissions]
can-edit-source = true
Expand All @@ -28,6 +28,12 @@ allow-silent-skip = false
require-rerun-after-fix = true
release-claim-requires-hard-pass = true

[reflexion]
# The reflexion design layer is advisory: it emits design obligations that gate
# changes to the language, but never auto-mutates the AST, compiler, or runtime.
obligations-are-advisory = true
never-auto-mutate-semantics = true

[automation-hooks]
# on-enter: Read 0-AI-MANIFEST.a2ml, then STATE.a2ml
# on-exit: Update STATE.a2ml with session outcomes
Expand Down
18 changes: 13 additions & 5 deletions .machine_readable/6a2/ECOSYSTEM.a2ml
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,25 @@
# ECOSYSTEM.a2ml — Phronesis ecosystem position
[metadata]
version = "1.0"
last-updated = "2026-04-11"
last-updated = "2026-06-18"

[project]
name = "Phronesis"
purpose = ""
role = ""
purpose = "Neuro-symbolic policy language for provably-safe agentic ethical reasoning on the BEAM."
role = "language-and-runtime"

[position-in-ecosystem]
category = ""
category = "nextgen-language"

[related-projects]
projects = [
# No related projects recorded
{ name = "phronesiser", relation = "sibling", note = "The -iser that adds provably-safe ethical constraints to AI agents via Phronesis deontic logic." },
{ name = "standards", relation = "depends-on", note = "Estate standards: RSR template, A2ML format family, licence policy." },
{ name = "rsr-template-repo", relation = "templated-from", note = "Rhodium Standard Repository template (.machine_readable/6a2 layout, contractiles)." },
{ name = "hypatia", relation = "ci", note = "Neurosymbolic CI scanning (report-format = logtalk)." },
{ name = "gitbot-fleet", relation = "ci", note = "Learning / feedback submission." },
{ name = "a2ml-validate-action", relation = "ci", note = "Validates the .machine_readable A2ML artefacts." },
]

[boundaries]
note = "A reflexion design-self-relation layer (claims / judgement-evidence graph / invariant-path equivalence / revaluation) was added 2026-06; it observes the toolchain and gates design changes but never auto-mutates semantics."
7 changes: 5 additions & 2 deletions .machine_readable/6a2/META.a2ml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,18 @@
# META.a2ml — Phronesis meta-level information
[metadata]
version = "0.1.0"
last-updated = "2026-04-11"
last-updated = "2026-06-18"

[project-info]
license = "MPL-2.0"
author = "Jonathan D.A. Jewell (hyperpolymath)"

[architecture-decisions]
decisions = [
# No ADRs recorded
{ id = "ADR-0001", title = "BEAM/Elixir reference runtime with a Rust to WASM production compiler", status = "accepted" },
{ id = "ADR-0002", title = "Idris2 ABI + Zig FFI as the cross-language boundary standard", status = "accepted" },
{ id = "ADR-0003", title = "Reflexion layer: design self-relation that gates changes, never auto-mutates semantics", status = "proposed" },
{ id = "ADR-0004", title = "Dual licence: MPL-2.0 for code, CC-BY-SA-4.0 for documentation/content", status = "accepted" },
]

[development-practices]
Expand Down
2 changes: 1 addition & 1 deletion .machine_readable/6a2/NEUROSYM.a2ml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# NEUROSYM.a2ml — Neurosymbolic integration metadata
[metadata]
version = "0.1.0"
last-updated = "2026-04-11"
last-updated = "2026-06-18"

[hypatia-config]
scan-enabled = true
Expand Down
2 changes: 1 addition & 1 deletion .machine_readable/6a2/PLAYBOOK.a2ml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# PLAYBOOK.a2ml — Operational playbook
[metadata]
version = "0.1.0"
last-updated = "2026-04-11"
last-updated = "2026-06-18"

[deployment]
# method = "gitops" # gitops | manual | ci-triggered
Expand Down
2 changes: 1 addition & 1 deletion .machine_readable/6a2/README.adoc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// SPDX-License-Identifier: MPL-2.0
// SPDX-License-Identifier: CC-BY-SA-4.0
// Copyright (c) Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk>
# A2ML 6a2 Directory

Expand Down
53 changes: 21 additions & 32 deletions .machine_readable/6a2/STATE.a2ml
Original file line number Diff line number Diff line change
Expand Up @@ -5,56 +5,45 @@
[metadata]
project = "phronesis"
version = "0.9.0"
last-updated = "2026-03-14"
last-updated = "2026-06-18"
status = "active"
session = "converted from scheme — 2026-04-11"
session = "reflexion design layer + docs/metadata/licence sync — 2026-06-18"

[project-context]
name = "Phronesis"
purpose = """Scale testing, edge case handling, production deployment"""
completion-percentage = 95
purpose = """Neuro-symbolic policy language for provably-safe agentic ethical reasoning on the BEAM."""
completion-percentage = 80

[position]
phase = "production-ready" # design | implementation | testing | maintenance | archived
phase = "implementation" # design | implementation | testing | maintenance | archived
maturity = "experimental" # experimental | alpha | beta | production | lts

[route-to-mvp]
milestones = [
# No milestones recorded
{ name = "Lexer / parser / AST", completion = 100 },
{ name = "Type checker + analyzer", completion = 100 },
{ name = "Interpreter + tracing + decision traces", completion = 100 },
{ name = "LSP / debugger / profiler / doc-generator", completion = 100 },
{ name = "Consensus (Raft via :ra) runtime + TLA+ spec", completion = 80 },
{ name = "Reflexion design layer (claims / JEG / invariant-path / revaluation)", completion = 70 },
{ name = "Rust to WASM production compiler", completion = 20 },
{ name = "Idris2 ABI + Zig FFI boundary", completion = 30 },
]

[blockers-and-issues]
issues = [
# No blockers recorded
{ id = "pre-existing-test-failures", note = "DebuggerTest (Trace.merge/2 undefined; State.variables), DocGeneratorTest, IncrementalLexerTest, ConformanceTest 04_boolean_logic — predate the reflexion work" },
{ id = "compiler-backend", note = "Rust to WASM codegen is still AST scaffolding only" },
]

[critical-next-actions]
actions = [
"Write comprehensive tests for lexer, parser, interpreter, consensus, RPKI",
"8-12 hours",
"Scale test and real-world BGP feed testing",
"15-20 hours",
"Add Idris2 ABI definitions and Zig FFI layer",
"15-20 hours",
")
(achieved ",
")
(evidence
(unit ",
")
(smoke ",
")
(p2p ",
")
(e2e ",
")
(aspect ",
")
(contract ",
")
(benchmarks ",
"Repair pre-existing test failures (Trace.merge/2 in debugger; State.variables field)",
"Wire reflexion claim ingest for the compiler, formal/proof, and benchmark sources",
"Advance the Rust to WASM production compiler beyond AST scaffolding",
"Add Idris2 ABI definitions and the Zig FFI layer",
]

[maintenance-status]
last-run-utc = "2026-03-14T00:00:00Z"
last-result = "unknown" # unknown | pass | warn | fail
last-run-utc = "2026-06-18T00:00:00Z"
last-result = "warn" # unknown | pass | warn | fail (reflexion suite green; pre-existing failures remain)
2 changes: 1 addition & 1 deletion .machine_readable/contractiles/Trustfile.a2ml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ Current trust level: maximal

#### license-content
- description: LICENSE contains expected identifier
- run: grep -q 'PMPL\|MPL\|MIT\|Apache\|LGPL' LICENSE
- run: grep -q 'MPL\|MIT\|Apache\|LGPL\|CC-BY-SA' LICENSE
- severity: warning

## Template-Specific Trust
Expand Down
61 changes: 33 additions & 28 deletions 0-AI-MANIFEST.a2ml
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ This is the AI manifest for **phronesis**. It declares:

## CANONICAL LOCATIONS (UNIVERSAL RULE)

### Machine-Readable Metadata: `.machine_readable/` ONLY
### Machine-Readable Metadata: `.machine_readable/6a2/` ONLY

These 6 SCM files MUST exist in `.machine_readable/` directory ONLY:
1. **STATE.scm** - Project state, progress, blockers
2. **META.scm** - Architecture decisions, governance
3. **ECOSYSTEM.scm** - Position in ecosystem, relationships
4. **AGENTIC.scm** - AI agent interaction patterns
5. **NEUROSYM.scm** - Neurosymbolic integration config
6. **PLAYBOOK.scm** - Operational runbook
These 6 A2ML files MUST exist in the `.machine_readable/6a2/` directory ONLY:
1. **STATE.a2ml** - Project state, progress, blockers
2. **META.a2ml** - Architecture decisions, governance
3. **ECOSYSTEM.a2ml** - Position in ecosystem, relationships
4. **AGENTIC.a2ml** - AI agent interaction patterns
5. **NEUROSYM.a2ml** - Neurosymbolic integration config
6. **PLAYBOOK.a2ml** - Operational runbook

**CRITICAL:** If ANY of these files exist in the root directory, this is an ERROR.

Expand All @@ -40,9 +40,9 @@ Bot-specific instructions for:

## CORE INVARIANTS

1. **No SCM duplication** - Root must NOT contain STATE.scm, META.scm, etc.
2. **Single source of truth** - `.machine_readable/` is authoritative
3. **No stale metadata** - If root SCMs exist, they are OUT OF DATE
1. **No metadata duplication** - Root must NOT contain STATE.a2ml, META.a2ml, etc.
2. **Single source of truth** - `.machine_readable/6a2/` is authoritative
3. **No stale metadata** - If root metadata files exist, they are OUT OF DATE
4. **License consistency** - All code MPL-2.0 unless platform requires MPL-2.0
5. **Author attribution** - Always "Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk>"

Expand All @@ -55,16 +55,21 @@ This repo contains:
```
phronesis/
├── 0-AI-MANIFEST.a2ml # THIS FILE (start here)
├── README.md # Project overview
├── [your source files] # Main code
├── .machine_readable/ # SCM files (6 files)
│ ├── STATE.scm
│ ├── META.scm
│ ├── ECOSYSTEM.scm
│ ├── AGENTIC.scm
│ ├── NEUROSYM.scm
│ └── PLAYBOOK.scm
└── .bot_directives/ # Bot instructions
├── README.adoc # Project overview
├── lib/phronesis/ # Reference implementation (Elixir/BEAM)
├── compiler/ # Rust → WASM compiler
├── spec/ formal/ academic/ # Grammar, semantics, proofs
├── docs/ # AsciiDoc design docs (incl. REFLEXION.adoc)
├── .machine_readable/
│ ├── 6a2/ # The 6 core A2ML files
│ │ ├── STATE.a2ml
│ │ ├── META.a2ml
│ │ ├── ECOSYSTEM.a2ml
│ │ ├── AGENTIC.a2ml
│ │ ├── NEUROSYM.a2ml
│ │ └── PLAYBOOK.a2ml
│ └── contractiles/ # Mustfile / Trustfile / Justfile / etc.
└── .github/workflows/ # CI/CD
```

## SESSION STARTUP CHECKLIST
Expand All @@ -73,8 +78,8 @@ phronesis/
✅ Understand canonical locations (.machine_readable/, .bot_directives/)
✅ Know the invariants (no SCM duplication, etc.)
✅ Check for MCP enforcement (if applicable)
✅ Read `.machine_readable/STATE.scm` for current status
✅ Read `.machine_readable/AGENTIC.scm` for interaction patterns
✅ Read `.machine_readable/6a2/STATE.a2ml` for current status
✅ Read `.machine_readable/6a2/AGENTIC.a2ml` for interaction patterns

## LIFECYCLE HOOKS

Expand All @@ -86,15 +91,15 @@ When starting a new session:
2. Log session start (optional but recommended)
- Format: `[YYYY-MM-DD HH:MM:SS] Session started: [agent-name]`
- Location: `.machine_readable/session-log.txt`
3. Read `.machine_readable/STATE.scm`
3. Read `.machine_readable/6a2/STATE.a2ml`
4. Check for blockers
5. State understanding of canonical locations

### on-exit (Session End)

When ending a session:

1. Update `.machine_readable/STATE.scm` if changes made
1. Update `.machine_readable/6a2/STATE.a2ml` if changes made
2. Log session end (optional but recommended)
- Format: `[YYYY-MM-DD HH:MM:SS] Session ended: [summary]`
- Location: `.machine_readable/session-log.txt`
Expand All @@ -105,13 +110,13 @@ When ending a session:

After reading this file, demonstrate understanding by stating:

**"I have read the AI manifest. SCM files are located in `.machine_readable/` ONLY, bot directives in `.bot_directives/`, and I will not create duplicate files in the root directory."**
**"I have read the AI manifest. The 6 core A2ML files are located in `.machine_readable/6a2/` ONLY, and I will not create duplicate metadata files in the root directory."**

## META

- **Format Version:** 1.0.0
- **Created:** [DATE]
- **Maintained By:** [YOUR-NAME/ORG]
- **Created:** 2026
- **Maintained By:** Jonathan D.A. Jewell (hyperpolymath)
- **License:** MPL-2.0
- **Protocol:** https://github.com/hyperpolymath/0-ai-gatekeeper-protocol

Expand Down
21 changes: 0 additions & 21 deletions CONTRIBUTING.adoc

This file was deleted.

Loading
Loading