Skip to content

Unify pipeline domain checks on the profile detector#180

Merged
Jiaaqiliu merged 1 commit intoaiming-lab:mainfrom
CKwin26:codex/detector-unification
Mar 30, 2026
Merged

Unify pipeline domain checks on the profile detector#180
Jiaaqiliu merged 1 commit intoaiming-lab:mainfrom
CKwin26:codex/detector-unification

Conversation

@CKwin26
Copy link
Copy Markdown
Contributor

@CKwin26 CKwin26 commented Mar 29, 2026

Summary

  • route the legacy researchclaw.pipeline._domain helper through the newer researchclaw.domains.detector profile system
  • make Stage 9's BenchmarkAgent gating reuse the same detected DomainProfile instead of re-running the old coarse detector
  • keep the old tuple API for existing callers while removing split-brain behavior between old and new domain logic

Why

AutoResearchClaw currently has two domain-detection paths in the pipeline:

  • the newer profile-based detector used to write stage-09/domain_profile.json
  • the older coarse _detect_domain() helper still used by some pipeline call sites, including the BenchmarkAgent gate in Stage 9

That split can lead to contradictory behavior inside the same run. In one recent repair workflow for an engineering-drawing circle-localization project, Stage 9 persisted a detailed domain profile while BenchmarkAgent still followed the coarse path and proceeded under a different detector path. The root issue was that the pipeline was not actually using one shared detector.

This PR makes the old helper a compatibility wrapper around the canonical profile detector, then updates Stage 9 to reuse the already-computed profile when deciding whether BenchmarkAgent should run.

Changes

  • replace the old keyword-based implementation in researchclaw/pipeline/_domain.py with a compatibility wrapper around researchclaw.domains.detector
  • map detailed profile ids like ml_vision / ml_tabular back to the legacy coarse tuple interface for older call sites
  • reuse the Stage 9 DomainProfile for BenchmarkAgent gating in researchclaw/pipeline/stage_impls/_experiment_design.py

Validation

  • python -m compileall researchclaw/pipeline/_domain.py researchclaw/pipeline/stage_impls/_experiment_design.py
  • smoke check that legacy _detect_domain(...) now returns a coarse tuple derived from the same detector used by the profile system

@Jiaaqiliu Jiaaqiliu merged commit 31e81e8 into aiming-lab:main Mar 30, 2026
Jiaaqiliu added a commit that referenced this pull request Mar 30, 2026
…cation

- Remove stale _DOMAIN_KEYWORDS import from executor.py (symbol removed by PR #180)
- Fix test_paper_draft_blocked_with_no_metrics: monkeypatch _detect_domain to return
  empirical domain so the no-metrics block triggers correctly with the new detector
Jiaaqiliu added a commit that referenced this pull request Mar 30, 2026
- Remove stale _DOMAIN_KEYWORDS import from executor.py (PR #180 removed it)
- Fix test_paper_draft_blocked_with_no_metrics for new domain detector
- Replace Cyrillic characters with ASCII dashes in PAUSED stage output (PR #177)
- Add pytest-asyncio to dev dependencies for CI compatibility (PR #185)
- Guard os.getuid()/os.getgid() for Windows in figure renderer
Jiaaqiliu added a commit that referenced this pull request Apr 1, 2026
Sync with upstream open source repo (10 commits):
- feat: universal skill loading system with 20 built-in skills and A-Evolve integration
- feat: A-Evolve agentic evolution skill from community contribution
- fix: post-merge compatibility fixes for PRs #177, #180, #185
- fix: detect remote GPU hardware when ssh_remote mode is configured
- fix: pause iterative refinement on ACP timeout (PR #177)
- fix: unify pipeline domain checks on the profile detector (PR #180)
- ci: add GitHub Actions workflow for automated testing (PR #185)
- Remove HITL module (deleted by upstream), clean all references
- Add 3 missing builtin skills (scientific-visualization/writing/statistical-reporting)
- All 2504 tests pass, 0 failures
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