Workplan refinement and examples

This commit is contained in:
2026-05-14 21:49:43 +02:00
parent 28ce4b3f65
commit f8f20c7c32
13 changed files with 726 additions and 23 deletions

View File

@@ -3,10 +3,10 @@ id: MKTT-WP-0018
type: workplan
title: "Source Adapter Interface And Markdown Normalization Contract"
domain: markitect
status: todo
status: active
owner: markitect-tool
topic_slug: markitect
planning_priority: P1
planning_priority: P0
planning_order: 145
depends_on_workplans:
- MKTT-WP-0013
@@ -70,7 +70,8 @@ new `markitect-filter` repo.
`MKTT-WP-0019` must run first and pin the v1 contract details for this
implementation: field-level normalized model semantics, read-only protocol
shape, external package entry point discovery, CLI/API output envelopes, and
fake adapter contract-test expectations.
fake adapter contract-test expectations. Those decisions are captured in
`docs/source-adapter-contract.md`.
`markitect-tool` should define:
@@ -120,8 +121,8 @@ Implement the cross-repo architecture pinned by `MKTT-WP-0019`:
- `kontextual-engine` can ingest adapter outputs into durable knowledge assets
Output: architecture note covering responsibilities, extension package shape,
the pinned entry point contract, dependency policy, and migration path from the
current `infospace-bench` EPUB spike.
the `docs/source-adapter-contract.md` entry point contract, dependency policy,
and migration path from the current `infospace-bench` EPUB spike.
## P18.2 - Canonical source-to-markdown data model
@@ -132,7 +133,8 @@ priority: high
state_hub_task_id: "f8164264-a9c1-4c82-8617-76bbb84a51bb"
```
Implement the normalized output model specified by `MKTT-WP-0019`:
Implement the normalized output model specified by
`docs/source-adapter-contract.md`:
- `SourceAsset`
- `SourceMetadata`
@@ -154,7 +156,8 @@ The model should represent:
- lossiness/quality signals
- adapter name/version/options
Output: public data model, serialization tests, and normalization contract
Output: public data model, serialization tests using
`examples/source-adapters/normalized-document.json`, and normalization contract
documentation matching the field-level v1 specification.
## P18.3 - Source adapter protocol and capability descriptors
@@ -199,7 +202,7 @@ Wire source adapters into the existing internal extension framework:
- register source adapter descriptors
- discover package-provided adapters through the entry point group pinned by
`MKTT-WP-0019`
`docs/source-adapter-contract.md`
- expose adapter capabilities via extension listing/inspection
- report missing optional dependency diagnostics
- ensure adapter packages can remain independently versioned
@@ -284,3 +287,5 @@ Output: migration note and follow-up workplan seeds for `markitect-filter` and
`markitect-tool` or `infospace-bench`.
- Writer/export adapter support is explicitly deferred beyond the v1 read
adapter contract.
- Implementation behavior matches `docs/source-adapter-contract.md` and the
fixtures in `examples/source-adapters/`.

View File

@@ -3,10 +3,10 @@ id: MKTT-WP-0019
type: workplan
title: "Source Adapter Contract Refinement"
domain: markitect
status: active
status: done
owner: markitect-tool
topic_slug: markitect
planning_priority: P0
planning_priority: complete
planning_order: 142
depends_on_workplans:
- MKTT-WP-0013
@@ -82,7 +82,7 @@ The v1 source adapter contract should be:
```task
id: MKTT-WP-0019-T001
status: todo
status: done
priority: high
state_hub_task_id: "0aa1d9a3-6cf8-47ab-8585-f23b2512d19b"
```
@@ -99,11 +99,15 @@ Define the v1 source adapter scope:
Output: concise architecture note or source-adapter contract section that
`MKTT-WP-0018` can implement directly.
Implemented: `docs/source-adapter-contract.md` defines the v1 read-only scope,
local-file-first posture, external package shape, optional dependency policy,
and compatibility boundary for `markitect-filter`.
## P19.2 - Specify normalized data model fields and serialization
```task
id: MKTT-WP-0019-T002
status: todo
status: done
priority: high
state_hub_task_id: "fabd3e76-3c2c-43cb-92b2-2322bd933fa7"
```
@@ -125,11 +129,17 @@ anchors, source hrefs, page/section references, and adapter metadata.
Output: model contract documentation and fixture-shaped examples.
Implemented: `docs/source-adapter-contract.md` pins field-level model contracts
for source assets, metadata, provenance, segments, normalized documents, and
quality. `examples/source-adapters/normalized-document.json` and
`examples/source-adapters/normalized-output.md` provide fixture-shaped
examples.
## P19.3 - Specify read adapter protocol and selection semantics
```task
id: MKTT-WP-0019-T003
status: todo
status: done
priority: high
state_hub_task_id: "2d559e3b-1515-4c88-8ed9-3895026cd2ca"
```
@@ -147,11 +157,16 @@ Define the v1 read protocol:
Output: protocol contract that can be implemented as Python `Protocol`
classes in `MKTT-WP-0018`.
Implemented: `docs/source-adapter-contract.md` defines the v1
`SourceReadAdapter` protocol, request/result names, option handling, adapter
selection semantics, and deterministic diagnostics for unsupported, malformed,
and dependency-missing inputs.
## P19.4 - Define package entry point and registry contract
```task
id: MKTT-WP-0019-T004
status: todo
status: done
priority: high
state_hub_task_id: "3d661d24-2496-405a-b525-c7e6d8eb4e68"
```
@@ -170,11 +185,17 @@ Define how external source adapter packages register with `markitect-tool`:
Output: discovery contract and fake entry point test plan for
`MKTT-WP-0018`.
Implemented: `docs/source-adapter-contract.md` defines the
`markitect_tool.source_adapters` entry point group, accepted entry point object
shapes, descriptor mapping to `ExtensionDescriptor`, duplicate handling, and
dependency diagnostics. `examples/source-adapters/fake-adapter-pyproject.toml`
provides the fake entry point fixture.
## P19.5 - Pin CLI/API output envelopes and exit behavior
```task
id: MKTT-WP-0019-T005
status: todo
status: done
priority: medium
state_hub_task_id: "2c30b0c7-683e-4d60-8268-0b49660f2e30"
```
@@ -192,11 +213,17 @@ Specify the public source commands and library functions:
Output: CLI/API contract note and expected-output fixtures.
Implemented: `docs/source-adapter-contract.md` pins the `mkt source` command
surface, formats, options, exit behavior, and public API export names.
`examples/source-adapters/adapter-list.json` and
`examples/source-adapters/inspect-result.json` provide expected-output
fixtures.
## P19.6 - Prepare contract-test and markitect-filter handoff criteria
```task
id: MKTT-WP-0019-T006
status: todo
status: done
priority: high
state_hub_task_id: "f6845a4d-3465-40b3-970a-714cfafe282c"
```
@@ -219,6 +246,10 @@ Also seed the `markitect-filter` handoff:
Output: contract-test checklist and handoff note.
Implemented: `docs/source-adapter-contract.md` includes the WP0018 contract
test checklist and the first `markitect-filter` EPUB3 handoff descriptor,
fixture expectations, and extraction responsibilities.
## Acceptance
- `MKTT-WP-0018` has no unresolved v1 contract ambiguity around model fields,