Skip to content

refactor(pipeline): own run activity accounting - #668

Merged
Sinity merged 1 commit into
masterfrom
feature/refactor/pipeline-run-activity-clean
May 1, 2026
Merged

Sinity merged 1 commit into
masterfrom
feature/refactor/pipeline-run-activity-clean

Conversation

@Sinity

@Sinity Sinity commented May 1, 2026

Copy link
Copy Markdown
Owner

Summary

Move run-result conversation activity accounting from polylogue.lib into polylogue.pipeline.

Problem

run_activity.py only interprets pipeline run counts and drift payloads for observers and run display surfaces. Keeping it as a lib primitive made the root library bucket own pipeline accounting semantics.

Solution

  • Rename polylogue/lib/run_activity.py to polylogue/pipeline/run_activity.py.
  • Update run observers and CLI run display helpers to import the pipeline owner.
  • Remove the file from the remaining lib-root topology primitive list and regenerate topology docs.

Ref #635

Verification

  • devtools build-topology-projection && devtools verify-topology — realized=696 declared=696 blocking=False
  • ruff check polylogue/ tests/ devtools/ — all checks passed
  • mypy polylogue/ — no issues found in 696 source files
  • pytest -q tests/unit/cli/test_run_display_workflow_runtime.py — 7 passed
  • devtools render-all --check — sync OK
  • pre-push devtools verify --quick — all checks passed

Copilot AI review requested due to automatic review settings May 1, 2026 20:56
@Sinity
Sinity merged commit 4293f38 into master May 1, 2026
12 of 13 checks passed
@coderabbitai

coderabbitai Bot commented May 1, 2026

Copy link
Copy Markdown

Warning

Rate limit exceeded

@Sinity has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 35 minutes and 44 seconds before requesting another review.

To keep reviews running without waiting, you can enable usage-based add-on for your organization. This allows additional reviews beyond the hourly cap. Account admins can enable it under billing.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: d06aa9c8-d5c6-4c84-a03d-ba32054f2868

📥 Commits

Reviewing files that changed from the base of the PR and between 7d89099 and 767a189.

📒 Files selected for processing (7)
  • devtools/build_topology_projection.py
  • docs/plans/topology-target.yaml
  • docs/topology-status.md
  • polylogue/cli/shared/formatting.py
  • polylogue/cli/shared/run_watch_workflow.py
  • polylogue/pipeline/observers.py
  • polylogue/pipeline/run_activity.py
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/refactor/pipeline-run-activity-clean

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
Review rate limit: 0/1 reviews remaining, refill in 35 minutes and 44 seconds.

Comment @coderabbitai help to get the list of available commands and usage tips.

@Sinity
Sinity deleted the feature/refactor/pipeline-run-activity-clean branch May 1, 2026 20:56
@github-actions

github-actions Bot commented May 1, 2026

Copy link
Copy Markdown
Contributor

Polylogue Proof Pack

Refs: origin/master..HEAD
Changed paths: 0

Affected Domains

  • none

Required Gates

  • devtools verify --quick — full PR gate remains explicit
  • devtools verify — full PR gate remains explicit
  • devtools build-package — deployment readiness gate; run when packaging or release confidence matters
  • nix flake check — deployment readiness gate; run when packaging or release confidence matters

Known Gaps

  • none for affected domains

Oracle / Cost

  • oracle mix: {}
  • cost tier: {}
  • stale evidence: 0
  • manual review cells: 0

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Moves pipeline run-result conversation activity accounting out of the polylogue.lib primitives bucket and into the pipeline owner (polylogue.pipeline), updating downstream imports and topology documentation to match the new ownership model.

Changes:

  • Add polylogue/pipeline/run_activity.py containing conversation_activity_counts.
  • Update pipeline observers and CLI run display helpers to import from polylogue.pipeline.run_activity.
  • Update topology target/docs and devtools primitive lists to remove lib/run_activity.py from lib-root primitives.

Reviewed changes

Copilot reviewed 6 out of 7 changed files in this pull request and generated no comments.

Show a summary per file
File Description
polylogue/pipeline/run_activity.py New pipeline-owned helper for conversation activity accounting from run counts/drift.
polylogue/pipeline/observers.py Import updated to use pipeline-owned run activity helper.
polylogue/cli/shared/run_watch_workflow.py Import updated to use pipeline-owned run activity helper.
polylogue/cli/shared/formatting.py Import updated to use pipeline-owned run activity helper for display formatting.
docs/topology-status.md Regenerated topology status counts reflecting the move out of lib-root primitives.
docs/plans/topology-target.yaml Remove polylogue/lib/run_activity.py from lib-root primitives and add pipeline entry.
devtools/build_topology_projection.py Remove run_activity.py from the lib-root primitive filename set.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sinity added a commit that referenced this pull request May 7, 2026
## Summary
Move run-result conversation activity accounting from `polylogue.lib`
into `polylogue.pipeline`.

## Problem
`run_activity.py` only interprets pipeline run counts and drift payloads
for observers and run display surfaces. Keeping it as a `lib` primitive
made the root library bucket own pipeline accounting semantics.

## Solution
- Rename `polylogue/lib/run_activity.py` to
`polylogue/pipeline/run_activity.py`.
- Update run observers and CLI run display helpers to import the
pipeline owner.
- Remove the file from the remaining `lib-root` topology primitive list
and regenerate topology docs.

Ref #635

## Verification
- `devtools build-topology-projection && devtools verify-topology` —
realized=696 declared=696 blocking=False
- `ruff check polylogue/ tests/ devtools/` — all checks passed
- `mypy polylogue/` — no issues found in 696 source files
- `pytest -q tests/unit/cli/test_run_display_workflow_runtime.py` — 7
passed
- `devtools render-all --check` — sync OK
- pre-push `devtools verify --quick` — all checks passed
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.

2 participants