Repository navigation
Description
Outcome
Continue the repository renewal effort beyond the first strict-typing and surface-contract program by targeting the remaining weak semantic boundaries directly.
This follow-up program should focus on places that are already type-checked but still rely on broad Any/object plumbing, repeated casts, and dict-shaped runtime payloads.
Problem or opportunity
The previous renewal program successfully tightened schema/source ingestion, storage/runtime seams, surface contraction, and verification alignment. What remains is not untyped code. It is code that is technically accepted by strict mypy while still underspecifying meaning.
A quick density scan after the merged verification tranche shows the main remaining pressure concentrated in:
polylogue/schemas/polylogue/lib/- selected
polylogue/sources/,polylogue/storage/, andpolylogue/pipeline/follow-through seams
These areas now dominate the remaining Any, object, and cast(...) usage in non-test code.
Expected scope
Program-level tracking across follow-up PRs that may touch:
polylogue/schemas/polylogue/lib/- selected
polylogue/sources/ - selected
polylogue/storage/ - selected
polylogue/pipeline/ - only the minimal
tests//devtools/fallout needed to prove each slice
Constraints and invariants
- Keep the work in coherent PR slices, not one mega-branch.
- Merge each completed PR before cutting the next branch.
- Use workers only for narrow mechanical propagation after local anchor rewrites establish the target contract shape.
- Prefer replacing broad payload containers with explicit intermediate records, aliases, and narrowing helpers.
- Preserve archive semantics and externally visible behavior while simplifying implementation shape.
Acceptance criteria
- Follow-up issues exist for the first semantic-precision slices.
- Each slice lands as a coherent PR with
devtools verifygreen. - The program materially reduces remaining
Any/object/cast(...)pressure in non-test code. - The renewed code expresses runtime meaning more directly instead of hiding it behind loosely typed containers.
Verification plan
Each follow-up PR should run devtools verify before merge.
Context and evidence
Post-merge density snapshot in non-test code:
schemas: highest remainingAnyandobjectdensitylib: next-highestAnydensity with substantialobjectcarry-oversourcesandstorage: still carry notableobject/cast(...)pressure
Non-goals or explicitly deferred work
- Rewriting already-clean surface areas again without a concrete architectural reason.
- Treating strict-type compliance as the final goal.
- One omnibus continuation branch.
Activity
Sinity commentedon Apr 20, 2026
Follow-up tranche issues are now in place under this program umbrella:
The intended execution order remains: merge each completed tranche before cutting the next branch, with workers used only for narrow mechanical propagation after local anchor rewrites establish the target shape.
Sinity commentedon Apr 20, 2026
Progress update:
Completed slices:
Remaining queued slices:
refactor: reduce weak payload plumbing across lib and storage runtimerefactor: contract CLI, MCP, and UI surfaces over renewed substraterefactor: introduce artifact graph and clarify health/readiness namingrefactor: renew tests and verification over semantic-precision substrateContinuing immediately into #263 from fresh
master.Sinity commentedon Apr 21, 2026
Closing this broad semantic-precision tracker as completed/superseded.
The original strict-typing and broad weak-contract campaign has effectively landed: current scans show no mypy exclude list, no
type: ignore, nocast(, no# noqa, no TODO/FIXME/XXX, and no realAnytype usage in the checked source/test/devtools surfaces.The remaining work is now structural rather than mechanical typing cleanup, and is tracked in narrower issues:
Future work should use those narrower issues rather than this now-stale campaign issue.
refactor: tighten schema and lib payload boundary contracts (#253)
refactor: rebuild source dispatch and drive ingestion boundary contra…
refactor: rebuild schema generation and audit boundary contracts (#258)
refactor: tighten schema and lib payload boundary contracts (#253)
refactor: rebuild source dispatch and drive ingestion boundary contra…
refactor: rebuild schema generation and audit boundary contracts (#258)
refactor: tighten schema and lib payload boundary contracts (#253)
refactor: rebuild source dispatch and drive ingestion boundary contra…
refactor: rebuild schema generation and audit boundary contracts (#258)
refactor: tighten schema and lib payload boundary contracts (#253)
refactor: rebuild source dispatch and drive ingestion boundary contra…
refactor: rebuild schema generation and audit boundary contracts (#258)