Skip to content

(CODUX-142) Add weighted task progress calculator - #2853

Merged
numnx merged 2 commits into
feature/CODUX-204-sprint-progressfrom
task/feature-codux-20-t01-codex-7bfb17f7-mrfqd1rq
Jul 11, 2026
Merged

(CODUX-142) Add weighted task progress calculator#2853
numnx merged 2 commits into
feature/CODUX-204-sprint-progressfrom
task/feature-codux-20-t01-codex-7bfb17f7-mrfqd1rq

Conversation

@numnx

@numnx numnx commented Jul 11, 2026

Copy link
Copy Markdown
Collaborator

🧩 Task: Add weighted task progress calculator

Automated task PR opened by Code UX for T01.

📋 Summary

Sprint: Sprint 204 · Sprint Progress · Task: T01

Expose live weighted sprint completion using task lifecycle stages and coding tool-call telemetry, preserve raw completed-task counts, and refresh/render fractional progress accurately across the dashboard and documentation.

🤖 Model & Provider

Provider Codex CLI
Model gpt-5.6-sol

⏱️ Timing

Started 2026-07-11 02:13:23 UTC
Finished 2026-07-11 02:20:26 UTC
Duration 7m 3s

📊 Token Usage

Metric Value
Input tokens 78,109
Cached input tokens 1,371,136
Output tokens 9,794
Total tokens 1,459,039
Invocations 2
Tool calls 23
Active time 6m 7s

Included usage estimate (subscription/local login): $1.37

✅ QA Review

⏳ QA review runs after this PR is opened. Check the task card in the dashboard for the outcome once it lands.

📝 Full Task Prompt
## Objective
Add a side-effect-free task progress calculator for the sprint weighting rules in CODUXCODUX-142.

## Scope
- `src/domain/sprint/sprint-progress.ts`
- `tests/backend/domain/sprint/sprint-progress.test.ts`
- Task status and merge-indicator values from `src/contracts/project-management-types.ts` and `src/contracts/app-types.ts`

## Implementation Requirements
1. Define the task weights: pending contributes `0`, coding contributes up to `0.5`, CI/post-coding gate progress contributes `0.75`, and settled completion contributes `1.0`.
2. For tasks still coding, add `0.005` per coding provider tool call, clamp the count at 100, and ignore negative or invalid counts.
3. Treat `completed`, merged states, and canonical settled merge indicators as full completion; treat `CI`, `QA_PENDING`, `MERGE_BLOCKED`, and `MERGE_CONFLICT` as post-coding progress; keep `coding_completed` at `0.5` and preserve partial tool-call progress for unfinished coding states.
4. Add focused tests for empty tasks, 100-call capping, coding completion, CI progress, no-CI completion jumps, settled merge states, and mixed task totals rounded to one decimal percentage point.

## Constraints
- Keep the helper pure and reusable from repository read models.
- Align state interpretation with `src/domain/sprint/task-pipeline-stage.ts`; do not change task lifecycle transitions.
- Do not add a database column or migration for derived sprint progress.

## Verification
- Run `pnpm run test:backend -- tests/backend/domain/sprint/sprint-progress.test.ts`.
- Run `pnpm run typecheck` and confirm the helper and tests compile without new errors.
🌿 Branch Info

Base: feature/CODUX-204-sprint-progress
Head: task/feature-codux-20-t01-codex-7bfb17f7-mrfqd1rq


🤖 Generated by Code UX

@numnx
numnx merged commit 8a3bc7d into feature/CODUX-204-sprint-progress Jul 11, 2026
1 check passed
@numnx
numnx deleted the task/feature-codux-20-t01-codex-7bfb17f7-mrfqd1rq branch July 11, 2026 02:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant