wisk 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.
- wisk-0.3.0/.github/workflows/ci.yml +91 -0
- wisk-0.3.0/.github/workflows/pypi.yml +34 -0
- wisk-0.3.0/.gitignore +11 -0
- wisk-0.3.0/.pre-commit-config.yaml +59 -0
- wisk-0.3.0/PKG-INFO +193 -0
- wisk-0.3.0/README.md +175 -0
- wisk-0.3.0/changelog/changes/agent-run-surfaces.md +13 -0
- wisk-0.3.0/changelog/changes/bootstrap-wisk.md +9 -0
- wisk-0.3.0/changelog/changes/builtin-session-types.md +14 -0
- wisk-0.3.0/changelog/changes/check-next-action.md +13 -0
- wisk-0.3.0/changelog/changes/consumer-golden-path.md +20 -0
- wisk-0.3.0/changelog/changes/contract-guided-start-check.md +13 -0
- wisk-0.3.0/changelog/changes/experience-recording-phase1.md +13 -0
- wisk-0.3.0/changelog/changes/handoff-runtime.md +15 -0
- wisk-0.3.0/changelog/changes/live-run-writes.md +14 -0
- wisk-0.3.0/changelog/changes/run-goal-closure.md +14 -0
- wisk-0.3.0/changelog/changes/run-spec-pinning.md +13 -0
- wisk-0.3.0/changelog/changes/session-cadence.md +14 -0
- wisk-0.3.0/changelog/changes/session-policies-layout.md +14 -0
- wisk-0.3.0/changelog/changes/session-types.md +13 -0
- wisk-0.3.0/changelog/changes/typed-run-schemas.md +11 -0
- wisk-0.3.0/docs/architecture.md +190 -0
- wisk-0.3.0/docs/dogfooding.md +57 -0
- wisk-0.3.0/docs/rfc/0001-repository-as-skill-runtime.md +632 -0
- wisk-0.3.0/docs/rfc/0002-contract-guided-execution-runtime.md +155 -0
- wisk-0.3.0/docs/rfc/0003-start-check-runtime.md +27 -0
- wisk-0.3.0/docs/rfc/0004-canonical-learning-cycle.md +151 -0
- wisk-0.3.0/docs/rfc/0005-consumer-golden-path.md +192 -0
- wisk-0.3.0/knowledge/experiences/records/2026-09-02-bootstrap-okf-boundary.md +23 -0
- wisk-0.3.0/knowledge/experiences/records/20260905-contract-first-types.md +16 -0
- wisk-0.3.0/knowledge/experiences/records/exp-pr23-runtime-dogfood-33983567300.md +21 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-check-okf.md +15 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-check-tests.md +15 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-contract-guided-runtime.md +32 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-decision-declared-empty-types.md +18 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-evidence-contract-verification.md +15 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-evidence-start-check-runtime.md +15 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-goal-contract-runtime.md +14 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-outcome-contract-runtime.md +23 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-reading-okf-knowledge.md +13 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-reading-open-issues.md +13 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-reading-open-prs.md +13 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-reading-recent-runs.md +13 -0
- wisk-0.3.0/knowledge/experiences/runs/20260905-reading-repository-guide.md +13 -0
- wisk-0.3.0/knowledge/skills/active/bootstrap-repository.md +20 -0
- wisk-0.3.0/knowledge/skills/policies/access/development.md +18 -0
- wisk-0.3.0/knowledge/skills/policies/cadence/development.md +17 -0
- wisk-0.3.0/knowledge/skills/policies/cadence/evaluator.md +17 -0
- wisk-0.3.0/knowledge/skills/policies/cadence/inference.md +17 -0
- wisk-0.3.0/knowledge/skills/policies/cadence/skill-evolver.md +18 -0
- wisk-0.3.0/knowledge/skills/policies/cadence/wiki-maintainer.md +20 -0
- wisk-0.3.0/knowledge/skills/policies/context/development.md +20 -0
- wisk-0.3.0/knowledge/skills/policies/context/evaluator.md +19 -0
- wisk-0.3.0/knowledge/skills/policies/context/inference.md +19 -0
- wisk-0.3.0/knowledge/skills/policies/context/skill-evolver.md +19 -0
- wisk-0.3.0/knowledge/skills/policies/context/wiki-maintainer.md +18 -0
- wisk-0.3.0/knowledge/skills/policies/output/default.md +22 -0
- wisk-0.3.0/knowledge/skills/run-specs/evaluation.md +28 -0
- wisk-0.3.0/knowledge/skills/run-specs/experience.md +26 -0
- wisk-0.3.0/knowledge/skills/run-specs/inference.md +25 -0
- wisk-0.3.0/knowledge/skills/run-specs/skill-evolution.md +28 -0
- wisk-0.3.0/knowledge/skills/run-specs/skill.md +31 -0
- wisk-0.3.0/knowledge/skills/run-specs/wiki-maintenance.md +27 -0
- wisk-0.3.0/knowledge/skills/run-specs/wiki.md +27 -0
- wisk-0.3.0/knowledge/skills/run-specs/wisk-development.md +46 -0
- wisk-0.3.0/knowledge/skills/session-types/base.md +15 -0
- wisk-0.3.0/knowledge/skills/session-types/development.md +18 -0
- wisk-0.3.0/knowledge/skills/session-types/evaluator.md +19 -0
- wisk-0.3.0/knowledge/skills/session-types/experience.md +15 -0
- wisk-0.3.0/knowledge/skills/session-types/inference.md +18 -0
- wisk-0.3.0/knowledge/skills/session-types/skill-evolver.md +19 -0
- wisk-0.3.0/knowledge/skills/session-types/skill.md +16 -0
- wisk-0.3.0/knowledge/skills/session-types/wiki-maintainer.md +20 -0
- wisk-0.3.0/knowledge/skills/session-types/wiki.md +16 -0
- wisk-0.3.0/knowledge/wiki/okf-infrastructure-boundary.md +22 -0
- wisk-0.3.0/pyproject.toml +86 -0
- wisk-0.3.0/scripts/check_bundle.py +43 -0
- wisk-0.3.0/scripts/check_pep723.py +84 -0
- wisk-0.3.0/scripts/check_version.py +167 -0
- wisk-0.3.0/scripts/serve_mcp.py +27 -0
- wisk-0.3.0/specs/accesspolicy.md +25 -0
- wisk-0.3.0/specs/accesspolicy.schema.sql +9 -0
- wisk-0.3.0/specs/agentskill.md +33 -0
- wisk-0.3.0/specs/agentskill.schema.sql +8 -0
- wisk-0.3.0/specs/cadencepolicy.md +31 -0
- wisk-0.3.0/specs/cadencepolicy.schema.sql +15 -0
- wisk-0.3.0/specs/changelog.md +7 -0
- wisk-0.3.0/specs/changelog.schema.sql +4 -0
- wisk-0.3.0/specs/contextpolicy.md +24 -0
- wisk-0.3.0/specs/contextpolicy.schema.sql +8 -0
- wisk-0.3.0/specs/experience.md +35 -0
- wisk-0.3.0/specs/experience.schema.sql +12 -0
- wisk-0.3.0/specs/handoff.md +41 -0
- wisk-0.3.0/specs/handoff.schema.sql +15 -0
- wisk-0.3.0/specs/looprun.md +71 -0
- wisk-0.3.0/specs/looprun.schema.sql +21 -0
- wisk-0.3.0/specs/outputpolicy.md +32 -0
- wisk-0.3.0/specs/outputpolicy.schema.sql +17 -0
- wisk-0.3.0/specs/runcheck.md +28 -0
- wisk-0.3.0/specs/runcheck.schema.sql +10 -0
- wisk-0.3.0/specs/rundecision.md +28 -0
- wisk-0.3.0/specs/rundecision.schema.sql +10 -0
- wisk-0.3.0/specs/runevidence.md +28 -0
- wisk-0.3.0/specs/runevidence.schema.sql +10 -0
- wisk-0.3.0/specs/rungoal.md +31 -0
- wisk-0.3.0/specs/rungoal.schema.sql +9 -0
- wisk-0.3.0/specs/runoutcome.md +32 -0
- wisk-0.3.0/specs/runoutcome.schema.sql +12 -0
- wisk-0.3.0/specs/runreading.md +23 -0
- wisk-0.3.0/specs/runreading.schema.sql +8 -0
- wisk-0.3.0/specs/runspec.md +39 -0
- wisk-0.3.0/specs/runspec.schema.sql +15 -0
- wisk-0.3.0/specs/sessiontype.md +32 -0
- wisk-0.3.0/specs/sessiontype.schema.sql +12 -0
- wisk-0.3.0/specs/skillevaluation.md +34 -0
- wisk-0.3.0/specs/skillproposal.md +33 -0
- wisk-0.3.0/specs/wikientry.md +28 -0
- wisk-0.3.0/specs/wikientry.schema.sql +7 -0
- wisk-0.3.0/src/wisk/__init__.py +12 -0
- wisk-0.3.0/src/wisk/bootstrap.py +302 -0
- wisk-0.3.0/src/wisk/cadence.py +263 -0
- wisk-0.3.0/src/wisk/cli.py +430 -0
- wisk-0.3.0/src/wisk/handoff.py +290 -0
- wisk-0.3.0/src/wisk/live_run.py +356 -0
- wisk-0.3.0/src/wisk/mcp.py +416 -0
- wisk-0.3.0/src/wisk/models.py +28 -0
- wisk-0.3.0/src/wisk/pinning.py +257 -0
- wisk-0.3.0/src/wisk/policy.py +209 -0
- wisk-0.3.0/src/wisk/profiles/standard/policies/cadence/standard-experience.md +12 -0
- wisk-0.3.0/src/wisk/profiles/standard/policies/cadence/standard-skill.md +14 -0
- wisk-0.3.0/src/wisk/profiles/standard/policies/cadence/standard-wiki.md +14 -0
- wisk-0.3.0/src/wisk/profiles/standard/policies/context/standard-experience.md +18 -0
- wisk-0.3.0/src/wisk/profiles/standard/policies/context/standard-skill.md +17 -0
- wisk-0.3.0/src/wisk/profiles/standard/policies/context/standard-wiki.md +17 -0
- wisk-0.3.0/src/wisk/profiles/standard/session-types/standard-experience.md +17 -0
- wisk-0.3.0/src/wisk/profiles/standard/session-types/standard-skill.md +17 -0
- wisk-0.3.0/src/wisk/profiles/standard/session-types/standard-wiki.md +17 -0
- wisk-0.3.0/src/wisk/runtime.py +406 -0
- wisk-0.3.0/src/wisk/session.py +146 -0
- wisk-0.3.0/tests/test_agent_run_surfaces.py +89 -0
- wisk-0.3.0/tests/test_basic.py +278 -0
- wisk-0.3.0/tests/test_bootstrap.py +213 -0
- wisk-0.3.0/tests/test_builtin_sessions.py +100 -0
- wisk-0.3.0/tests/test_cadence.py +122 -0
- wisk-0.3.0/tests/test_experience_recording.py +121 -0
- wisk-0.3.0/tests/test_goal_closure.py +180 -0
- wisk-0.3.0/tests/test_handoff.py +176 -0
- wisk-0.3.0/tests/test_judicial_consumer.py +140 -0
- wisk-0.3.0/tests/test_live_run_writes.py +182 -0
- wisk-0.3.0/tests/test_policy.py +81 -0
- wisk-0.3.0/tests/test_run_schemas.py +27 -0
- wisk-0.3.0/tests/test_runspec_pinning.py +135 -0
- wisk-0.3.0/tests/test_session_types.py +76 -0
- wisk-0.3.0/tests/test_wisk_public_api.py +6 -0
- wisk-0.3.0/uv.lock +2076 -0
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [main]
|
|
8
|
+
|
|
9
|
+
jobs:
|
|
10
|
+
test:
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
steps:
|
|
13
|
+
- uses: actions/checkout@v4
|
|
14
|
+
|
|
15
|
+
- name: Install uv
|
|
16
|
+
uses: astral-sh/setup-uv@v5
|
|
17
|
+
with:
|
|
18
|
+
enable-cache: true
|
|
19
|
+
|
|
20
|
+
- name: Set up Python
|
|
21
|
+
uses: actions/setup-python@v5
|
|
22
|
+
with:
|
|
23
|
+
python-version: "3.12"
|
|
24
|
+
|
|
25
|
+
- name: Install dependencies
|
|
26
|
+
run: uv sync
|
|
27
|
+
|
|
28
|
+
- name: Lint (Ruff check)
|
|
29
|
+
run: uv run ruff check .
|
|
30
|
+
|
|
31
|
+
- name: Format (Ruff format)
|
|
32
|
+
run: uv run ruff format --check .
|
|
33
|
+
|
|
34
|
+
- name: Type check (ty)
|
|
35
|
+
run: uv run ty check
|
|
36
|
+
|
|
37
|
+
- name: Security audit (Bandit)
|
|
38
|
+
run: uv run bandit -r src/ -c pyproject.toml
|
|
39
|
+
|
|
40
|
+
- name: Dead code check (Vulture)
|
|
41
|
+
run: uv run vulture src/ --min-confidence 80
|
|
42
|
+
|
|
43
|
+
- name: Validate PEP 723 Metadata in scripts
|
|
44
|
+
run: uv run scripts/check_pep723.py
|
|
45
|
+
|
|
46
|
+
- name: Check Version Sync & Changelog Presence
|
|
47
|
+
run: uv run scripts/check_version.py
|
|
48
|
+
|
|
49
|
+
- name: Validate OKF Bundle (Normative Specs Gate)
|
|
50
|
+
run: uv run okf-parser check knowledge/ --require-spec "../specs/{slug}.md" --normative-spec
|
|
51
|
+
|
|
52
|
+
- name: Build consumer-installable wheel
|
|
53
|
+
run: uv build --wheel
|
|
54
|
+
|
|
55
|
+
- name: Smoke installed consumer golden path
|
|
56
|
+
shell: bash
|
|
57
|
+
run: |
|
|
58
|
+
WHEEL="$GITHUB_WORKSPACE/$(find dist -name 'wisk-*.whl' -print -quit)"
|
|
59
|
+
CONSUMER="$(mktemp -d)"
|
|
60
|
+
cd "$CONSUMER"
|
|
61
|
+
uvx --from "$WHEEL" wisk init .
|
|
62
|
+
test -f .wisk/manifest.json
|
|
63
|
+
uvx --from "$WHEEL" wisk session start-next "Do the best useful work available"
|
|
64
|
+
find .wisk/knowledge/experiences/runs -name '*.md' -print -quit | grep -q .
|
|
65
|
+
|
|
66
|
+
- name: Run Pytest
|
|
67
|
+
run: uv run pytest -v
|
|
68
|
+
|
|
69
|
+
test-lower-bounds:
|
|
70
|
+
runs-on: ubuntu-latest
|
|
71
|
+
steps:
|
|
72
|
+
- uses: actions/checkout@v4
|
|
73
|
+
|
|
74
|
+
- name: Install uv
|
|
75
|
+
uses: astral-sh/setup-uv@v5
|
|
76
|
+
with:
|
|
77
|
+
enable-cache: true
|
|
78
|
+
|
|
79
|
+
- name: Set up Python
|
|
80
|
+
uses: actions/setup-python@v5
|
|
81
|
+
with:
|
|
82
|
+
python-version: "3.12"
|
|
83
|
+
|
|
84
|
+
- name: Test Lowest Direct Dependencies
|
|
85
|
+
run: uv sync --resolution lowest-direct
|
|
86
|
+
|
|
87
|
+
- name: Run Pytest against Lowest Bounds
|
|
88
|
+
run: uv run pytest -v
|
|
89
|
+
|
|
90
|
+
- name: Validate OKF Bundle against Lowest Bounds
|
|
91
|
+
run: uv run okf-parser check knowledge/ --require-spec "../specs/{slug}.md" --normative-spec
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
name: Publish to PyPI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
paths:
|
|
7
|
+
- pyproject.toml
|
|
8
|
+
workflow_dispatch:
|
|
9
|
+
|
|
10
|
+
permissions:
|
|
11
|
+
contents: read
|
|
12
|
+
|
|
13
|
+
jobs:
|
|
14
|
+
publish:
|
|
15
|
+
runs-on: ubuntu-latest
|
|
16
|
+
permissions:
|
|
17
|
+
id-token: write
|
|
18
|
+
contents: read
|
|
19
|
+
steps:
|
|
20
|
+
- uses: actions/checkout@v4
|
|
21
|
+
|
|
22
|
+
- name: Install uv
|
|
23
|
+
uses: astral-sh/setup-uv@v5
|
|
24
|
+
|
|
25
|
+
- name: Set up Python
|
|
26
|
+
uses: actions/setup-python@v5
|
|
27
|
+
with:
|
|
28
|
+
python-version: "3.12"
|
|
29
|
+
|
|
30
|
+
- name: Build distributions
|
|
31
|
+
run: uv build
|
|
32
|
+
|
|
33
|
+
- name: Publish to PyPI
|
|
34
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
wisk-0.3.0/.gitignore
ADDED
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
minimum_prek_version: "0.5.1"
|
|
2
|
+
default_install_hook_types: [pre-commit, pre-push]
|
|
3
|
+
|
|
4
|
+
repos:
|
|
5
|
+
- repo: local
|
|
6
|
+
hooks:
|
|
7
|
+
- id: ruff-check
|
|
8
|
+
name: ruff check
|
|
9
|
+
entry: uv run --no-sync ruff check
|
|
10
|
+
language: system
|
|
11
|
+
types: [python]
|
|
12
|
+
|
|
13
|
+
- id: ruff-format
|
|
14
|
+
name: ruff format check
|
|
15
|
+
entry: uv run --no-sync ruff format --check
|
|
16
|
+
language: system
|
|
17
|
+
types: [python]
|
|
18
|
+
|
|
19
|
+
- id: ty-check
|
|
20
|
+
name: ty type check
|
|
21
|
+
entry: uv run --no-sync ty check
|
|
22
|
+
language: system
|
|
23
|
+
pass_filenames: false
|
|
24
|
+
always_run: true
|
|
25
|
+
|
|
26
|
+
- id: bandit-check
|
|
27
|
+
name: bandit security audit
|
|
28
|
+
entry: uv run --no-sync bandit -r src/ -c pyproject.toml
|
|
29
|
+
language: system
|
|
30
|
+
pass_filenames: false
|
|
31
|
+
always_run: true
|
|
32
|
+
|
|
33
|
+
- id: vulture-check
|
|
34
|
+
name: vulture dead code check
|
|
35
|
+
entry: uv run --no-sync vulture src/ --min-confidence 80
|
|
36
|
+
language: system
|
|
37
|
+
pass_filenames: false
|
|
38
|
+
always_run: true
|
|
39
|
+
|
|
40
|
+
- id: pep723-check
|
|
41
|
+
name: check PEP 723 metadata in scripts
|
|
42
|
+
entry: uv run --no-sync scripts/check_pep723.py
|
|
43
|
+
language: system
|
|
44
|
+
pass_filenames: false
|
|
45
|
+
always_run: true
|
|
46
|
+
|
|
47
|
+
- id: version-check
|
|
48
|
+
name: check version sync & changelog presence
|
|
49
|
+
entry: uv run --no-sync scripts/check_version.py
|
|
50
|
+
language: system
|
|
51
|
+
pass_filenames: false
|
|
52
|
+
always_run: true
|
|
53
|
+
|
|
54
|
+
- id: okf-check
|
|
55
|
+
name: okf parser check (normative specs)
|
|
56
|
+
entry: uv run --no-sync okf-parser check knowledge/ --require-spec "../specs/{slug}.md" --normative-spec
|
|
57
|
+
language: system
|
|
58
|
+
pass_filenames: false
|
|
59
|
+
always_run: true
|
wisk-0.3.0/PKG-INFO
ADDED
|
@@ -0,0 +1,193 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: wisk
|
|
3
|
+
Version: 0.3.0
|
|
4
|
+
Summary: Contract-guided agent execution and persistent learning runtime built on OKF.
|
|
5
|
+
Project-URL: Homepage, https://github.com/franklinbaldo/wisk
|
|
6
|
+
Project-URL: Repository, https://github.com/franklinbaldo/wisk
|
|
7
|
+
Author-email: Franklin Silveira Baldo <franklinbaldo@gmail.com>
|
|
8
|
+
License-Expression: MIT
|
|
9
|
+
Requires-Python: >=3.12
|
|
10
|
+
Requires-Dist: cyclopts>=4.0
|
|
11
|
+
Requires-Dist: duckdb>=1.0
|
|
12
|
+
Requires-Dist: fastmcp>=3.0
|
|
13
|
+
Requires-Dist: ibis-framework[duckdb]>=9.0
|
|
14
|
+
Requires-Dist: networkx>=3.2
|
|
15
|
+
Requires-Dist: okf-parser>=0.45.8
|
|
16
|
+
Requires-Dist: pydantic>=2.7
|
|
17
|
+
Description-Content-Type: text/markdown
|
|
18
|
+
|
|
19
|
+
# Wisk
|
|
20
|
+
|
|
21
|
+
> **Contract-guided agent execution and persistent learning on OKF.**
|
|
22
|
+
|
|
23
|
+
`wisk` is an experimental agent runtime inspired by Google Research's 2026 work on compiling agent experience into persistent knowledge for skill evolution.
|
|
24
|
+
|
|
25
|
+
It uses [Open Knowledge Format (OKF)](https://github.com/franklinbaldo/okf-parser) to represent live execution state and persistent learning as an auditable typed knowledge graph.
|
|
26
|
+
|
|
27
|
+
## Consumer quickstart
|
|
28
|
+
|
|
29
|
+
Wisk is intended to be adopted by an existing repository, not reconstructed from a long prompt.
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
uvx wisk init .
|
|
33
|
+
wisk session start-next "Do the best useful work available in this repository"
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
`wisk init` creates a managed `.wisk/` bundle containing compatible normative contracts, canonical learning roles, and the standard consumer profile.
|
|
37
|
+
|
|
38
|
+
Managed runtime files can be refreshed with:
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
wisk upgrade .
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
Upgrade checks hashes before writing. If a Wisk-managed file was edited locally, the command reports a conflict and leaves the installation untouched. Consumer-owned files and runtime knowledge are never overwritten by managed upgrade.
|
|
45
|
+
|
|
46
|
+
See [RFC 0005](docs/rfc/0005-consumer-golden-path.md).
|
|
47
|
+
|
|
48
|
+
## What Wisk does
|
|
49
|
+
|
|
50
|
+
Agent repositories face two related problems:
|
|
51
|
+
|
|
52
|
+
1. a session can start from a prompt with weak structural guidance about what good execution must establish;
|
|
53
|
+
2. useful lessons from execution are easily lost or mixed into unstructured memory.
|
|
54
|
+
|
|
55
|
+
Wisk addresses both.
|
|
56
|
+
|
|
57
|
+
A work session starts from a typed `RunSpec`, creates an intentionally incomplete `LoopRun`, and progressively records readings, goals, decisions, evidence, checks, and an outcome. `okf-parser` validation makes missing contract state visible while the work is still happening.
|
|
58
|
+
|
|
59
|
+
```text
|
|
60
|
+
RunSpec
|
|
61
|
+
→ LoopRun scaffold
|
|
62
|
+
→ RunReading / RunGoal / RunDecision / RunEvidence / RunCheck
|
|
63
|
+
→ RunOutcome
|
|
64
|
+
→ Experience
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
That episodic evidence feeds the canonical three-role learning cycle:
|
|
68
|
+
|
|
69
|
+
```text
|
|
70
|
+
Skill creates/refines a candidate
|
|
71
|
+
↓
|
|
72
|
+
Experience executes real work and records what happened
|
|
73
|
+
↓
|
|
74
|
+
Wiki synthesizes and compares durable evidence
|
|
75
|
+
↓
|
|
76
|
+
Skill revisits the candidate and decides its lifecycle
|
|
77
|
+
└──────────────→ next Experience
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
The canonical roles are **Experience**, **Wiki**, and **Skill**. `SkillEvaluation` remains available as an optional explicit benchmark/review artifact when useful.
|
|
81
|
+
|
|
82
|
+
See [RFC 0004](docs/rfc/0004-canonical-learning-cycle.md).
|
|
83
|
+
|
|
84
|
+
## Standard profile
|
|
85
|
+
|
|
86
|
+
`wisk init` installs an opinionated but replaceable standard profile.
|
|
87
|
+
|
|
88
|
+
- **Experience** is ordinary useful work and is the on-demand fallback for an explicit `session start-next` call.
|
|
89
|
+
- **Wiki** becomes eligible after three new Experiences and has higher priority than ordinary Experience.
|
|
90
|
+
- **Skill** becomes eligible after six new Experiences. Wiki has higher priority, so synthesis runs before skill evolution when both are due.
|
|
91
|
+
|
|
92
|
+
The default rhythm is roughly:
|
|
93
|
+
|
|
94
|
+
```text
|
|
95
|
+
Experience × 3 → Wiki
|
|
96
|
+
Experience × 3 → Wiki → Skill
|
|
97
|
+
repeat
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
Those thresholds are product defaults, not universal laws. Consumers can specialize SessionTypes, RunSpecs, context policies, and cadence without redefining the core learning roles.
|
|
101
|
+
|
|
102
|
+
## Contract-guided execution
|
|
103
|
+
|
|
104
|
+
The run artifact is not a report written after the work. It exists before substantive execution begins.
|
|
105
|
+
|
|
106
|
+
```text
|
|
107
|
+
create scaffold
|
|
108
|
+
→ validate with okf-parser
|
|
109
|
+
→ inspect the next unsatisfied requirement
|
|
110
|
+
→ perform the next useful action
|
|
111
|
+
→ record typed state and evidence
|
|
112
|
+
→ validate again
|
|
113
|
+
→ leave a coherent outcome or handoff
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
Core concepts include `RunSpec`, `LoopRun`, `RunReading`, `RunGoal`, `RunDecision`, `RunEvidence`, `RunCheck`, `RunOutcome`, and `Handoff`.
|
|
117
|
+
|
|
118
|
+
Consumers specialize `RunSpec` rather than forcing domain rules into Wisk core. Software development, journalism, legal work, research, and other domains can require different readings, evidence, checks, and result states while sharing the same runtime.
|
|
119
|
+
|
|
120
|
+
## Persistent learning
|
|
121
|
+
|
|
122
|
+
- **`Experience`** — episodic evidence distilled from real execution.
|
|
123
|
+
- **`WikiEntry`** — durable knowledge synthesized across experiences.
|
|
124
|
+
- **`AgentSkill`** — reusable procedural guidance; active and experimental versions may coexist.
|
|
125
|
+
- **`SkillProposal`** — explicit change record/rationale for procedural evolution.
|
|
126
|
+
- **`SkillEvaluation`** — optional explicit benchmark or review record.
|
|
127
|
+
|
|
128
|
+
Procedural state is reversible while evidence and durable knowledge are cumulative. A weak candidate skill can be rejected without losing the experience that showed why it failed.
|
|
129
|
+
|
|
130
|
+
## CLI
|
|
131
|
+
|
|
132
|
+
Important entry points include:
|
|
133
|
+
|
|
134
|
+
```text
|
|
135
|
+
wisk init [repository]
|
|
136
|
+
wisk upgrade [repository]
|
|
137
|
+
wisk context <task>
|
|
138
|
+
wisk session next
|
|
139
|
+
wisk session start-next <task>
|
|
140
|
+
wisk start <task> [--session-type ...]
|
|
141
|
+
wisk check <run>
|
|
142
|
+
wisk run reading|goal|decision|evidence|check|outcome ...
|
|
143
|
+
wisk experience preview|record ...
|
|
144
|
+
wisk handoff list|create|continue ...
|
|
145
|
+
wisk serve
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
## Python API
|
|
149
|
+
|
|
150
|
+
```python
|
|
151
|
+
from wisk import Wisk
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
## Architecture boundary
|
|
155
|
+
|
|
156
|
+
```text
|
|
157
|
+
okf-parser
|
|
158
|
+
├── Markdown/frontmatter parsing
|
|
159
|
+
├── concept identity and graph traversal
|
|
160
|
+
├── Ibis / DuckDB / NetworkX integration
|
|
161
|
+
└── schema compilation and validation
|
|
162
|
+
|
|
163
|
+
wisk
|
|
164
|
+
├── RunSpec + live execution semantics
|
|
165
|
+
├── SessionType + policy/cadence composition
|
|
166
|
+
├── experience and knowledge consolidation
|
|
167
|
+
├── skill evolution lifecycle
|
|
168
|
+
├── consumer bootstrap + upgrade
|
|
169
|
+
└── CLI + FastMCP runtime
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
Wisk does not duplicate generic parsing or validation machinery from `okf-parser`.
|
|
173
|
+
|
|
174
|
+
## Development and dogfooding
|
|
175
|
+
|
|
176
|
+
Wisk develops itself through the same runtime. The repository's own `knowledge/` tree is a dogfood consumer with additional development-specific SessionTypes and policies.
|
|
177
|
+
|
|
178
|
+
The canonical Experience/Wiki/Skill roles are deliberately policy-neutral so other repositories do not inherit Wisk's software-development assumptions.
|
|
179
|
+
|
|
180
|
+
See [docs/architecture.md](docs/architecture.md) and [docs/dogfooding.md](docs/dogfooding.md).
|
|
181
|
+
|
|
182
|
+
## Development setup
|
|
183
|
+
|
|
184
|
+
```bash
|
|
185
|
+
git clone https://github.com/franklinbaldo/wisk.git
|
|
186
|
+
cd wisk
|
|
187
|
+
uv sync
|
|
188
|
+
uv run wisk info
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
## License
|
|
192
|
+
|
|
193
|
+
MIT © Franklin Baldo
|
wisk-0.3.0/README.md
ADDED
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
# Wisk
|
|
2
|
+
|
|
3
|
+
> **Contract-guided agent execution and persistent learning on OKF.**
|
|
4
|
+
|
|
5
|
+
`wisk` is an experimental agent runtime inspired by Google Research's 2026 work on compiling agent experience into persistent knowledge for skill evolution.
|
|
6
|
+
|
|
7
|
+
It uses [Open Knowledge Format (OKF)](https://github.com/franklinbaldo/okf-parser) to represent live execution state and persistent learning as an auditable typed knowledge graph.
|
|
8
|
+
|
|
9
|
+
## Consumer quickstart
|
|
10
|
+
|
|
11
|
+
Wisk is intended to be adopted by an existing repository, not reconstructed from a long prompt.
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
uvx wisk init .
|
|
15
|
+
wisk session start-next "Do the best useful work available in this repository"
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
`wisk init` creates a managed `.wisk/` bundle containing compatible normative contracts, canonical learning roles, and the standard consumer profile.
|
|
19
|
+
|
|
20
|
+
Managed runtime files can be refreshed with:
|
|
21
|
+
|
|
22
|
+
```bash
|
|
23
|
+
wisk upgrade .
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
Upgrade checks hashes before writing. If a Wisk-managed file was edited locally, the command reports a conflict and leaves the installation untouched. Consumer-owned files and runtime knowledge are never overwritten by managed upgrade.
|
|
27
|
+
|
|
28
|
+
See [RFC 0005](docs/rfc/0005-consumer-golden-path.md).
|
|
29
|
+
|
|
30
|
+
## What Wisk does
|
|
31
|
+
|
|
32
|
+
Agent repositories face two related problems:
|
|
33
|
+
|
|
34
|
+
1. a session can start from a prompt with weak structural guidance about what good execution must establish;
|
|
35
|
+
2. useful lessons from execution are easily lost or mixed into unstructured memory.
|
|
36
|
+
|
|
37
|
+
Wisk addresses both.
|
|
38
|
+
|
|
39
|
+
A work session starts from a typed `RunSpec`, creates an intentionally incomplete `LoopRun`, and progressively records readings, goals, decisions, evidence, checks, and an outcome. `okf-parser` validation makes missing contract state visible while the work is still happening.
|
|
40
|
+
|
|
41
|
+
```text
|
|
42
|
+
RunSpec
|
|
43
|
+
→ LoopRun scaffold
|
|
44
|
+
→ RunReading / RunGoal / RunDecision / RunEvidence / RunCheck
|
|
45
|
+
→ RunOutcome
|
|
46
|
+
→ Experience
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
That episodic evidence feeds the canonical three-role learning cycle:
|
|
50
|
+
|
|
51
|
+
```text
|
|
52
|
+
Skill creates/refines a candidate
|
|
53
|
+
↓
|
|
54
|
+
Experience executes real work and records what happened
|
|
55
|
+
↓
|
|
56
|
+
Wiki synthesizes and compares durable evidence
|
|
57
|
+
↓
|
|
58
|
+
Skill revisits the candidate and decides its lifecycle
|
|
59
|
+
└──────────────→ next Experience
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
The canonical roles are **Experience**, **Wiki**, and **Skill**. `SkillEvaluation` remains available as an optional explicit benchmark/review artifact when useful.
|
|
63
|
+
|
|
64
|
+
See [RFC 0004](docs/rfc/0004-canonical-learning-cycle.md).
|
|
65
|
+
|
|
66
|
+
## Standard profile
|
|
67
|
+
|
|
68
|
+
`wisk init` installs an opinionated but replaceable standard profile.
|
|
69
|
+
|
|
70
|
+
- **Experience** is ordinary useful work and is the on-demand fallback for an explicit `session start-next` call.
|
|
71
|
+
- **Wiki** becomes eligible after three new Experiences and has higher priority than ordinary Experience.
|
|
72
|
+
- **Skill** becomes eligible after six new Experiences. Wiki has higher priority, so synthesis runs before skill evolution when both are due.
|
|
73
|
+
|
|
74
|
+
The default rhythm is roughly:
|
|
75
|
+
|
|
76
|
+
```text
|
|
77
|
+
Experience × 3 → Wiki
|
|
78
|
+
Experience × 3 → Wiki → Skill
|
|
79
|
+
repeat
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
Those thresholds are product defaults, not universal laws. Consumers can specialize SessionTypes, RunSpecs, context policies, and cadence without redefining the core learning roles.
|
|
83
|
+
|
|
84
|
+
## Contract-guided execution
|
|
85
|
+
|
|
86
|
+
The run artifact is not a report written after the work. It exists before substantive execution begins.
|
|
87
|
+
|
|
88
|
+
```text
|
|
89
|
+
create scaffold
|
|
90
|
+
→ validate with okf-parser
|
|
91
|
+
→ inspect the next unsatisfied requirement
|
|
92
|
+
→ perform the next useful action
|
|
93
|
+
→ record typed state and evidence
|
|
94
|
+
→ validate again
|
|
95
|
+
→ leave a coherent outcome or handoff
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
Core concepts include `RunSpec`, `LoopRun`, `RunReading`, `RunGoal`, `RunDecision`, `RunEvidence`, `RunCheck`, `RunOutcome`, and `Handoff`.
|
|
99
|
+
|
|
100
|
+
Consumers specialize `RunSpec` rather than forcing domain rules into Wisk core. Software development, journalism, legal work, research, and other domains can require different readings, evidence, checks, and result states while sharing the same runtime.
|
|
101
|
+
|
|
102
|
+
## Persistent learning
|
|
103
|
+
|
|
104
|
+
- **`Experience`** — episodic evidence distilled from real execution.
|
|
105
|
+
- **`WikiEntry`** — durable knowledge synthesized across experiences.
|
|
106
|
+
- **`AgentSkill`** — reusable procedural guidance; active and experimental versions may coexist.
|
|
107
|
+
- **`SkillProposal`** — explicit change record/rationale for procedural evolution.
|
|
108
|
+
- **`SkillEvaluation`** — optional explicit benchmark or review record.
|
|
109
|
+
|
|
110
|
+
Procedural state is reversible while evidence and durable knowledge are cumulative. A weak candidate skill can be rejected without losing the experience that showed why it failed.
|
|
111
|
+
|
|
112
|
+
## CLI
|
|
113
|
+
|
|
114
|
+
Important entry points include:
|
|
115
|
+
|
|
116
|
+
```text
|
|
117
|
+
wisk init [repository]
|
|
118
|
+
wisk upgrade [repository]
|
|
119
|
+
wisk context <task>
|
|
120
|
+
wisk session next
|
|
121
|
+
wisk session start-next <task>
|
|
122
|
+
wisk start <task> [--session-type ...]
|
|
123
|
+
wisk check <run>
|
|
124
|
+
wisk run reading|goal|decision|evidence|check|outcome ...
|
|
125
|
+
wisk experience preview|record ...
|
|
126
|
+
wisk handoff list|create|continue ...
|
|
127
|
+
wisk serve
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
## Python API
|
|
131
|
+
|
|
132
|
+
```python
|
|
133
|
+
from wisk import Wisk
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
## Architecture boundary
|
|
137
|
+
|
|
138
|
+
```text
|
|
139
|
+
okf-parser
|
|
140
|
+
├── Markdown/frontmatter parsing
|
|
141
|
+
├── concept identity and graph traversal
|
|
142
|
+
├── Ibis / DuckDB / NetworkX integration
|
|
143
|
+
└── schema compilation and validation
|
|
144
|
+
|
|
145
|
+
wisk
|
|
146
|
+
├── RunSpec + live execution semantics
|
|
147
|
+
├── SessionType + policy/cadence composition
|
|
148
|
+
├── experience and knowledge consolidation
|
|
149
|
+
├── skill evolution lifecycle
|
|
150
|
+
├── consumer bootstrap + upgrade
|
|
151
|
+
└── CLI + FastMCP runtime
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
Wisk does not duplicate generic parsing or validation machinery from `okf-parser`.
|
|
155
|
+
|
|
156
|
+
## Development and dogfooding
|
|
157
|
+
|
|
158
|
+
Wisk develops itself through the same runtime. The repository's own `knowledge/` tree is a dogfood consumer with additional development-specific SessionTypes and policies.
|
|
159
|
+
|
|
160
|
+
The canonical Experience/Wiki/Skill roles are deliberately policy-neutral so other repositories do not inherit Wisk's software-development assumptions.
|
|
161
|
+
|
|
162
|
+
See [docs/architecture.md](docs/architecture.md) and [docs/dogfooding.md](docs/dogfooding.md).
|
|
163
|
+
|
|
164
|
+
## Development setup
|
|
165
|
+
|
|
166
|
+
```bash
|
|
167
|
+
git clone https://github.com/franklinbaldo/wisk.git
|
|
168
|
+
cd wisk
|
|
169
|
+
uv sync
|
|
170
|
+
uv run wisk info
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
## License
|
|
174
|
+
|
|
175
|
+
MIT © Franklin Baldo
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
---
|
|
2
|
+
type: Changelog
|
|
3
|
+
version: 0.2.11
|
|
4
|
+
date: 2026-09-06
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Agent-facing session and run surfaces
|
|
8
|
+
|
|
9
|
+
- adds MCP tools for starting the next eligible session and recording every typed live-run component;
|
|
10
|
+
- adds CLI `session next` / `session start-next` and `run reading|goal|decision|evidence|check|outcome` commands;
|
|
11
|
+
- allows the core MCP and CLI context/start/check operations to target an explicit Wisk bundle path;
|
|
12
|
+
- exposes `target_session_type` through CLI handoff creation;
|
|
13
|
+
- keeps each mutation effect-explicit and delegates persistence to the validated Wisk runtime service layer.
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
---
|
|
2
|
+
type: Changelog
|
|
3
|
+
version: 0.2.7
|
|
4
|
+
date: 2026-09-05
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Built-in Wisk session types
|
|
8
|
+
|
|
9
|
+
- adds inference, wiki-maintainer, skill-evolver, and evaluator SessionTypes alongside development;
|
|
10
|
+
- gives each built-in its own RunSpec and curated context policy;
|
|
11
|
+
- keeps the inference session focused on active skills rather than injected wiki knowledge;
|
|
12
|
+
- gives wiki maintenance access to experiences plus existing WikiEntry knowledge;
|
|
13
|
+
- gives skill evolution both consolidated wiki knowledge and supporting experiences;
|
|
14
|
+
- encourages pattern-shaped WikiEntry consolidation through prompt nudges without introducing a Pattern ontology type.
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
---
|
|
2
|
+
type: Changelog
|
|
3
|
+
version: 0.2.2
|
|
4
|
+
date: 2026-09-05
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Actionable contract-guided checks
|
|
8
|
+
|
|
9
|
+
- faz `Wisk.check_run()` devolver `next_action` derivado da primeira exigência tipada ainda não satisfeita;
|
|
10
|
+
- preserva a ordem declarada pelo `RunSpec`, tornando a orientação determinística e diretamente ligada ao contrato da rodada;
|
|
11
|
+
- devolve uma ação explícita `complete` quando a rodada satisfaz seu `RunSpec`;
|
|
12
|
+
- preserva `unsatisfied` como diagnóstico completo e mantém CLI/MCP alinhados pela mesma resposta do runtime;
|
|
13
|
+
- cobre o comportamento com contrato TDD para scaffold incompleto e rodada conforme.
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
---
|
|
2
|
+
type: Changelog
|
|
3
|
+
version: 0.3.0
|
|
4
|
+
date: 2026-09-06
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Consumer golden path
|
|
8
|
+
|
|
9
|
+
- adds non-destructive `wisk init` for existing repositories;
|
|
10
|
+
- installs managed normative specs, canonical Experience/Wiki/Skill contracts, and a standard consumer profile;
|
|
11
|
+
- installs a managed `.wisk/.gitignore` so reproducible manifest/spec/system state does not pollute consumer diffs while local and learned state remains versionable;
|
|
12
|
+
- preserves versioned consumer/runtime knowledge (`local`, `experiences`, `wiki`, `skills`) when a fresh clone runs `init`;
|
|
13
|
+
- adds manifest-backed `wisk upgrade` with SHA-256 conflict detection and rollback-safe final writes;
|
|
14
|
+
- makes explicit `session start-next` fall back to on-demand Experience while preserving automatic `session next` semantics;
|
|
15
|
+
- autodiscovers `.wisk/knowledge` from the repository root in CLI commands;
|
|
16
|
+
- packages normative and canonical bootstrap assets in the wheel;
|
|
17
|
+
- makes scheduler selection prefer leaf SessionType specializations so consumer children replace managed defaults without priority tricks;
|
|
18
|
+
- makes `RunSpec.parent_spec` operational: required readings, goals, evidence, and checks append into the effective pinned contract;
|
|
19
|
+
- lets Handoffs targeting a parent SessionType activate compatible leaf specializations;
|
|
20
|
+
- documents the canonical cross-session Experience → Wiki → Skill evaluation lifecycle and consumer/core responsibility boundary.
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
---
|
|
2
|
+
type: Changelog
|
|
3
|
+
version: 0.2.0
|
|
4
|
+
date: 2026-09-05
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Contract-guided live runs
|
|
8
|
+
|
|
9
|
+
- adiciona `Wisk.start_run()` e `Wisk.check_run()`;
|
|
10
|
+
- expõe `wisk start` e `wisk check` no CLI;
|
|
11
|
+
- expõe `wisk_start` e `wisk_check` no FastMCP;
|
|
12
|
+
- combina validação estrutural do `okf-parser` com requisitos operacionais definidos por `RunSpec`;
|
|
13
|
+
- adiciona testes para o ciclo scaffold incompleto → contrato satisfeito.
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
---
|
|
2
|
+
type: Changelog
|
|
3
|
+
version: 0.2.3
|
|
4
|
+
date: 2026-09-05
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Experience Recording joins contract-guided execution
|
|
8
|
+
|
|
9
|
+
- restores `preview_experience()` and `record_experience()` on top of the RunSpec/LoopRun runtime;
|
|
10
|
+
- validates every persisted Experience with the normative OKF gate and rolls back invalid writes;
|
|
11
|
+
- exposes `wisk experience preview|record` plus FastMCP preview/write tools;
|
|
12
|
+
- lets an Experience reference the `LoopRun` that produced it, preserving execution-to-learning provenance;
|
|
13
|
+
- preserves the original causal TDD history from PR #23 while reanchoring the implementation on the current runtime.
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
---
|
|
2
|
+
type: Changelog
|
|
3
|
+
version: 0.2.4
|
|
4
|
+
date: 2026-09-05
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Cross-session Handoff runtime
|
|
8
|
+
|
|
9
|
+
- adiciona `Handoff` como conceito OKF tipado para trabalho material deixado entre sessões;
|
|
10
|
+
- separa `RunOutcome.result_state` de `work_status: complete | partial`;
|
|
11
|
+
- exige Handoff ativo quando uma rodada declara trabalho parcial;
|
|
12
|
+
- faz `context` e `start` exporem handoffs ativos e relevantes;
|
|
13
|
+
- adiciona criação, listagem e continuação/arquivamento com provenance `created_by_run → continued_by_run`;
|
|
14
|
+
- expõe o lifecycle na CLI e no FastMCP;
|
|
15
|
+
- cobre o ciclo completo com testes de retomada entre duas `LoopRun`.
|