8000 refactor(harness): time tool steps with Pi's execution duration by geminixiang · Pull Request #187 · geminixiang/mikan · GitHub
[go: up one dir, main page]

Skip to content

refactor(harness): time tool steps with Pi's execution duration - #187

Merged
geminixiang merged 1 commit into
mainfrom
refactor/pi-tool-events
Oct 17, 2026
Merged

geminixiang merged 1 commit into
mainfrom
refactor/pi-tool-events

Conversation

@geminixiang
@geminixiang geminixiang commented Oct 17, 2026 •
Copy link
Copy Markdown
Owner

Pi 1.1 records how long each tool's execute() took on its result (durationMs). Tool metrics, spans, logs, and the budget stop report use it, and fall back to the wall clock between start and end events only when Pi has none (calls aborted or interrupted before a result).

Not changed: compaction_end still reads the task outcome. Pi's event carries only error, and an aborted compaction leaves pi.live.compactionFailure unchanged, so dropping the lookup would log an aborted compaction as complete.

Acceptance

Case main branch
tool_execution_end carries Pi's durationMs on a real tool run fail pass
Budget stop reports Pi's execution time, not event wall time fail pass
Existing budget stop report from wall-clock timing pass pass

Verification

  • Full gate (lint, fmt, knip, build, typecheck, test) passes on the branch.
  • Real-platform check and Slack E2E (slack-e2e.yml) not yet run: this changes the run loop and its tools, so it is on the Slack message path; they wait for approval.

Research: docs/research/pi-1.3-retirement-2026-10.md (added in #186).

Pi 1.1 records how long each tool's execute() took on its result. Tool metrics, spans, logs, and the budget stop report now use it, and fall back to the wall clock between start and end events only for calls Pi never ran to a result, such as aborted ones.
@geminixiang
geminixiang merged commit 1090839 into main Oct 17, 2026
5 checks passed
@geminixiang
geminixiang deleted the refactor/pi-tool-events branch October 17, 2026 15:03
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

0