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
34 changes: 34 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# SPDX-License-Identifier: MPL-2.0
# CODEOWNERS - Define code review assignments for GitHub
# See: https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners

# Default: sole maintainer for all files
* @hyperpolymath

# Security-sensitive files require explicit ownership
SECURITY.md @hyperpolymath
.github/workflows/ @hyperpolymath
.machine_readable/ @hyperpolymath
contractiles/ @hyperpolymath

# License files
LICENSE @hyperpolymath
LICENSES/ @hyperpolymath

# Configuration
.gitignore @hyperpolymath
.github/ @hyperpolymath

# Documentation
README* @hyperpolymath
CONTRIBUTING* @hyperpolymath
CODE_OF_CONDUCT* @hyperpolymath
GOVERNANCE* @hyperpolymath
MAINTAINERS* @hyperpolymath
CHANGELOG* @hyperpolymath
ROADMAP* @hyperpolymath

# Build and CI
Justfile @hyperpolymath
Makefile @hyperpolymath
*.sh @hyperpolymath
4 changes: 4 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
<!--
SPDX-License-Identifier: MPL-2.0
Copyright (c) Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk>
-->
---
name: Bug report
about: Create a report to help us improve
Expand Down
4 changes: 4 additions & 0 deletions .github/ISSUE_TEMPLATE/custom.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
<!--
SPDX-License-Identifier: MPL-2.0
Copyright (c) Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk>
-->
---
name: Custom issue template
about: Describe this issue template's purpose here.
Expand Down
4 changes: 4 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
<!--
SPDX-License-Identifier: MPL-2.0
Copyright (c) Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk>
-->
---
name: Feature request
about: Suggest an idea for this project
Expand Down
6 changes: 6 additions & 0 deletions .github/copilot/coding-agent.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
mcp_servers:
boj-server:
command: npx
args: ["-y", "@hyperpolymath/boj-server@latest"]
env:
BOJ_URL: http://localhost:7700
6 changes: 2 additions & 4 deletions .github/workflows/governance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,14 @@
# (rust-ci, codeql, dependabot, release, scan/mirror/pages plumbing).

name: Governance

on:
push:
branches: [main, master]
pull_request:
workflow_dispatch:

permissions:
contents: read

jobs:
governance:
uses: hyperpolymath/standards/.github/workflows/governance-reusable.yml@main
uses: hyperpolymath/standards/.github/workflows/governance-reusable.yml@861b5e911d9e5dcfb3c0ab3dd2a9a3c8fd0a1613
timeout-minutes: 10
22 changes: 22 additions & 0 deletions .machine_readable/6a2/0-AI-MANIFEST.a2ml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# AI Manifest for 6a2 Directory

## Purpose

This manifest declares the AI-assistant context for the 6a2 machine-readable metadata directory.

## Canonical Locations

The 6 core A2ML files MUST exist in this directory:
1. AGENTIC.a2ml
2. ECOSYSTEM.a2ml
3. META.a2ml
4. NEUROSYM.a2ml
5. PLAYBOOK.a2ml
6. STATE.a2ml

## Invariants

- No duplicate files in root directory
- Single source of truth: this directory is authoritative
- No stale metadata

20 changes: 20 additions & 0 deletions .machine_readable/6a2/README.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// SPDX-License-Identifier: MPL-2.0
// Copyright (c) Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk>
# A2ML 6a2 Directory

This directory contains the 6 core A2ML machine-readable metadata files for this repository.

## Files

- `AGENTIC.a2ml` - AI agent operational gating, safety controls
- `ECOSYSTEM.a2ml` - Project ecosystem position, relationships, explicit boundaries
- `META.a2ml` - Architecture decisions (ADRs), development practices, design rationale
- `NEUROSYM.a2ml` - Symbolic semantics, composition algebra
- `PLAYBOOK.a2ml` - Executable plans, operational runbooks
- `STATE.a2ml` - Project state, phase, milestones, session history

## Standards Compliance

These files follow the A2ML Format Family specification from:
https://github.com/hyperpolymath/standards/tree/main/a2ml

72 changes: 72 additions & 0 deletions .machine_readable/contractiles/Adjustfile.a2ml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
# SPDX-License-Identifier: MPL-2.0
# Adjustfile — Drift-tolerance contract for rsr-template-repo
# Author: Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk>
#
# Cumulative-drift catchment: tolerance bands + corrective actions.
# Authority: advisory (Yard) — continue-with-warnings; auto_fix where deterministic.
# Run with: adjust check
# Fix with: adjust fix (applies deterministic patches; advisory otherwise)

@abstract:
Drift tolerances and corrective actions for rsr-template-repo. Unlike
MUST (hard gate), ADJUST tracks cumulative drift against tolerance bands
and proposes corrective actions. Advisory — it warns and trends, it does
not block.
@end

## Template Drift

### placeholder-drift
- description: Template placeholders should be replaced when copied
- tolerance: 0 placeholder markers in copied repos
- corrective: Search and replace all {{PLACEHOLDER}} markers
- severity: advisory
- notes: This check only applies to repos that copied from this template

### template-version-drift
- description: Template version should match RSR spec version
- tolerance: Template version matches current RSR spec
- corrective: Update template to match latest RSR spec
- severity: advisory

## Documentation Drift

### readme-completeness
- description: README should document all template features
- tolerance: README covers all contractiles and directory structure
- corrective: Update README.adoc with missing sections
- severity: advisory

### example-accuracy
- description: Examples in documentation should match actual template content
- tolerance: All code examples in docs are accurate
- corrective: Audit and fix examples in documentation
- severity: advisory

## Structural Drift

### contractile-sync
- description: All contractiles should have matching a2ml and ncl implementations
- tolerance: Every .a2ml has a corresponding .ncl
- corrective: Generate missing .ncl files from .a2ml
- severity: advisory

### no-broken-symlinks
- description: No broken symbolic links in template structure
- tolerance: 0 broken symlinks
- corrective: Run symlink-check script
- severity: advisory

## Accessibility Drift

### adoc-not-md
- description: Template docs should prefer AsciiDoc
- tolerance: New prose docs are *.adoc
- corrective: Convert any new *.md to *.adoc
- severity: advisory

### spdx-header-consistency
- description: All template files have correct SPDX headers
- tolerance: 0 files missing SPDX-License-Identifier
- corrective: Add SPDX headers to files that need them
- severity: advisory
99 changes: 99 additions & 0 deletions .machine_readable/contractiles/Intentfile.a2ml
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
# SPDX-License-Identifier: MPL-2.0
# Intentfile (A2ML Canonical) — north-star contractile for rsr-template-repo
# Author: Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk>
#
# Paired runner: intend.ncl
# Verb: intend
#
# Semantics: North-star contractile. Declares BOTH concrete committed
# next-actions AND horizon aspirations the project wishes to
# become. Two sections share one file because they answer
# the same question at different ranges:
# [[intents]] — "we WILL do this; track progress"
# status: declared → in_progress → done |
# deferred | retired
# [[wishes]] — "we WISH this were true; revisit later"
# status: declared → in_progress → achieved |
# abandoned
# grouped by horizon: near / mid / far.
# Non-gating — this is a report, not a gate. See the `must`
# contractile for hard gates.

@abstract:
North-star contractile for rsr-template-repo. This repository is the
canonical template for Rhodium Standard Repository compliance. It provides
the scaffold that all hyperpolymath repos should copy and customize.
@end

## Purpose

The rsr-template-repo serves as the master template for all hyperpolymath
repositories. It contains the complete set of contractile files, machine-readable
specifications, and governance documentation that define the Rhodium Standard.

Every new repository in the hyperpolymath estate should be initialized by
copying this template and substituting the placeholder values with
repo-specific content.

## Anti-Purpose

This repository is NOT:
- A general-purpose project scaffold for external use (hyperpolymath-only)
- A replacement for per-repo customization (all files must be bespoke)
- A static template that never changes (evolves with RSR spec)
- A runtime library or framework (build-time only)

## If In Doubt

If you are unsure whether a change is in scope, ask. Sensitive areas:
- .machine_readable/ contractile definitions
- RSR specification files
- Governance templates
- License policy documents

## Committed Next-Actions

### repo-initialization
- description: Provide just copy-and-substitute template for new repos
- probe: test -f scripts/init-repo.sh
- status: done
- notes: Run with source scripts/init-repo.sh <new-repo-name>

### contractile-completeness
- description: Every RSR contractile has an a2ml and ncl implementation
- probe: ls .machine_readable/contractiles/*.a2ml | wc -l | grep -q "^6$"
- status: in_progress
- notes: Currently 6 contractile verbs: intend, must, trust, adjust, bust, dust

### automation-scripts
- description: All repetitive tasks have just recipes
- probe: grep -c "^# " Justfile | grep -q "^[6-9][0-9]*$"
- status: in_progress

## Wishes

### Near Horizon

#### cross-repo-validation
- description: Tooling to validate all repos against RSR spec
- horizon: near
- status: declared

#### automated-substitution
- description: Script to automate repo-specific substitution in template
- horizon: near
- status: declared

### Mid Horizon

#### formal-verification
- description: Idris2 proofs for all critical contractile invariants
- horizon: mid
- status: declared

### Far Horizon

#### ecosystem-visualization
- description: Interactive graph of all hyperpolymath repos and dependencies
- horizon: far
- status: declared
81 changes: 81 additions & 0 deletions .machine_readable/contractiles/Justfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
# SPDX-License-Identifier: MPL-2.0
# justfile - Error-Lang build commands

set shell := ["bash", "-uc"]

# Default recipe
default: help

# Show help
help:
@echo "Error-Lang Build Commands"
@echo "========================="
@echo ""
@echo "Usage: just <recipe>"
@echo ""
@echo "Recipes:"
@echo " run <file> Run an Error-Lang program"
@echo " doctor Check environment"
@echo " explain Explain an error code"
@echo " test Run tests"
@echo " lint Lint code"
@echo " fmt Format code"
@echo " build Build ReScript compiler"
@echo " clean Clean build artifacts"

# Run an Error-Lang program
run file:
deno run --allow-read --allow-write cli/runtime.js {{file}}

# Check environment
doctor:
deno run cli/main.js doctor

# Explain an error code
explain code="--all":
deno run cli/main.js explain {{code}}

# Run tests
test:
deno test --allow-read --allow-write

# Lint code
lint:
deno lint
@if command -v rescript &> /dev/null; then \
cd compiler && npx rescript build; \
fi

# Format code
fmt:
deno fmt

# Build ReScript compiler
build:
@if [ -d "compiler" ] && [ -f "compiler/rescript.json" ]; then \
cd compiler && npx rescript build; \
else \
echo "ReScript compiler not yet configured"; \
fi

# Clean build artifacts
clean:
rm -rf compiler/lib
rm -f compiler/src/*.res.js
rm -rf .error-lang

# Run all examples
examples:
@for f in examples/*.err; do \
echo "=== Running $$f ==="; \
just run "$$f"; \
echo ""; \
done

# Initialize state for a fresh start
init:
rm -rf .error-lang
@echo "State cleared. Next run will be Run #1."

secret-scan-trufflehog:
@command -v trufflehog >/dev/null && trufflehog filesystem . --only-verified || true
Loading
Loading